Posted: Wed Jun 13, 2007 8:51 am
hmmm...yes
update is run only when the AI gets time to do it ...dunno which mechanism would be more robust.
a- resetting the state after each itteration, or
b- updating the script.
like this.
I added the pause at enter to prevent the device from triggering too soon after launch.
update is run only when the AI gets time to do it ...dunno which mechanism would be more robust.
a- resetting the state after each itteration, or
b- updating the script.
Code: Select all
GLOBAL {ENTER = ("setStateTo: PULSE"); UPDATE = (); EXIT = ();};
PULSE = {
ENTER = ("pauseAI: 5");
UPDATE = (scanForHostiles, "pauseAI: 3");
"TARGET_FOUND" = (performHyperspaceExit, "pauseAI: 2");
"NOTHING_FOUND" = ("pauseAI: 2", becomeExplosion)
EXIT = ();};
I added the pause at enter to prevent the device from triggering too soon after launch.