Code:
;###### Isengard Garrison Script: By TNZ and Withwnar #######
;###### For TA 3.1 #######
declare_counter france_garrison
;###### Isengard Garrison Script: Local vs AI #######
monitor_event GeneralAssaultsResidence FactionIsLocal
and TargetFactionType france
and I_IsFactionAIControlled france
and IsTargetRegionOneOf Nan-Curunir_Province
and I_SettlementUnderSiege Nan-Curunir
create_unit Nan-Curunir, Garrison Orthanc Guard, num 4, exp 2, arm 0, wep 0
create_unit Nan-Curunir, Garrison Uruk-Hai Raiders, num 4, exp 2, arm 0, wep 0
create_unit Nan-Curunir, Garrison Uruk-Hai Archers, num 2, exp 0, arm 0, wep 0
set_counter france_garrison 1
end_monitor
monitor_event GeneralAssaultsResidence FactionIsLocal
and TargetFactionType france
and I_IsFactionAIControlled france
and IsTargetRegionOneOf Dunland_Province
and I_SettlementUnderSiege Dunland
create_unit Dunland, Garrison Dunlendings, num 4, exp 0, arm 0, wep 0
create_unit Dunland, Garrison Dunlending Axemen, num 2, exp 0, arm 0, wep 0
set_counter france_garrison 1
end_monitor
monitor_event GeneralAssaultsResidence FactionIsLocal
and TargetFactionType france
and I_IsFactionAIControlled france
and IsTargetRegionOneOf Dunland-Hills_Province
and I_SettlementUnderSiege Dunland-Hills
create_unit Dunland-Hills, Garrison Dunlendings, num 4, exp 0, arm 0, wep 0
create_unit Dunland-Hills, Garrison Dunlending Axemen, num 2, exp 0, arm 0, wep 0
set_counter france_garrison 1
end_monitor
;###### Isengard Garrison Script: AI vs AI #######
monitor_event GeneralAssaultsResidence not FactionIsLocal
and TargetFactionType france
and I_IsFactionAIControlled france
and IsTargetRegionOneOf Nan-Curunir_Province
and I_SettlementUnderSiege Nan-Curunir
create_unit Nan-Curunir, Garrison Orthanc Guard, num 6, exp 2, arm 0, wep 0
create_unit Nan-Curunir, Garrison Uruk-Hai Raiders, num 6, exp 2, arm 0, wep 0
create_unit Nan-Curunir, Garrison Uruk-Hai Archers, num 4, exp 0, arm 0, wep 0
set_counter france_garrison 1
end_monitor
monitor_event GeneralAssaultsResidence not FactionIsLocal
and TargetFactionType france
and I_IsFactionAIControlled france
and IsTargetRegionOneOf Dunland_Province
and I_SettlementUnderSiege Dunland
create_unit Dunland, Garrison Dunlendings, num 6, exp 0, arm 0, wep 0
create_unit Dunland, Garrison Dunlending Axemen, num 4, exp 0, arm 0, wep 0
set_counter france_garrison 1
end_monitor
monitor_event GeneralAssaultsResidence not FactionIsLocal
and TargetFactionType france
and I_IsFactionAIControlled france
and IsTargetRegionOneOf Dunland-Hills_Province
and I_SettlementUnderSiege Dunland-Hills
create_unit Dunland-Hills, Garrison Dunlendings, num 6, exp 0, arm 0, wep 0
create_unit Dunland-Hills, Garrison Dunlending Axemen, num 4, exp 0, arm 0, wep 0
set_counter france_garrison 1
end_monitor
;###### Isengard Garrison Script: Destroy France Garrison #######
monitor_event PostBattle IsRegionOneOf Nan-Curunir_Province, Dunland_Province, Dunland-Hills_Province
and I_CompareCounter france_garrison = 1
destroy_units france garrison_unit
set_counter france_garrison 0
end_monitor
monitor_event PreBattleWithdrawal IsRegionOneOf Nan-Curunir_Province, Dunland_Province, Dunland-Hills_Province
and I_CompareCounter france_garrison = 1
destroy_units france garrison_unit
set_counter france_garrison 0
end_monitor