Half-Life: Alyx Workshop Tools/Level Design/Buttons

From Valve Developer Community
< Half-Life: Alyx Workshop Tools‎ | Level Design
Revision as of 20:17, 21 April 2020 by XBLAH (talk | contribs) (Created page with "== Introduction == This tutorial will teach you how to create buttons for HL:A based mods. == Setup == Create a test room. Insert a '''prop_dynamic'''. For this tutorial, s...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Introduction

This tutorial will teach you how to create buttons for HL:A based mods.

Setup

Create a test room. Insert a prop_dynamic. For this tutorial, set its model to models/props/button_1_pusher.vmdl

HLA SDK Buttons Img1.png

Insert a func_physical_button mesh entity. Match its volume to the model you chose for the prop_dynamic and, for this tutorial, set the following properties:

Key Value
Name button_pusher
Move direction <align it with the push direction>
Speed 10
Delay Before Reset 0
Use sound Button_Basic.Press

HLA SDK Buttons Img2.png

In the outputs, add the following output:

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

Select the prop_dynamic again and set its Parent Name to button_pusher.

Finishing up

Compile and run your map, and you should have a working button.