kraggrim ?️ said:Huh. I can't actually recall how to 'get' the current faction of a troop or party.
operations handle that
kraggrim ?️ said:Huh. I can't actually recall how to 'get' the current faction of a troop or party.
kraggrim ?️ said:Doh, it was store faction and I was searching for get_faction and variations on that .
kraggrim ?️ said:lol one of these operations even has an alternate spelling just to mess with us
So I think this should work:
#Rebellion changes begin:
(try_begin),
(eq, ":party_type", spt_kingdom_hero_party),
(party_stack_get_troop_id, ":leader", ":party_no"),
(store_troop_faction, ":party_faction", ":leader"),
(try_end),
#Rebellion changes end
(try_begin),
(eq, ":party_no", "p_main_party"),
(try_begin),
(is_between, "$players_kingdom", npc_kingdoms_begin, npc_kingdoms_end),
(assign, ":party_faction", "$players_kingdom"),
(else_try),
(assign, ":party_faction", "fac_player_supporters_faction"),
(try_end),
(else_try),
(eq, ":party_faction", "fac_player_supporters_faction"),
(is_between, ":party_no", walled_centers_begin, walled_centers_end),
(party_get_slot, ":town_lord", ":party_no", slot_town_lord),
(try_begin),
(gt, ":town_lord", 0),
(store_troop_faction, ":party_faction", ":town_lord"),
(else_try),
(store_faction_of_party, ":party_faction", ":party_no"),
(try_end),
(try_end),
But I'm rusty at this so not sure at all. Also remember if it does work it won't change the existing troops, just the new ones that are added from then on.
kraggrim ?️ said:It'll be in module_game_menus. Search for the text for those options you want to change and work backwards from there.
kraggrim ?️ said:lol one of these operations even has an alternate spelling just to mess with us
So I think this should work:
#Rebellion changes begin:
(try_begin),
(eq, ":party_type", spt_kingdom_hero_party),
(party_stack_get_troop_id, ":leader", ":party_no"),
(store_troop_faction, ":party_faction", ":leader"),
(try_end),
#Rebellion changes end
(try_begin),
(eq, ":party_no", "p_main_party"),
(try_begin),
(is_between, "$players_kingdom", npc_kingdoms_begin, npc_kingdoms_end),
(assign, ":party_faction", "$players_kingdom"),
(else_try),
(assign, ":party_faction", "fac_player_supporters_faction"),
(try_end),
(else_try),
(eq, ":party_faction", "fac_player_supporters_faction"),
(is_between, ":party_no", walled_centers_begin, walled_centers_end),
(party_get_slot, ":town_lord", ":party_no", slot_town_lord),
(try_begin),
(gt, ":town_lord", 0),
(store_troop_faction, ":party_faction", ":town_lord"),
(else_try),
(store_faction_of_party, ":party_faction", ":party_no"),
(try_end),
(try_end),
But I'm rusty at this so not sure at all. Also remember if it does work it won't change the existing troops, just the new ones that are added from then on.
kraggrim ?️ said:lol one of these operations even has an alternate spelling just to mess with us
So I think this should work:
#Rebellion changes begin:
(try_begin),
(eq, ":party_type", spt_kingdom_hero_party),
(party_stack_get_troop_id, ":leader", ":party_no"),
(store_troop_faction, ":party_faction", ":leader"),
(try_end),
#Rebellion changes end
(try_begin),
(eq, ":party_no", "p_main_party"),
(try_begin),
(is_between, "$players_kingdom", npc_kingdoms_begin, npc_kingdoms_end),
(assign, ":party_faction", "$players_kingdom"),
(else_try),
(assign, ":party_faction", "fac_player_supporters_faction"),
(try_end),
(else_try),
(eq, ":party_faction", "fac_player_supporters_faction"),
(is_between, ":party_no", walled_centers_begin, walled_centers_end),
(party_get_slot, ":town_lord", ":party_no", slot_town_lord),
(try_begin),
(gt, ":town_lord", 0),
(store_troop_faction, ":party_faction", ":town_lord"),
(else_try),
(store_faction_of_party, ":party_faction", ":party_no"),
(try_end),
(try_end),
But I'm rusty at this so not sure at all. Also remember if it does work it won't change the existing troops, just the new ones that are added from then on.
King Yngvar said:put something like (neq, "$campaign_type", camp_storyline, camp_sandbox)?
The first one says that somehow a lord is leading a party that no longer exists. The second, possibly related, says that there is no party led by the lord one is having a dialog with.King Yngvar said:Could this possibly be the cause of the following errors?
SCRIPT ERROR ON OPCODE 2204: Invalid Party ID: 17697; LINE NO: 4:
At Simple trigger trigger no: 109. At Simple trigger trigger no: 109.
SCRIPT ERROR ON OPCODE 1694: Invalid Party ID: -1; LINE NO: 7:
At dialog condition: dlga_lord_talk:lord_request_help. At dialog condition: dlga_lord_talk:lord_request_help. SCRIPT ERROR ON OPCODE 1694: Invalid Party ID: -1; LINE NO: 7:
At dialog condition: dlga_lord_talk:lord_request_help. At dialog condition: dlga_lord_talk:lord_request_help.
I didn't get these until I became king and had a lord defect to me.
motomataru said:The first one says that somehow a lord is leading a party that no longer exists. The second, possibly related, says that there is no party led by the lord one is having a dialog with.King Yngvar said:Could this possibly be the cause of the following errors?
SCRIPT ERROR ON OPCODE 2204: Invalid Party ID: 17697; LINE NO: 4:
At Simple trigger trigger no: 109. At Simple trigger trigger no: 109.
SCRIPT ERROR ON OPCODE 1694: Invalid Party ID: -1; LINE NO: 7:
At dialog condition: dlga_lord_talk:lord_request_help. At dialog condition: dlga_lord_talk:lord_request_help. SCRIPT ERROR ON OPCODE 1694: Invalid Party ID: -1; LINE NO: 7:
At dialog condition: dlga_lord_talk:lord_request_help. At dialog condition: dlga_lord_talk:lord_request_help.
I didn't get these until I became king and had a lord defect to me.
Would you mind seeing if you get those errors with straight VC 2.032? If so, please post in support with defected lord save game. It would be helpful in that case if you remember the lord involved and his history. Thx.
King Yngvar said:Could this possibly be the cause of the following errors?
SCRIPT ERROR ON OPCODE 2204: Invalid Party ID: 17697; LINE NO: 4:
At Simple trigger trigger no: 109. At Simple trigger trigger no: 109.
SCRIPT ERROR ON OPCODE 1694: Invalid Party ID: -1; LINE NO: 7:
At dialog condition: dlga_lord_talk:lord_request_help. At dialog condition: dlga_lord_talk:lord_request_help. SCRIPT ERROR ON OPCODE 1694: Invalid Party ID: -1; LINE NO: 7:
At dialog condition: dlga_lord_talk:lord_request_help. At dialog condition: dlga_lord_talk:lord_request_help.
I didn't get these until I became king and had a lord defect to me.