This article relates to the game "Half-Life: Alyx". Click here for more information.
This article relates to the workshop tools for "Half-Life: Alyx". Click here for more information.
This article's documentation is for Source 2. Click here for more information.

Difference between revisions of "Half-Life: Alyx Workshop Tools/Level Design/Trigger Detect Bullet Fire"

From Valve Developer Community
Jump to: navigation, search
(Added HLATools page template)
Line 1: Line 1:
 +
{{HLATools page|leveldesign=1}}
 
== Introduction ==
 
== Introduction ==
  
Line 27: Line 28:
  
 
Compile and run your map, and you should have a trigger that, whenever a bullet passes it, it will output ''OnDetectedBulletFire''.
 
Compile and run your map, and you should have a trigger that, whenever a bullet passes it, it will output ''OnDetectedBulletFire''.
 
[[Category:Half-Life:_Alyx_Workshop_Tools/Level_Design]]
 
[[Category:Half-Life:_Alyx_Workshop_Tools]]
 

Revision as of 20:44, 27 May 2020

Introduction

This tutorial will teach you how detect if a bullet passes a volume.

Setup

Create a test room. Insert a trigger_detect_bullet_fire mesh entity. If you only want to detect player fire, check the property Player Fire Only.

In the outputs, add the following output:

My Output Target Entity Target Input Parameter Delay
OnDetectedBulletFire <targetEntity> <input> 0.00

Finishing up

Compile and run your map, and you should have a trigger that, whenever a bullet passes it, it will output OnDetectedBulletFire.