Page 1 of 1
Help with trigger
Posted: Mon Jan 04, 2021 4:22 pm
by Ezequiel1996
hi guys i need to have a trigger where in a certain turn, especific units of the AI change their behavior and starts moving towards an specific hex.
I need help with the lua scripting, i didn't found a trigger like that in the dlc's, how i should achieve that? what would be the script for this?
Re: Help with trigger
Posted: Tue Jan 05, 2021 3:53 am
by dalfrede

- AIScrpt1.jpg (256.51 KiB) Viewed 743 times
Re: Help with trigger
Posted: Tue Jan 05, 2021 3:56 am
by dalfrede

- AIScrpt2.jpg (208.47 KiB) Viewed 741 times
It appears the triggers can be done without using LUA at all.
Re: Help with trigger
Posted: Tue Jan 05, 2021 4:39 am
by Ezequiel1996
thanks dalfrede, what tolerance means? its the turns that have to pass for that unit to start moving?
Re: Help with trigger
Posted: Tue Jan 05, 2021 5:01 am
by dalfrede
Duration is the number of turns the command will run.
Such as 'Patrol' for 5 turns, then goto next command.
Tolerance is for 'Base'.
ie if you are within 'Tolerance' you are at the Base, and will reinforce [assuming Harasser mode].
Base may have some additional uses.
Some things will have to be tested to get right, such as does 'Duration=5' mean mean next command starts on turn 5 or turn 6.