...
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
function findTarget() { // do something here to find a target return targetObject; } function eventStructureReady(structure) { switch (structure.stattype) { case LASSAT: { // fire laser satellite activateStructure(structure,findTarget()); break; } default: { // uhm, panic? } } } |
See also
- structureIdle() – you can use this to manually check whether a structure is idle