
Reference |
With regard to unit clarification, 1 JKU is the equivalent of 1 meter, a time value of 3000.0 msec is the equivalent of 3 seconds and boolean values within are assigned by either a 0 (false) or 1 (true) value. Interestingly, both integer and floating-point numbers seem to be legal values for boolean arguments (but must be of the form 0.0 or 1.0).
Each instinct has a set number of arguments which must be set, in order for the AI character to use that instinct. The following details show examples, as well as listing each argument effect and type.
ReturnHome
This instinct takes no arguments (boolean: the AI character either has this instinct, or it does not)
This instinct forces the character to return to its point of creation (the thing's placement position in the level editor, or alternatively the respawn point, if generated via cog).
This section details how the instinct is initiated. In some cases, a charactor's AI are dependent upon certain actions/events occurring before the instinct is triggered.
Testing has shown that this instinct is initiated if the AI has lost sight of its target for a certain duration or upon having killed its target. Unless the actor has dropped to a level from which it cannot get back up to (see "maxstep" value in the AI Setup line and the Jump instinct), it will always manage to return to its "home pointer"; traversing sloped or small-step stairs poses no problem and obstruction by both 3DO objects and general world-architecture (such as cleaved pillars in-level) are successfully navigated (does not have to have LOS to it's "home pointer").
If the AI was spawned via a "CreateThing()" or similar "create" COG verb, then the AI character will attempt to return to its "ghost" creation/spawn point. The AI can jump over objects to follow a target, but must have the Jump instinct present; the height must also be greater than "maxstep" for the AI to jump over in order to continue following.