It is a common sight in Warband: Sooner or later a lord gets thrown out of his faction, joins another one only to be indicted again few days thereafter.
... I have found that all lords befallen by this sad fate share two interesting characteristics:
1) They hold no fiefs. No wonder, those being stripped on indictment. This makes them more likely to raise controversy.
2) They have a controversy of >90. Probably due to 1). And this makes them ineligible for new fiefs. Which causes 1) to persist.
Another interesting point is that a lord loses his party on indictment, which has him suffer both respawn and buildup time before he actually has a chance to work on rising once more.
Experimentally, I have modified script_indict_lord_for_treason with two minor tweaks and it seems to have done the trick, so to write:
Unfortunately, my playtime is rather limited, so I am not totally sure it is enough. Within ~400 ingame days the problem has so far not resurfaced, which is most reassuring though.
Detailed deployment instruction:
Seek for "#Indictments, cont: Remove party" in module_scripts.py.
The first code block goes right above this line.
The code block that is already in place directly below this line must be replaced. If you want a minimal solution which may or may not cause problems that you can help me find, replace with the second code block from the beginning of this post.
If you just want to play it save, replace instead with this:
To help out the lord even more, use JuJu70's variant, which additionally teleports the lord to safety (you may see a lord disappear on the world map, if you are nearby when he is indicted; this is already the case with the vanilla script, however):
... I have found that all lords befallen by this sad fate share two interesting characteristics:
1) They hold no fiefs. No wonder, those being stripped on indictment. This makes them more likely to raise controversy.
2) They have a controversy of >90. Probably due to 1). And this makes them ineligible for new fiefs. Which causes 1) to persist.
Another interesting point is that a lord loses his party on indictment, which has him suffer both respawn and buildup time before he actually has a chance to work on rising once more.
Experimentally, I have modified script_indict_lord_for_treason with two minor tweaks and it seems to have done the trick, so to write:
Code:
(troop_set_slot, ":troop_no", slot_troop_controversy, 0),
Code:
(troop_get_slot, ":led_party", ":troop_no", slot_troop_leaded_party),
(try_begin),
(party_is_active, ":led_party"),
(neq, ":led_party", "p_main_party"),
(party_set_faction, ":led_party", ":new_faction"),
(try_end),
Detailed deployment instruction:
Seek for "#Indictments, cont: Remove party" in module_scripts.py.
The first code block goes right above this line.
The code block that is already in place directly below this line must be replaced. If you want a minimal solution which may or may not cause problems that you can help me find, replace with the second code block from the beginning of this post.
If you just want to play it save, replace instead with this:
Code:
(troop_get_slot, ":led_party", ":troop_no", slot_troop_leaded_party),
(try_begin),
(party_is_active, ":led_party"),
(neq, ":led_party", "p_main_party"),
(party_set_faction, ":led_party", ":new_faction"),
# addition to minimal: detaches lord's party from anything it is currently attached to, increases chance of flight
(party_get_attached_to, ":anything", ":led_party"),
(ge, ":anything", 0), # center, fight, whatever else one can be attached to; assumes "nothing" be '-1'
(party_detach, ":led_party"),
(try_end),
Code:
(troop_get_slot, ":led_party", ":troop_no", slot_troop_leaded_party),
(try_begin),
(party_is_active, ":led_party"),
(neq, ":led_party", "p_main_party"),
(party_set_faction, ":led_party", ":new_faction"),
# addition to minimal: teleports lord's party to town or castle of new faction, guarantees flight
(party_detach, ":led_party"), # assumes that party_detach does not fail if party not attached to anything
(call_script,"script_cf_select_random_walled_center_with_faction", ":new_faction", -1),
(party_relocate_near_party, ":led_party", reg0, 2),
(try_end),