🔵Soldier

NPC that attacks Hostiles who also defends itself when attacked.

This behaviour has not yet been migrated for use in multiplayer Experiences.

Soldier

  • When applied to an Asset it will defend the area for hostiles and attack them on sight. Soldier won't attack you unless you attack them first.

Common Uses

  • Patrolling NPC, or non-player character, that confronts hostiles as a line of defense

Communications

Inputs:

Detects specified Tags (default Tag is Hostile, which is added to any object or Avatar that attacks Citizens or Soldiers)

Outputs:

If any of its Tags to Attack are detected, moves toward and attacks the Avatar or Objects with its target Tags, otherwise peaceful

Drawing

Parameters

Options
Details

Patrol Zone - define the space where the Object will walk around. It may step up or down one block at a time. This parameter is visualised with a blue cube Gizmo that adjusts as you enter new X, Y, and Z values.

Walk Speed (slider) - Determines the amount of blocks travelled per second by your Object when walking. This parameter's max value is determined by the ASSET's Speed stat. Run Speed (slider) - Determines the amount of blocks travelled per second by your Object when running. This parameter's max value is determined by the ASSET's Speed stat.

Attack Damage (slider) - Defines how many points of damage your Object will deal with a single hit. The max value of this parameter is determined by the ASSET's Power stat. Attack Speed (slider) - Defines the amount of attacks that can be done per second by the Object. This parameter's max value is determined by the ASSET's Speed stat.

Tags to Attack - Defines which tags the Object will chase and attack if within its range.

Detection Range (slider) - defines the area in which your Object will detect Tags to Attack. This parameter is visualised with a yellow circle Gizmo that adjusts as you move the slider or change the value. The max value of this parameter is determined by the ASSET's Luck stat. Attack Range - Defines how far away the Object needs to be to attack. This parameter is visualised with a red circle Gizmo that adjusts as you move the slider or change the value.

Auto Defense - If set to True, the Object will fight back if it is attacked.

Random Walk Frequency - Determines how often, in seconds, the Object will change direction when patrolling.

Last updated

Was this helpful?

#123: GM 0.11 update - do not publish until public release

Change request updated