Monkwarrior
05-13-2006, 09:06
I'm trying to implement different scripts depending on the campaign to be played.
I found in docudemon_conditions one that could be useful:
Identifier: I_MapName
Trigger requirements:
Parameters: map file name
Sample use: not I_MapName world\maps\campaign\sons_of_mars\descr_strat.txt
Description: The qualified file name of the current map relative to the data directory
Battle or Strat: Either
Class: MAP_NAME
Implemented: Yes
Author: Guy
I tried this in this way (export_descr_advice):
;------------------------------------------ ITW Campaign
Trigger ITW_Campaign_Thread_Trigger
WhenToTest SettlementSelected
Condition I_LocalFaction carthage
and I_MapName world\maps\campaign\Hispania_Cartago\descr_strat.txt
AdviceThread ITW_Carthage_Campaign_Thread 0
Result: the advice didn't appear and, or course, the script was not launched.
Then, I tried the negative way:
;------------------------------------------ ITW Campaign
Trigger ITW_Campaign_Thread_Trigger
WhenToTest SettlementSelected
Condition I_LocalFaction carthage
and not I_MapName world\maps\campaign\imperial_campaign\descr_strat.txt
AdviceThread ITW_Carthage_Campaign_Thread 0
Result: the advice appeared in all the campaigns, when carthage faction was selected.
I tried also using the full path (data\world\etc), but the result was the same.
Did anybody use this condition successfully?
Any other method to launch scripts selectively depending on the campaign?
I found in docudemon_conditions one that could be useful:
Identifier: I_MapName
Trigger requirements:
Parameters: map file name
Sample use: not I_MapName world\maps\campaign\sons_of_mars\descr_strat.txt
Description: The qualified file name of the current map relative to the data directory
Battle or Strat: Either
Class: MAP_NAME
Implemented: Yes
Author: Guy
I tried this in this way (export_descr_advice):
;------------------------------------------ ITW Campaign
Trigger ITW_Campaign_Thread_Trigger
WhenToTest SettlementSelected
Condition I_LocalFaction carthage
and I_MapName world\maps\campaign\Hispania_Cartago\descr_strat.txt
AdviceThread ITW_Carthage_Campaign_Thread 0
Result: the advice didn't appear and, or course, the script was not launched.
Then, I tried the negative way:
;------------------------------------------ ITW Campaign
Trigger ITW_Campaign_Thread_Trigger
WhenToTest SettlementSelected
Condition I_LocalFaction carthage
and not I_MapName world\maps\campaign\imperial_campaign\descr_strat.txt
AdviceThread ITW_Carthage_Campaign_Thread 0
Result: the advice appeared in all the campaigns, when carthage faction was selected.
I tried also using the full path (data\world\etc), but the result was the same.
Did anybody use this condition successfully?
Any other method to launch scripts selectively depending on the campaign?