
Originally Posted by
King Siegfried
Only that script? So the only script in the entire game is my power center ones?
Yeah, just make a new file with:
Code:
;
; Test Script
;
script
;Detect if settlement has been lost
;Decrement event counter
monitor_conditions not I_SettlementOwner Jerusalem = jerusalem
and I_EventCounter holds_jerusalem == 1
and I_NumberOfSettlements jerusalem > 0
set_event_counter holds_jerusalem 0
log MONITOR #1 WORKS
end_monitor
monitor_conditions not I_SettlementOwner Antioch = knights_templar
and I_EventCounter holds_antioch == 1
and I_NumberOfSettlements knights_templar > 0
set_event_counter holds_antioch 0
log MONITOR #2 WORKS
end_monitor
monitor_conditions not I_SettlementOwner Edessa = knights_templar
and I_EventCounter holds_edessa == 1
and I_NumberOfSettlements knights_templar > 0
set_event_counter holds_edessa 0
log MONITOR #3 WORKS
end_monitor
;Detect if settlement has been taken
;Increment event counter
monitor_conditions I_SettlementOwner Jerusalem = jerusalem
and I_EventCounter holds_jerusalem == 0
set_event_counter holds_jerusalem 1
log MONITOR #4 WORKS
end_monitor
monitor_conditions I_SettlementOwner Antioch = knights_templar
and I_EventCounter holds_antioch == 0
set_event_counter holds_antioch 1
log MONITOR #5 WORKS
end_monitor
monitor_conditions I_SettlementOwner Edessa = knights_templar
and I_EventCounter holds_edessa == 0
set_event_counter holds_edessa 1
log MONITOR #6 WORKS
end_monitor
;;;;end
wait_monitors
end_script
Call it test_script.txt and change the last line in the descr_strat:
Code:
script
test_script.txt
This is a good method to try out new things that aren't contingent on other scripting factors or to isolate errors. I have a scripts folder where I keep a few miscellaneous scripts like this. The descr_strat reference line accepts paths, so:
Code:
script
scripts/test_script.txt
works fine.