Hey everybody. Yep the whole 3 other users on here. :D How do you assgn a fief to a faction?[By that I mean how do change which faction controlls a town/castle/village.
For towns and castles, go to module_scripts.py, scroll down until you find the script_give_center_to_lord and give_center_to_faction_aux section, then edit which lord (for cities), or which faction (for castles) owns each castle/town. Villages are normally given to the closest town or castle.
For lords, rememebr the faction of the lord determines the faction of the city. Castles will be given to a random lord of the faction.
Aaah thanks. And for that you are spared dfs.
Could you give me an example? Like what I write in where:
# script_give_center_to_lord
# Input: arg1 = center_no, arg2 = lord_troop
("give_center_to_lord",
[
(store_script_param_1, ":center_no"),
(store_script_param_2, ":lord_no"),
(party_get_slot, ":lord_no", ":center_no", slot_town_lord),
(store_troop_faction, ":lord_troop_faction", ":lord_troop_id"),
(try_begin),
(eq, ":lord_troop_id", "trp_player"),
(gt, "$players_kingdom", 0),
(party_set_faction, ":center_no", "$players_kingdom"),
(else_try),
(party_set_faction, ":center_no", ":lord_troop_faction"),
(try_end),
(party_set_slot, ":center_no", slot_town_lord, ":lord_troop_id"),
So where do I put what. Assuming I want to give town_11 to kingdom_1_lord?
Wrong bit. Search for the script name (give_center_to_lord), and find the bit where it's called lots and lots of times with parties as the parameters.
Moved to Workshop
Do you mean this bit?
(try_begin),
(this_or_next|party_slot_eq, ":center_no", slot_party_type, spt_town),
(party_slot_eq, ":center_no", slot_party_type, spt_castle),
(troop_get_slot, ":cur_banner", ":lord_troop_id", slot_troop_banner_scene_prop),
(gt, ":cur_banner", 0),
(val_sub, ":cur_banner", "spr_banner_a"),
(val_add, ":cur_banner", "icon_banner_01"),
(party_set_banner_icon, ":center_no", ":cur_banner"),
(try_end),
This bit;
(call_script, "script_give_center_to_lord", "p_town_1", "trp_kingdom_4_lord"),
(call_script, "script_give_center_to_lord", "p_town_2", "trp_knight_4_1"),
(call_script, "script_give_center_to_lord", "p_town_3", "trp_knight_5_1"),
(call_script, "script_give_center_to_lord", "p_town_4", "trp_knight_1_1"),
I cant find that bit.
It's quite near the top...
it's not working. I put this in (call_script, "script_give_center_to_lord", "p_town_11", "trp_kingdom_1_lord"), but curaw (town 11) still isnt owned by the right faction. Do I need to givew it to kingdom_1 as wel as the king?
It should work...
1) does the King have any other cities atm? It may be impossible to give him more than 1 city.
2) Did you remember to build the module?
There was some huge error in the python files which meant I had to wipe all of my m&b files so I'll try again soon.
Nicht gut.
Check your PM inbox btw, I sent you a message.