Opening doors with func button: Difference between revisions
Jump to navigation
Jump to search
m (I proof-read it.) |
No edit summary |
||
(One intermediate revision by one other user not shown) | |||
Line 1: | Line 1: | ||
{{LanguageBar}} | |||
=Create the door(s)= | =Create the door(s)= | ||
This will be the door that the button will open. A [[func_door]], a [[prop_door_rotating]], or a combination can be used. Just give the door a name, and maybe uncheck "use opens" so that players have to use the button. It might be a good idea to set the doors' auto-close time to never (-1). | This will be the door that the button will open. A [[func_door]], a [[prop_door_rotating]], or a combination can be used. Just give the door a name, and maybe uncheck "use opens" so that players have to use the button. It might be a good idea to set the doors' auto-close time to never (-1). | ||
=Create the button= | =Create the button= | ||
Create a [[func_button]] that will open the door(s). Add an output for OnPressed that will fire the Open (or Toggle) input on the doors. The buttons return time can be used with OnIn and OnOut to open and close the doors in that amount of time. Another way to toggle the doors with each press of the use key would be make your button itself a [func_door]. | Create a [[func_button]] that will open the door(s). Add an output for OnPressed that will fire the Open (or Toggle) input on the doors. The buttons return time can be used with OnIn and OnOut to open and close the doors in that amount of time. Another way to toggle the doors with each press of the use key would be make your button itself a [[func_door]]. | ||
[[Category:IO System]] | [[Category:IO System]] |
Latest revision as of 05:21, 29 June 2025
Create the door(s)
This will be the door that the button will open. A func_door, a prop_door_rotating, or a combination can be used. Just give the door a name, and maybe uncheck "use opens" so that players have to use the button. It might be a good idea to set the doors' auto-close time to never (-1).
Create the button
Create a func_button that will open the door(s). Add an output for OnPressed that will fire the Open (or Toggle) input on the doors. The buttons return time can be used with OnIn and OnOut to open and close the doors in that amount of time. Another way to toggle the doors with each press of the use key would be make your button itself a func_door.