Input/Output System

Now We're gonna understand the basic of the I/O System. Its easy but very useful for the beginners.

What is the I/O System ?

Well We can call it the new version of the old "Target" field in hl1. But now more advanced, making it easy to use.

The Meaning of Input and Output

Ok. Output is like an order given to something (entities) that must be done. Example. To turn a light off you can make a button that fire an output telling the light to turn off.

Input I'll call input the act of receive an order and do it. If a button tells the light to turn off via a output the light will turn off (input).

Creating an Output

First create a light a give it a name.. I'll use "Light" (without the quotes)

Now We're gonna create the output. Just create a brush a make it a func_button... Then go to Outputs border and click in Add...

Ok, lets see the use of each field:

My Output Named Here you set the way to fire the output. In this case "OnPressed" (if you choose "OnDamaged" the button will fire the output when damaged ...)

Targets Entities Named The targeted entity... here Light

Via This Input The action, what the button will make the light do? choose TurnOff to turn the light off... (In this tutorial the light will spawn "On" )

With a parameter override of Not used in this case... (It is used to set other kind of input like if you wanna kill a citizen (npc_citizen) via a button (output) you will use the input "SetHealth" and here will set 0 (0 is the life of the npc after the output).

After a Delay in Seconds of If you want a delay before firing the output this is the place.

Once Only Mark this option and the output will be fired just one time.

news post image

The Input

The Input border shows to you information about the output that the light is receiving. If you double click in the input will be redirected to the output's entity properties.

news post image

Just remember that the output is the order given to an entity and input is the act of receiving and doing the output. There are other outputs like OnDamaged, Display.... just create the output set the target and choose the output. (most of them are self explanatory)..

I hope you understand it.


View comments ( 3 )

Back to top