Next: Hitscan Module, Previous: AI Station, Up: AI [Contents][Index]
Add to an object representing an AI guard or cannon fodder. This should be an empty object with a 3D model of a guard parented to it. By "Guard" we mean an AI that should stay in a given area or near a given object, and attack enemies that provoke it. To use this effectively, we recommend also adding a NavModule or similar, since this guard will probably need to get around. Also, add some sort of combat component, or attach a turret so it can do harm.
GameObject objectiveWhat are we trying to guard?
float objectiveSearchTimeHow often do we search for our objective by tag? (Only occurs if a Guard Objective Tag is defined)
Default value: 2
GameObject killTargetWho you wan’ me kill? (Assigns a target that already exists in the scene, good for scripted events)
LayerMask obstructionMaskWhen we’re looking for our target, what collision layers can block our view?
float guardRangeHow far from my objective can I travel?
Default value: 30.0f
float guardingRotationHow far do I turn, in degrees, while guarding a position?
Default value: 30.0f
float rotationVarianceHow varied, in degrees, is that rotation?
Default value: 15.0f
float wanderIntervalHow many seconds between patrol times?
Default value: 15.0f
float wanderWalkTimeHow long do I walk for?
Default value: 3.0f
bool autoLookAroundDo I change orientation automatically?
Default value: true
bool wanderDo I wander about the area?
Default value: true
bool debugShould I output information to the console?
Default value: false
Enables hunting mode, where we will try to go to the target’s last known position
Disables hunting mode, so normal target following behavior willbe used instead
Causes the Guard Module to immediately begin wandering to a new location.
Causes the Guard Module to immediately randomize it’s orientation based on the parameters supplied on the component.
Instantly clear’s the Guard Module’s objective and kill target.
If an object with the given tag is found, target that!
Argument: The tag of the object you wish to target.
GameObject objectiveWhat are we trying to guard?
float objectiveSearchTimeHow often do we search for our objective by tag? (Only occurs if a Guard Objective Tag is defined)
Default value: 2
GameObject killTargetWho you wan’ me kill? (Assigns a target that already exists in the scene, good for scripted events)
LayerMask obstructionMaskWhen we’re looking for our target, what collision layers can block our view?
float guardRangeHow far from my objective can I travel?
Default value: 30.0f
float guardingRotationHow far do I turn, in degrees, while guarding a position?
Default value: 30.0f
float rotationVarianceHow varied, in degrees, is that rotation?
Default value: 15.0f
float wanderIntervalHow many seconds between patrol times?
Default value: 15.0f
float wanderWalkTimeHow long do I walk for?
Default value: 3.0f
bool autoLookAroundDo I change orientation automatically?
Default value: true
bool wanderDo I wander about the area?
Default value: true
bool debugShould I output information to the console?
Default value: false
Enables hunting mode, where we will try to go to the target’s last known position
Disables hunting mode, so normal target following behavior willbe used instead
Causes the Guard Module to immediately begin wandering to a new location.
Causes the Guard Module to immediately randomize it’s orientation based on the parameters supplied on the component.
Instantly clear’s the Guard Module’s objective and kill target.
If an object with the given tag is found, target that!
Argument: The tag of the object you wish to target.
Next: Hitscan Module, Previous: AI Station, Up: AI [Contents][Index]