Modding Q&A [For Quick Questions and Answers]

Users who are viewing this thread

Status
Not open for further replies.
Can someone tell me what this mean and how I can fix it, I started removing some native partys and the 5th faction. Obviously something to do with the spawn bandits script but I don't see anything wrong with it. That's why I really didn't want to go around removing native stuff as stuff like this happen.

Here's what appears in the pyme text that says where or what the error is, I removed the bracket and such but I got even more errors so I really need help here. Even if someone could take the module system im working with and fix it for me I would be grateful. This is in module scripts by the way.
IndentationError: unexpected indent
Traceback (most recent call last):
  File "PythonCard\widget.pyo", line 408, in _dispatch
  File "editor.pyo", line 1203, in on_btnOpenProject_command
  File "editor.pyo", line 905, in on_menuModificationOpen_select
  File "editor.pyo", line 1527, in importAll
  File "pymelib\ModuleImporter.pyo", line 31, in importAll
  File "pymelib\FileParser.pyo", line 547, in parse
  File "pymelib\FileParser.pyo", line 447, in traite_modules
  File "pymelib\FileParser.pyo", line 31, in imp
  File "J:\m&b mod stuff\PyME\temp\module_scripts.py", line 16856
    ]),
    ^
IndentationError: unexpected indent

Here's an image of where this part is.

 
I have a dialogue/string question.  I know when you use "{playername}" in a string, it gets replaced with the player's name.  When you use "{s#}" in a string, it gets replaced with whatever is in the string register.

Some of the strings or dialogue has stuff like this: "{young man/lassie}".  How does the game know which to choose?  Is there some code somewhere I could take a look at?  Or is this hard-coded, so that it uses the stuff to the left of '/' if the player is male and the stuff on the right if the player is female?

What if I wanted to to do something like that, except it would depend on the gender of the npc I'm talking to?  Is there some way I can do that other than to create two dialogue tuples?
 
fg109 said:
I have a dialogue/string question.  I know when you use "{playername}" in a string, it gets replaced with the player's name.  When you use "{s#}" in a string, it gets replaced with whatever is in the string register.

Some of the strings or dialogue has stuff like this: "{young man/lassie}".  How does the game know which to choose?  Is there some code somewhere I could take a look at?  Or is this hard-coded, so that it uses the stuff to the left of '/' if the player is male and the stuff on the right if the player is female?

What if I wanted to to do something like that, except it would depend on the gender of the npc I'm talking to?  Is there some way I can do that other than to create two dialogue tuples?
The game engine (the "sir/lady" syntax is parsed there, not in the module system) looks for player gender with troop_get_type.
If you want something similar, but when talking to NPCs, do a single dialog with variable parts using string registers. Like this:
"I want to {s4} you, but I'm afraid I'm late for a witch burning."
Where you assign s4 according to gender (troop_get_type), to "rough up peasants with" or "make passionate love to".
 
MadVader said:
Look for the looter leader troop (trp_something) in the code, probably in the menus. His dialogs are always started, why? (I don't have the code where I am, so I can't check)
I've been looking for ages but I can't see why. I think whatever determines whether you talk to an npc after defeating them is found in the total victory menu, between ##talk to enemy leaders and ####talk to freed heros, but I can't see any reason why my npc isn't included whilst the looter leader is.
 
pentagathus said:
MadVader said:
Look for the looter leader troop (trp_something) in the code, probably in the menus. His dialogs are always started, why? (I don't have the code where I am, so I can't check)
I've been looking for ages but I can't see why. I think whatever determines whether you talk to an npc after defeating them is found in the total victory menu, between ##talk to enemy leaders and ####talk to freed heros, but I can't see any reason why my npc isn't included whilst the looter leader is.
There should be a start_map_conversation there. Check the code there if you fail some condition, but the looter leader doesn't.
 
I changed the npcs faction from commoners to outlaws and that seems to have worked (although he manages to escape but that should be easy enough to fix.)
 
Where can I find the dialogue, which comes, if I start a new game. I found the most of them in module_game_menus.py , but I miss one.
It's the last dialogue before the scene with the bandit starts. The one with the tavern and the sound of a sword.
Anyone know, where I can find this?
 
Roemerboy said:
Where can I find the dialogue, which comes, if I start a new game.
It's the last dialogue before the scene with the bandit starts.
Good that you found what you're looking for... but for the sake of clarity, this is not a dialogue (box/window/screen), although it can be seen as one. It's defined as a game menu, so we must refer to it as a menu, although it does act like a dialogue window... while the "dialogue" term is reserved for module_dialogs's conversations.
 
Lumos said:
Roemerboy said:
Where can I find the dialogue, which comes, if I start a new game.
It's the last dialogue before the scene with the bandit starts.
Good that you found what you're looking for... but for the sake of clarity, this is not a dialogue (box/window/screen), although it can be seen as one. It's defined as a game menu, so we must refer to it as a menu, although it does act like a dialogue window... while the "dialogue" term is reserved for module_dialogs's conversations.

Ah yes I remember me.  :mrgreen:
I looked in game_menus.py , but I forgot to write it here.....

Am I be right, that if I change the things below this I am able to change the order of the spawns? For example that the merchant spawn before the bandit?
 
xPearse said:
Can someone tell me what this mean and how I can fix it, I started removing some native partys and the 5th faction. Obviously something to do with the spawn bandits script but I don't see anything wrong with it. That's why I really didn't want to go around removing native stuff as stuff like this happen.

Here's what appears in the pyme text that says where or what the error is, I removed the bracket and such but I got even more errors so I really need help here. Even if someone could take the module system im working with and fix it for me I would be grateful. This is in module scripts by the way.
IndentationError: unexpected indent
Traceback (most recent call last):
  File "PythonCard\widget.pyo", line 408, in _dispatch
  File "editor.pyo", line 1203, in on_btnOpenProject_command
  File "editor.pyo", line 905, in on_menuModificationOpen_select
  File "editor.pyo", line 1527, in importAll
  File "pymelib\ModuleImporter.pyo", line 31, in importAll
  File "pymelib\FileParser.pyo", line 547, in parse
  File "pymelib\FileParser.pyo", line 447, in traite_modules
  File "pymelib\FileParser.pyo", line 31, in imp
  File "J:\m&b mod stuff\PyME\temp\module_scripts.py", line 16856
    ]),
    ^
IndentationError: unexpected indent

Here's an image of where this part is.


Um any help here guys.
 
MadVader said:
fg109 said:
I have a dialogue/string question.  I know when you use "{playername}" in a string, it gets replaced with the player's name.  When you use "{s#}" in a string, it gets replaced with whatever is in the string register.

Some of the strings or dialogue has stuff like this: "{young man/lassie}".  How does the game know which to choose?  Is there some code somewhere I could take a look at?  Or is this hard-coded, so that it uses the stuff to the left of '/' if the player is male and the stuff on the right if the player is female?

What if I wanted to to do something like that, except it would depend on the gender of the npc I'm talking to?  Is there some way I can do that other than to create two dialogue tuples?
The game engine (the "sir/lady" syntax is parsed there, not in the module system) looks for player gender with troop_get_type.
If you want something similar, but when talking to NPCs, do a single dialog with variable parts using string registers. Like this:
"I want to {s4} you, but I'm afraid I'm late for a witch burning."
Where you assign s4 according to gender (troop_get_type), to "rough up peasants with" or "make passionate love to".

Thanks.  :smile:
 
d010060002 said:
I know this has been asked a million times, as I searched the board and folloew the relevant threads. However, I haven't been able to resolve my problem. I wanted to transfer an item between mods; specifically, I wanted to see if I could transfer a musket to a non musket mod, in this case, pop. I found a the mesh, the material, and the texture all in one brf, so i copied that one into my pop module. I also tranferred the texture file and copy and pasted some muskets into the end of the items file. I modified the .ini so that it loads the new brf,  and the game runs. However, I can't find my items anywhere. I've used the cheat menu and they don't appear, and they aren'y in any of the shops. I used morgh's tool to make sure everything was good, and they look ok. They are checked as merchandise, with a reasonable availability. From what I've read, I should be seeing them. HOwever, I'm not. Instead, when I go to the shops I occasionally get an RGL error that says something about a missing iron texture, and that's it. THe game doesn't crash, it just gives me that error and then a few others and continues to run. I think it has something to do with adding items, because when I try and make a new item with morgh's tool, it never works. I have created an exact replica of an item using his tool and simply changed the name, and it doesn't show up. However, maybe it's the texture error? Anyways, any help would be appreciated. Thanks.
@d010060002:I don't supose you've tried finding those textures that the RGL error talks about,(in this case look in YourMusketMod/Textures)and copying them to your PoP/Textures folder,have you? That might just fix your problem.
 
d010060002 said:
I know this has been asked a million times, as I searched the board and folloew the relevant threads. However, I haven't been able to resolve my problem. I wanted to transfer an item between mods; specifically, I wanted to see if I could transfer a musket to a non musket mod, in this case, pop. I found a the mesh, the material, and the texture all in one brf, so i copied that one into my pop module. I also tranferred the texture file and copy and pasted some muskets into the end of the items file. I modified the .ini so that it loads the new brf,  and the game runs. However, I can't find my items anywhere. I've used the cheat menu and they don't appear, and they aren'y in any of the shops. I used morgh's tool to make sure everything was good, and they look ok. They are checked as merchandise, with a reasonable availability. From what I've read, I should be seeing them. HOwever, I'm not. Instead, when I go to the shops I occasionally get an RGL error that says something about a missing iron texture, and that's it. THe game doesn't crash, it just gives me that error and then a few others and continues to run. I think it has something to do with adding items, because when I try and make a new item with morgh's tool, it never works. I have created an exact replica of an item using his tool and simply changed the name, and it doesn't show up. However, maybe it's the texture error? Anyways, any help would be appreciated. Thanks.
Which tool? For example his texture editor doesn't save the mesh names. Maybe the python editor does.
In theory the items file is good because it wants to load something.

Do you see the textures on the model in the brf editor?
Are the textures in the right place, in the modules\yourmodulename\textures folder?
I suppose in .ini you used load_mod_resource and not load_resource.

This 'iron' texture is a thing you got from another mod?
 
No, muskets won't show up in shops since the merchants aren't scripted to carry them. Increase the bolded numbers by 1.
menus.txt said:
menu_cheat_find_item 0 {!}Current_item_range:_{reg5}_to_{reg6} none 4 2133 2 72057594037927941 144115188075856184 2120 3 72057594037927942 144115188075856184 96 2110 2 72057594037927942 288230376151712890 2106 2 72057594037927942 1 3
mno_cheat_find_item_next_range  0  {!}Move_to_next_item_range.  6 2105 2 144115188075856184 96 4 0 30 2 144115188075856184 288230376151712890 2133 2 144115188075856184 0 3 0 2060 1 864691128455135260  .  mno_cheat_find_item_choose_this  0  {!}Choose_from_this_range.  9 1532 1 360287970189639684 2120 3 1224979098644774912 144115188075856184 96 2110 2 1224979098644774912 288230376151712890 2121 3 1224979098644774913 1224979098644774912 144115188075856184 6 3 1224979098644774914 0 1224979098644774913 2120 3 1224979098644774915 144115188075856184 1224979098644774914 1535 3 360287970189639684 1224979098644774915 1 3 0 2042 1 360287970189639684  .  mno_camp_action_4  0  {!}Back_to_camp_menu.  1 2060 1 864691128455135258  .
 
Guys, is there any way to skip the fighting and the merchant tutorial quest when starting a new game? It might be fun but it really is annoying when editing. All is nice and clear in the modules until the part Roemerboy was reffering to (and Somebody answered to): start_phase_3

I wanted to short-circuit the whole thing but I cannot find the dialogue with the merchant. If I find that and the "I'm not interested" option then I can just skip the tutorial because it must have somewhere the an exit from the quest.

So, I'd be trying to jump from start_phase_2.5 (I'm at work and don't have the modules with me so it might also be start_phase_2) straigh after the saying no to the merchant.

Thanks.



PS
Also I'm still stuck with the whole banner thing, and, frustrating enough, I don't have enough time to try things out with it. I will surely annoy you guys again when I'll have time for that.  :mrgreen:
 
Dawiduh said:
Guys, is there any way to skip the fighting and the merchant tutorial quest when starting a new game? It might be fun but it really is annoying when editing.
Easy as pie. Get to the menu where you join a caravan to X, or even better - go to the next menu, and instead of making the player jump to a scene and so on, use
Code:
(change_screen_return),
and you'll be kicked on to the map. I can't give you a code example, because my start menus were long changed, but if you couldn't get something from my half-arsed explanation in the previous sentence, just tell me. :smile:
Dawiduh said:
Also I'm still stuck with the whole banner thing, and, frustrating enough, I don't have enough time to try things out with it. I will surely annoy you guys again when I'll have time for that.  :mrgreen:
Banner thing? What banner thing? I'm also stuck on a banner thing. :smile:
 
Status
Not open for further replies.
Back
Top Bottom