Modding Q&A [For Quick Questions and Answers]

Users who are viewing this thread

Status
Not open for further replies.
does anyone know how to make a mercenary headless? I've tried to make a face texture transparent but i cant figure it out
 
DarkAngel#1 said:
Hey guys
I was just wondering if anyone knew how to make captured villages produce units of the new faction or where it has been done before.

Also I would like to know if it is possible to make one faction spawn more recruits from their villages than another faction.

Cheers
DarkAngel#1

For a village to spawn the new faction's units you have to change its culture. Look up in module_scripts the code that deals with conquering a village (actually conquering the town/castle it is bound to) and when it changes faction also make it change culture. That should, largely, cover it. If you're using the module system that is...

For the differentiated village recruit production... I don't know. Sorry.




And for one of my own problems:


I have the following code that USED to work in order to have "discoverable" places on the world map. Meaning a map icon would stay hidded (but active and working, just like any other party) until I come close enough to see it. That moment the always_visible flag should change to 1 and so make the place visible from that moment forward.

The problem is that it dissapears when i ride off. So it makes no sense. The code is placed in module_simple_triggers right after the deprecated ti_simulate_battle. Any ideas? :neutral:

(0,
[(map_free),
  (try_for_range,":cur_icon","p_smuggler_village_01","p_salt_mine"),                      #go through Fremen and Smuggler villages I have added after the Native ones
        (store_distance_to_party_from_party,":cur_dist","p_main_party",":cur_icon"), #get the distance between the player party and the village
        (lt,":cur_dist",1),                                                                                                  #I guess this must be an if condition, so if current distance is smaller then the minimum distance it  runs next line
        (party_set_flags,":cur_icon",pf_always_visible,1),                                              #this should put the pf_always_visible flag in my previously undiscovered village making it visible for all eternity
  (try_end),

  (try_for_range,":cur_icon","p_sietch_tabr","p_castle_1"),                                        #go through Fremen and Smuggler towns I have added after the Native ones
        (store_distance_to_party_from_party,":cur_dist","p_main_party",":cur_icon"), #get the distance between the player party and the town
        (lt,":cur_dist",1),                                                                                                  #I guess this must be an if condition, so if current distance is smaller then the minimum distance it  runs next line
        (party_set_flags,":cur_icon",pf_always_visible,1),                                              #this should put the pf_always_visible flag in my previously undiscovered town making it visible for all eternity
  (try_end),
  ]),
 
Dawiduh said:
DarkAngel#1 said:
Hey guys
I was just wondering if anyone knew how to make captured villages produce units of the new faction or where it has been done before.

Also I would like to know if it is possible to make one faction spawn more recruits from their villages than another faction.

Cheers
DarkAngel#1

For a village to spawn the new faction's units you have to change its culture. Look up in module_scripts the code that deals with conquering a village (actually conquering the town/castle it is bound to) and when it changes faction also make it change culture. That should, largely, cover it. If you're using the module system that is...

For the differentiated village recruit production... I don't know. Sorry.




And for one of my own problems:


I have the following code that USED to work in order to have "discoverable" places on the world map. Meaning a map icon would stay hidded (but active and working, just like any other party) until I come close enough to see it. That moment the always_visible flag should change to 1 and so make the place visible from that moment forward.

The problem is that it dissapears when i ride off. So it makes no sense. The code is placed in module_simple_triggers right after the deprecated ti_simulate_battle. Any ideas? :neutral:

(0,
[(map_free),
  (try_for_range,":cur_icon","p_smuggler_village_01","p_salt_mine"),                      #go through Fremen and Smuggler villages I have added after the Native ones
        (store_distance_to_party_from_party,":cur_dist","p_main_party",":cur_icon"), #get the distance between the player party and the village
        (lt,":cur_dist",1),                                                                                                  #I guess this must be an if condition, so if current distance is smaller then the minimum distance it  runs next line
        (party_set_flags,":cur_icon",pf_always_visible,1),                                              #this should put the pf_always_visible flag in my previously undiscovered village making it visible for all eternity
  (try_end),

  (try_for_range,":cur_icon","p_sietch_tabr","p_castle_1"),                                        #go through Fremen and Smuggler towns I have added after the Native ones
        (store_distance_to_party_from_party,":cur_dist","p_main_party",":cur_icon"), #get the distance between the player party and the town
        (lt,":cur_dist",1),                                                                                                  #I guess this must be an if condition, so if current distance is smaller then the minimum distance it  runs next line
        (party_set_flags,":cur_icon",pf_always_visible,1),                                              #this should put the pf_always_visible flag in my previously undiscovered town making it visible for all eternity
  (try_end),
  ]),


:mrgreen:


Code:
(0,
 [(map_free),
  (try_for_range,":cur_icon","p_smuggler_village_01","p_salt_mine"),                              
 (store_distance_to_party_from_party,":cur_dist","p_main_party",":cur_icon"), 
   (lt,":cur_dist",1),

 # # # # # # # # # # # # # # # # # # # # # #
   (party_set_flags, ":cur_icon", pf_disabled, 0),
 # # # # # # # # # # # # # # # # # # # # # # 
                                                                                                 
(party_set_flags,":cur_icon",pf_always_visible,1),                                             
(try_end),
 
OK I want to change the ingame font and used the font customiser but it didn't work and it looks like this when I loaded it up. See the text doesn't appear so can anyone help me out.

 
Dawiduh said:
this is really annoying. it works for the towns but not for the villages :neutral:

Do you have this settings for your villages ? (module_parties)

Code:
  ("village_1","Bruges_Village",  icon_village_snow_a|pf_disabled|pf_village, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(39.47,99.26),[],100),

this is my parties i dont know if help it ?  :roll:

Code:
  ("camp_anglais","Camp anglais", icon_camp|pf_disabled|pf_is_static|pf_hide_defenders, no_menu, pt_none, fac_neutral,0,ai_bhvr_hold,0,(34.76,-47.58),[],100),

it work with

show (initially disabled)
  (party_set_flags, "p_camp_anglais", pf_disabled, 0),
    (party_set_flags, "p_camp_anglais", pf_always_visible, 1),
#    (party_set_flags, "p_camp_anglais", pf_quest_party, 1),

hide (quest finished)

    (party_set_flags, "p_camp_anglais", pf_always_visible, 0),
    (party_set_flags, "p_camp_anglais", pf_disabled, 1),



edit:

Lumos said:
Why are you disabling the party? Just omit pf_always_visible, then put some code that sets it back to 1 for the current village in game_check_party_sees_party.

Yes, it's better like this, but it work and i'm so tired  :lol:



edit:

Dawiduh said:
Fantasy Warriosr as Lumos said, I'm not using pf_disabled. I'm just leaving out pf_always_visible. and that is all. And my code worked fine 1-2 months ago and now it doesn't. I really need to get this going again. Been out of it for almost one month... damn work (and teambuildings travel, etc.  :mrgreen: )

Ho! ok sorry i understand now,I would like to help but I do not speak English  Correctly :sad:
 
Somebody can tell me why this doesn´t make effect if the result is less than 1? ( I want 0.8 ).

Code:
(store_div, ":resultado", 8, 10),
		(position_move_x, pos1, ":resultado", 1),
		(overlay_set_position, "$g_pvp_texto_tiempo_minero", pos1),

How Can I do that? I need to specify more in that position.

Thanks.
 
CTCCoco said:
Somebody can tell me why this doesn´t make effect if the result is less than 1? ( I want 0.8 ).
Thanks.
Because all values in the module system are integers. You need to use the fixed point multiplier
Cozur said:
Can someone explain the reinforcements in party_template? Like what the numbers after the unit names mean?
Minimum and maximum limits for randomization when the party template is added to a party.
 
Cozur said:
Can someone explain the reinforcements in party_template? Like what the numbers after the unit names mean?

I can't help you there too much. I just put 10 after each other and I got 300 strong armies defending each city.

Fantasy Warriosr as Lumos said, I'm not using pf_disabled. I'm just leaving out pf_always_visible. and that is all. And my code worked fine 1-2 months ago and now it doesn't. I really need to get this going again. Been out of it for almost one month... damn work (and teambuildings travel, etc.  :mrgreen: )
 
Somebody said:
CTCCoco said:
Somebody can tell me why this doesn´t make effect if the result is less than 1? ( I want 0.8 ).
Thanks.
Because all values in the module system are integers. You need to use the fixed point multiplier
Cozur said:
Can someone explain the reinforcements in party_template? Like what the numbers after the unit names mean?
Minimum and maximum limits for randomization when the party template is added to a party.

Loos like Somebody told you  :grin:
 
Somebody said:
CTCCoco said:
Somebody can tell me why this doesn´t make effect if the result is less than 1? ( I want 0.8 ).
Thanks.
Because all values in the module system are integers. You need to use the fixed point multiplier
Cozur said:
Can someone explain the reinforcements in party_template? Like what the numbers after the unit names mean?
Minimum and maximum limits for randomization when the party template is added to a party.

Aha, I thought it was how often the lords/cities gained reinforcements. Where is that defined?
 
Status
Not open for further replies.
Back
Top Bottom