Gess1t said:My second quick question will be: can i force a certain party to besiege a town even if this one isn't a member of a kingdom?
Like i can force bandit to besiege a town, and then enter instantly in battle with the party when behind the wall
yes and no. Yes you can control the AI flags of any party to give a command like "go attack that town", no as Native bandits are not suppose to siege places (so you will need to modify that as well to then make it possible).
you will need to learn more about AI and how to use flags like "ai_bhvr_travel_to_point".
from the script that controls NPCs behaviour
Code:
(else_try),
(eq, ":new_ai_state", spai_besieging_center),
(party_get_position, pos1, ":new_ai_object"),
(map_get_random_position_around_position, pos2, pos1, 2),
(party_set_ai_behavior, ":party_no", ai_bhvr_travel_to_point),
(party_set_ai_target_position, ":party_no", pos2),
(party_set_ai_object, ":party_no", ":new_ai_object"),
(party_set_flags, ":party_no", pf_default_behavior, 0),
(party_set_slot, ":party_no", slot_party_follow_me, 1),
(party_set_slot, ":party_no", slot_party_ai_substate, 0),
(try_begin),
(gt, ":party_is_in_town", 0),
(neq, ":party_is_in_town", ":new_ai_object"),
(party_detach, ":party_no"),
(try_end),
(assign, ":aggressiveness", 1),
(assign, ":courage", 9),
(assign, ":initiative", 20),
#(assign, ":initiative", 100),