monster_target

XashXT

monster_target

A faithful recreation of the entity from Spirit of Half-Life. Creates an invisible point-based monster that the AIs of regular monsters are aware of.

Spawnflag

SF_MONSTERTARGET_OFF 1 (initially turned off, dead)

Option

frags class of the monster (see Monster Classes and Behaviour).

Usage Details

  • This monster cannot be destroyed in the usual way, because it is intangible and invisible. However, you can turn it on and off, which to AIs looks like it dies. You can also attach this monster using the parent system.
  • The main purpose is to provide a target (which can be inanimate) for NPCs without interfering with the AI operation and interrupting it with a scripted_sequence. For example, you can make friendly NPCs destroy some inanimate strategic barriers set up by the enemy (such as func_breakable). For that, simply place the entity in front of the barrier. The NPCs will try to hit the monster_target, but since it is intangible, they will hit the object behind it instead.
  • Likewise, you can set these monsters up in front of targets in a shooting gallery and turn them off when the targets are hit.