How do different buttons work?
I hope it's as simple as it sounds and I just overlooked something.
edit: to clarify; I need a switch for a tractor beam to reverse directions, and then reverse back when switched again. As it stands, a prop_button only reverses the direction once (with the option of turning on a timer for the switch back). I want to be able to choose when it goes what direction.
and a switch model
Sounds simple enough. Someone find me that damn switch model!
models\props_gameplay\push_button.mdl
the other is switch used in the coop maps
models\props_gameplay\circuit_breaker_box.mdl
models\props_gameplay\circuit_breaker_lever.mdl
Doesn't have animations, so you have to play more with brushes, i.e create func_rotating and parent lever model to the brush.
OnPressed > Door > Open > [Delay]*
OnPressed > func_rotating > Start**
OnPressed > func_rotating > Stop > [Delay]***
choose same delay as lever stops delay, so door opens when lever is fully pulled down.
Stop delay is for lever, when it stops at correct moment
**I don't remember output correctly but you'll find out
That is just quick example for levers, it takes more input/outputs to make more better.
For the lever idea you could ToggleTest the branch at door outputs OnFullyOpened/OnFullyClosed, this will ensure that the direction won't change until the switch is moved all the way. (Providing that you can get the parenting of the func and model to look correct). See here for more information on rotating doors and specifically setting the "pivot" point!.((Although for a full 180deg arc for a circuit breaker it may be best to leave the origin in the center of the brush and align the model base to the center/origin point))... And setting the door flag of UseOpens if its placed "nodraw" over your model will make it appear the player has actually used the lever .... You could also use the "Delay Before Reset" of the door to make a timed lever... ...
Hope that helps you and I didn't start rambling too much!?!
All the outputs work, but only once.
Kaleido wrote:
Ok, I got the lever switch working, but it only triggers once (rotates downward), and then never moves again even though I'm spamming the use button -_-"All the outputs work, but only once.
Well, I'm glad that it at least works once!
I think the issue here (if your using the func_door_rotating idea) is that "UseOpens" obviously does exactly what it says... use opens.. ie use again doesn't close, it opens again... .... .. maybe have two identical func_door_rotating side by side, but mirrored. Have the outputs on both set to do their thing OnFullyOpen and also to close the other one. That way you should always have a "closed" door to open (onuse) .... erm .. now you'll also need to swap the Parent of the Model to the other/sister/mirror door as well... ..
Hell there must be an easier way then all that...
How about trying out this ...
Make sure you parent the moving part of the switch to it, and set the "toggle" flag; that way the player can flip it on and off repeatedly. Use the OnIn and OnOut signals to change the funnel direction. I don't think you need any additional logic control entities, as the toggle function is already built into the button itself.
(The "X axis", "Y axis" and "Distance (deg)" work the same as for the func_door_rotating.)
Someone either explain to me why this doesn't work, or re-upload a working version pleeeease...
i've tried a bunch of things, and none of them work... the one I posted is with the func_rot_button that... doesn't work either... T_T
Kaleido wrote:
This is what I have... ignore the random shit and crappy textures in that room, I deleted the puzzle elements in order to not spoil what my puzzle isSomeone either explain to me why this doesn't work, or re-upload a working version pleeeease...
i've tried a bunch of things, and none of them work... the one I posted is with the func_rot_button that... doesn't work either... T_T
I fixed a lot of things for you.
EDIT: EDITED THE FUNC_BUTTONS
Kaleido wrote:
Someone either explain to me why this doesn't work, or re-upload a working version pleeeease...
You're almost there, actually. You just need to enable the "use activates" and "touch activates" flags. And you may want to make the button brush a bit larger so it's easier to hit.
Here's a modified version with those changes implemented:
That makes me feel so stupid. Note to future self: check flags before asking dumb questions
Thank you soooo much!!!

Also minor correction: I wrote "touch activates" above where I meant "toggle" 
But I assume that you figured that one out already 