Half-Life: Alyx Workshop Tools/Level Design/ Point Template

From Valve Developer Community
Jump to: navigation, search
Wikipedia - Letter.png
This article has multiple issues. Please help improve it or discuss these issues on the talk page. (Learn how and when to remove these template messages)
Dead End - Icon.png
This article has no Wikipedia icon links to other VDC articles. Please help improve this article by adding links Wikipedia icon that are relevant to the context within the existing text.
January 2024

point_template

Introduction

The point_template is an entity that can be used to spawn other entities when triggered. In Half-Life: Alyx, point_templates can be properly used to prepare NPCs for when a player passes a trigger, to spawn certain items such as ammo or puzzle items when the player interacts with something, among other things. Each point_template can have up to 64 other entities tied to it.

*It is important to note that each entity tied to the point_template must be named, as well as the point_template itself.

Setup

This section will teach you how spawn, & set-up a proper point_template. In this example, 3 combine soldiers will spawn when the player passes through a trigger.

  • Place down an Entity using Shift + E. Change the Entity class to a point_template
  • Give the point_template a suitable name. This example will use the name "template_3combine"

[Insert Image Here]

  • Spawn in the combine soldiers with the Entity class npc_combines_s. Give each a unique name. (Note: each soldier will spawn where you place them in the editor, NOT where the point_template is!)
  • In the point_template properties (double click on it), designate each combine soldier as one of the templates by putting in their names in each field (Ex: Template 1 - "otis")

[Insert Image Here]

  • Create a brush where you want your trigger to be, and once created press Crtl + T to turn the brush into a trigger entity.

Designate the class as a trigger_once. This is to prevent spawning of the combine multiple times (unless you want this to happen!). Name the trigger.