How can I make a func_rotating behave like this?

SteveN

L1: Registered
Jul 16, 2017
6
6
Hi, I'm working on a pretty sizeable hammer project and have run into a problem; I need a func_rotating to behave like in the attached demonstration but I can't get it to work, I know I could maybe use logic relays to make it switch but that would require a button and I'd like the movement to be looping by itself (kind of like a pendulum in a grandfather clock) I tried sending an input to the brush for OnTrigger > Reverse > "name" > Delay 1.00s but that seems to only do it once
My knowledge of hammer is around intermediate, any help would be greatly appreciated :D
 

puxorb

L69: Emoticon
aa
Dec 15, 2013
531
799
I think you can use the commands "StartForward" and "StartBackward". Maybe you can use a logic_timer set to however long you need it to, and give it two outputs. Lets say the loop lasts 2 seconds, I would do this:

Create a logic timer with a refire interval of 2 seconds.
Have it set to Start Enabled (Or start it with another entity)
In the outputs tab, create these two:

OnTimer>brush>StartBackward>1.00
OnTimer>brush>StartForward>2.00

You would have to play around with these a lot to get the timing right.


I think an even easier solution would be to create a func_door_rotating though. Set its maximum rotation to something like, 90 degrees or less, and give it two Outputs:

OnFullyOpen>!self>Close>0.00
OnFullyClosed>!self>Open>0.00

This solution will have instant acceleration though so it might not be desirable.
 
T

The Asylum

Isn't func_rotating still broken in TF2? I've been using func_door_rotating for all my spinny needs.
 

Startacker!

WANT ME TO BE REAL? MAKE ME.
aa
Jun 15, 2013
647
1,197
Isn't func_rotating still broken in TF2? I've been using func_door_rotating for all my spinny needs.
It got fixed about a year ago.
 

SteveN

L1: Registered
Jul 16, 2017
6
6
I think you can use the commands "StartForward" and "StartBackward". Maybe you can use a logic_timer set to however long you need it to, and give it two outputs. Lets say the loop lasts 2 seconds, I would do this:

Create a logic timer with a refire interval of 2 seconds.
Have it set to Start Enabled (Or start it with another entity)
In the outputs tab, create these two:

OnTimer>brush>StartBackward>1.00
OnTimer>brush>StartForward>2.00

You would have to play around with these a lot to get the timing right.


I think an even easier solution would be to create a func_door_rotating though. Set its maximum rotation to something like, 90 degrees or less, and give it two Outputs:

OnFullyOpen>!self>Close>0.00
OnFullyClosed>!self>Open>0.00

This solution will have instant acceleration though so it might not be desirable.

Alright, I'll give those options a try and play around with the outputs and see how it goes, thanks for the help so far, I'll post the results here later on :)