momentary_rot_button

J-M v2.5.5

BANNED
BANNED
Joined
Feb 26, 2005
Messages
5,675
Reaction score
1
Age
35
Location
Nijmegen, the Netherlands.
Is there any way to reverse the direction of rotation for this entity? Entering a negative value in the distance (# of degrees rotated) field gives rather odd and undesired results...
 

Thothie

Administrator
Staff member
Administrator
Moderator
MSC Archivist
Joined
Apr 8, 2005
Messages
16,342
Reaction score
326
Location
lost
Odd, that should work fine... Only other options that I know of are X-axis and Y-axis flags. Try a monetary door?

I suppose it'd be a pain, but if need be, you can get the same effect with some env_renders, a func_button, and a func_door_rotating.
 
  • Thread starter
  • Banned
  • #3

J-M v2.5.5

BANNED
BANNED
Joined
Feb 26, 2005
Messages
5,675
Reaction score
1
Age
35
Location
Nijmegen, the Netherlands.
OK, I got it. I used a hilarious workaround.

What I was trying to achieve was this: A lever (momentary_rot_button) opens two doors (both also momentary_rot_button, set up using the Door Hack). The problem was that both doors would rotate in counterclockwise direction around the z-axis, meaning one would open 'towards' you and one 'away' from you. Obviously that looks like ass.

What I did was: I rotated the door that I wanted to rotate in clockwise direction (ie. also 'away' from me) 90 degrees counterclockwise around the y-axis. Then I set its rotation axis to the x-axis. And, finally, I set "angles" to "90 0 0", which effectively means the door would be rotated 90 degrees clockwise around the y-axis in-game, restoring it to its original position. And it worked!

In Hammer, it looks like this. In BSP Viewer, it still looks as if it's not going to work (note "spawnflags" = "65", which is "Door Hack" (1) plus "X-Axis" (64)).
But in-game, it actually works! And both doors now rotate in the same direction! Took me well over two hours, but I'd say it was worth it.

Note: It took me so long to get this right because I had to figure out which number of the "angles" value does what. From what I learned (these insights might be useful),
  • The first value causes clockwise rotation around the y-axis (as seen in the side (x/z) view).
  • The second value causes counterclockwise rotation around the z-axis (as seen in the top (x/y) view).
  • The third value causes counterclockwise rotation around the x-axis (as seen in the front (y/z) view).

One would expect that the three values of the "angles" field would represent either clockwise or counterclockwise rotation around the x-, y- and z-axes, respectively, and not in the above order (yzx), randomly clock- or counterclockwise... Oh well.
 
Top