Modding Q&A [For Quick Questions and Answers]

Users who are viewing this thread

Status
Not open for further replies.
Because it's placeholder, yes, but if 1 fire, it arms him and clothes him and adds everything.  If 2-6 fire, they do nothing.  Nothing is added to the inventory, no skill points are added, etc. 
 
Code:
  ("bard_intro_1",menu_text_color(0xFF000000)|mnf_disable_all_keys,
    "etc etc etc",
    "none",
    [],
    [
     ("continue",[],"Continue...",
       [(assign, "$player_class", 2),
	   (jump_to_menu, "mnu_start_phase_2"),

        ]
       ),
      ("go_back",[],"Go back",
       [
		  (jump_to_menu, "mnu_class_choices"),
       ]),
    ]
  ),
 
Would it be possible to assign multiple cultures to a faction? Say, culture_1 would be the north of kingdom_1, culture_2 would be the south of kingdom_1, and culture_3 the centre of kingdom_1... I've noticed     
Code:
(faction_set_slot, "fac_kingdom_1",  slot_faction_culture, "fac_culture_1"),
in module_scripts, so would something like:
Code:
     (faction_set_slot, "fac_culture_1",  slot_faction_culture, "fac_kingdom_1"),
      (faction_set_slot, "fac_culture_2",  slot_faction_culture, "fac_kingdom_1"),
      (faction_set_slot, "fac_culture_3",  slot_faction_culture, "fac_kingdom_1"),
do the trick? Thanks :grin:
 
In your example, you are settings kingdom's as the culture of a culture. This doesn't make much sense.

In order to have a kingdom have multiple cultures, it would need to have multiple culture slots. Something like slot_faction_culture_north, slot_faction_culture_south, etc, and store a different culture in each slot for that one kingdom. But then you'd need to change all the code were kingdom cultures are used and make it so the _north/_south culture is selected appropriately in various situations, etc...
 
In your example, you are settings kingdom's as the culture of a culture. This doesn't make much sense.
Oh true. How did I not get that :O.
In order to have a kingdom have multiple cultures, it would need to have multiple culture slots. Something like slot_faction_culture_north, slot_faction_culture_south, etc, and store a different culture in each slot for that one kingdom. But then you'd need to change all the code were kingdom cultures are used and make it so the _north/_south culture is selected appropriately in various situations, etc...
so adding stuff like slot_faction_culture_1, slot_faction_culture_2, etc etc, and then changing every instance of slot_faction_culture to slot_faction_culture_1 or _2 or something, that would work?
 
I've modified the game to allow garrisons in villages that you own.  Now I want to put the troops on the payroll.  I modified the troops section of the budget report, but village garrisons don't shoe up. 

My additions are in green. What's wrong, please?
#TroopsBegin
      (try_for_parties, ":party_no"),
        (assign, ":garrison_troop", 0),
        (try_begin),
          (this_or_next|party_slot_eq, ":party_no", slot_party_type, spt_town),
          (party_slot_eq, ":party_no", slot_party_type, spt_castle),
          (party_slot_eq, ":party_no", slot_party_type, spt_village), ##garrison of villages  
        (party_slot_eq, ":party_no", slot_town_lord, "trp_player"),
          (assign, ":garrison_troop", 1),
(else_try), 
          (this_or_next|party_slot_eq, ":party_no", slot_party_type, spt_town),
(party_slot_eq, ":party_no", slot_party_type, spt_castle),
                          (party_slot_eq, ":party_no", slot_party_type, spt_village), ##garrison of villages    
      (neg|party_slot_ge, ":party_no", slot_town_lord, 1), #unassigned
  (store_faction_of_party, ":center_faction", ":party_no"),
  (eq, ":center_faction", "fac_player_supporters_faction"),
  (faction_slot_eq, "fac_player_supporters_faction", slot_faction_leader, "trp_player"),
          (assign, ":garrison_troop", 1),  
        (try_end),

        (this_or_next|eq, ":party_no", "p_main_party"),
(eq, ":garrison_troop", 1),
        (assign, ":total_wage", 0),
        (party_get_num_companion_stacks, ":num_stacks", ":party_no"),
        (try_for_range, ":i_stack", 0, ":num_stacks"),
          (party_stack_get_troop_id, ":stack_troop", ":party_no", ":i_stack"),
          (party_stack_get_size, ":stack_size", ":party_no", ":i_stack"),
          (call_script, "script_game_get_troop_wage", ":stack_troop", ":party_no"),
          (assign, ":cur_wage", reg0),
          (val_mul, ":cur_wage", ":stack_size"),
          (val_add, ":total_wage", ":cur_wage"),
        (try_end),
        (try_begin),
          (eq, ":garrison_troop", 1),
          (val_div, ":total_wage", 2), #Half payment for garrisons
        (else_try),
          (eq, ":party_no", "p_main_party"),
          (store_sub, ":total_payment_ratio", 14, "$g_cur_week_half_daily_wage_payments"), #between 0 and 7
          (val_mul, ":total_wage", ":total_payment_ratio"),
          (val_div, ":total_wage", 14),
        (try_end),
##        (gt, ":total_wage", 0),
        (val_mul, ":total_wage", -1),
        (val_add, ":net_change", ":total_wage"),
        (str_store_party_name, s0, ":party_no"),
        (try_begin),
          (eq, ":party_no", "p_main_party"),
          (str_store_string, s0, "str_s0s_party"),
        (try_end),
 
You need to add "this_or_next|" to the line before your green line. Or, add it to your green line and stick them each one line higher than you have them at present.

Remember, all conditional checks stack together in the module system, as if there was a Boolean AND between them, unless you add the this_or_next before the check.
 
Caba`drin said:
You need to add "this_or_next|" to the line before your green line. Or, add it to your green line and stick them each one line higher than you have them at present.

Remember, all conditional checks stack together in the module system, as if there was a Boolean AND between them, unless you add the this_or_next before the check.

Yes, thank you.  After I made that change, it looks like the budget report picked up the wages, but it's not on the report. I get:
(total income)                    =  6203
Wages for (player's) party = -1122
Net Income                        =  3993

It looks like the wages for the village (my only fief) are being subtracted, but there is no line for them.
 
New Questions, Sir
To change a Relations with Troops is script_troop_change_relation_with_troop, rights?
So what is that can change faction relations?
 
Somebody said:
The most direct method would be (set_relation), but that doesn't taken into account the various political consequences. Look in module_scripts for its usage.
I saw it. So the template is (set_relation, ":kingdom_a", ":kingdom_b", ":relation"),
Red is faction that we will change with Green Faction, then The Blue is relation what we will change. Thats rights, Somebody?
 
13exa said:
Somebody said:
The most direct method would be (set_relation), but that doesn't taken into account the various political consequences. Look in module_scripts for its usage.
I saw it. So the template is (set_relation, ":kingdom_a", ":kingdom_b", ":relation"),
Red is faction that we will change with Green Faction, then The Blue is relation what we will change. Thats rights, Somebody?

when you change Faction A relation with Faction B to X, you are  automaticly changing Faction B relation with Faction A to X too.

EDIT:
and yes that right

relation should be between 1(friendly) and -1(hatefull) and 0 is neutral. anything less than 0 will make some atacks, but -1 will make much more atacks.
 
Ikaguia said:
13exa said:
Somebody said:
The most direct method would be (set_relation), but that doesn't taken into account the various political consequences. Look in module_scripts for its usage.
I saw it. So the template is (set_relation, ":kingdom_a", ":kingdom_b", ":relation"),
Red is faction that we will change with Green Faction, then The Blue is relation what we will change. Thats rights, Somebody?

when you change Faction A relation with Faction B to X, you are  automaticly changing Faction B relation with Faction A to X too.
Well, Thank you for every Taleworlders :mrgreen: that answer my questions
 
Status
Not open for further replies.
Back
Top Bottom