I am having trouble making a stormdoor script_object open on an angle. As you can see in the screenshot, it will move on two axis just fine. But somehow Y and Z seem to be rotating on the same axis after X has been rotated. Here is a test map with the doors and a rotation tester. Any help to get the doors angled down on the Z axis (actually it is up) when open would be great!
I will help you with it, Tom. But right now I am at work and no map editor at my disposal. I have been doing lots of brush rotation myself in my map. By the way, Great TUTS on your website! Congrates!
Try using rotateZupto or rotateZdownto to make the angle work, have you tried those?
well when you make a script object it's angles are ( 0 0 0 ) so if you make the doors flat not angled then in script you change it to the angles you need then rotate x is pitch and y is a flat spin or yaw and z is side or roll . So if the doors top to bottom was 0 to 90 when you made it then after you set the angles of it from script you should be able to rotate it on the z axis . I will download your zip and have a go at it .
main:
level waittill prespawn
exec global/ambient.scr mohdm1
$sd1_lt_origin time 2
$sd1_rt_origin time 2
$sd1_lt time 2
$sd1_rt time 2
$sd1_rt bind $sd1_rt_origin // bind script_object door brush to script_origin
$sd1_lt bind $sd1_lt_origin // bind script_object door brush to script_origin
thread stormdoor1_mover
level waittill spawn
end
//------------------------------------------
// storm door 1
//------------------------------------------
stormdoor1_mover:
$sd1_trigger waittill trigger
$sd1_speaker playsound door_wood_open_move
$sd1_lt_origin rotateXup -90 // rotate script_origin
$sd1_rt_origin rotateXup 90
$sd1_lt_origin rotateYup -6.5
$sd1_rt_origin rotateYup 6.5
$sd1_lt rotateYup -6.5 // rotate script_object door
$sd1_rt rotateYup 6.5
$sd1_lt_origin move
$sd1_rt_origin move
$sd1_lt move
$sd1_rt waitmove
$sd1_speaker playsound door_wood_open_stop
wait 15
$sd1_speaker playsound door_wood_close_move
$sd1_lt_origin rotateXdown -90 // rotate script_origin
$sd1_rt_origin rotateXdown 90
$sd1_lt_origin rotateYdown -6.5
$sd1_rt_origin rotateYdown 6.5
$sd1_lt rotateYdown -6.5 // rotate script_object door
$sd1_rt rotateYdown 6.5
$sd1_lt_origin move
$sd1_rt_origin move
$sd1_lt move
$sd1_rt waitmove
$sd1_speaker playsound door_wood_close_stop
goto stormdoor1_mover
end
// Note: door brushes are at 6.5 degrees in the map.
Placing the script_origins on either side of the doors is a pain--and still not perfect. But, the doors do open on an angle now. It appears that rotating, or angling, script_objects on three axis is not possible!
We tried that JV and no matter what we did the door would rotate on the x axis ok but if you tried the y or z axis it aways changed the yaw we could not get it to roll properly . It remained level after rotateing on the x axis . Tom's idea was a good one to rotate the door and have a script origin to bind to to roll it . Actually I think Tom rotated it on the x axis with the script origin and then rolled the door .
tltrude wrote:I bet you can't get your chopper to do a hammerhead stall with a half twist! Did you script it's angles, or is it done with a spline path?