npc_template_maker
Jump to navigation
Jump to search
Code classes:
CTemplateNPCMaker
CBaseNPCMaker
CBaseEntity
(all ents)
npc_template_maker
is a point entity present in some Source games. It makes a clone of an NPC that's placed inside Hammer, and copies all of its properties and outputs.
Flags[edit | edit source]
- 64: Do Not Drop - Makes the NPC fall to the ground instead of teleport to it.
- 256: Always use radius spawn - If Radius is non-zero, the entity will spawn the NPC inside that radius.
- 512:
Don't preload template models- Does not function.
Keyvalues[edit | edit source]
- Name of template NPC
(TemplateName)
<target_destination>
- NPC to make clones of.
- Radius
(Radius)
<float>
- If Always use radius spawn is set or the SpawnNPCInRadius input is sent, the entity will try to find empty space within this radius to spawn NPCs.
- Name of Destination Group
(DestinationGroup)
<target_destination>
- Optionally, an
info_npc_spawn_destination
to spawn the NPCs at instead of the entity origin. If multipleinfo_npc_spawn_destination
s of the specified name exist, the destination criteria below are used to choose which one to spawn the NPCs at. - Dest. Criterion
- Visible to player?
(CriterionVisibility)
<choices>
- If using multiple destinations of the same name, determine if the spawns should be visible to the player.
- 0: Yes - NPCs will phase into existence right before the player's eyes.
- 1: No - NPCs must not be visible when spawning.
- 2: Don't care
- Dest. Criterion
- Distance to player?
(CriterionDistance)
<choices>
- If using multiple destinations of the same name, determine the ideal spawn by its distance to the player.
- 0: Nearest
- 1: Farthest
- 2: Don't Care
- Minimum spawn distance from player
(MinSpawnDistance)
<integer>
- If using Nearest or Farthest for Distance to player, spawns which are within this distance are considered too close.
Inputs[edit | edit source]
- SpawnNPCInRadius
- Spawns an NPC within Radius.
- SpawnNPCInLine
- Spawns NPCs together in a line. Works best when sent multiple times at once.
- SpawnMultiple
<integer>
- Makes the specified number of NPCs all at once.
- ChangeDestinationGroup
<target_destination>
- Sets Name of Destination Group.
- SetMinimumSpawnDistance
<integer>
- Sets Minimum spawn distance from player.