The "exploding" rocket consists of two parts:
1. The body of the rocket moves linearly away from its parent object (the mothership), then disappears by moving off screen (distance = 9999). (see macro_linearMove in zfai.py)
2. At the same time that the rocket disappears, a timer is set to do the following 3 things:
- enable the singularity guns (which cause the "explosion" - the guns themselves are hidden).
- set each gun's timer to play the firing sequence ("explode")
- then disable the singularity guns (until it's enabled again in the next explosion)(see macro_singularityFire in zfai.py)
Also, you can try out the level within the level editor
- copying the part list from checkersLevel-parts.txt
into the "text edit" window
- execute checkersLevel-aiCode.py
using the typical Python command:> python checkersLevel-aiCode.py
which will generate a long list of text, which are AI commands - copy these into the AI code window in the editor.
- now run the level, and tinker with it as much as you like