
Originally Posted by
DolToX
Realy nice !
Can you show us how you use applyangforce to rotate the thruster ?

Yes:
Code:
###Angle of Thruster Pods
if(abs(Pitch)>90){
UpsideDown=-1
}else{
UpsideDown=1
}
GoAngle=40*(S-W)
TurnAngle=20*(D-A)
Torque=70
RPitch=clamp(UpsideDown*(RPod:angles():pitch()+GoAngle+TurnAngle+SpeedCounter+SpinCounter),-160,160)
LPitch=clamp(UpsideDown*(LPod:angles():pitch()+GoAngle-TurnAngle+SpeedCounter-SpinCounter),-160,160)
APitch=clamp(UpsideDown*(APod:angles():pitch()+GoAngle+SpeedCounter),-160,160)
RPod:applyAngForce(ang(RPitch+$RPitch*4,0,0)*Torque)
LPod:applyAngForce(ang(LPitch+$LPitch*4,0,0)*Torque)
APod:applyAngForce(ang(APitch+$APitch*4,0,0)*Torque) Spin Counter is calculated using the yaw angular velocity.
Speed Counter is calculated using the forward speed.
You need to make sure you find the forward direction vector of your thruster, or it will angle the wrong way. The best way is to wire it up with no thrust, no-grav your thruster, and press W to see which way it rotates.

Originally Posted by
OMFGMOD
Well the one in the pictures are not the same in your video =D but still nice job though
you deserve a medal
The one from the pictures IS the one from the video, just upgraded a little. But thanks lol

Originally Posted by
jayg20769
Very smooth control! This is really nice, great work!
Now, you said that you used applyAngForce to control the thrusters, but how did you bind the thrusters to the craft? ballsocket?
for the front 2 thrusters, I just axised them on. The rear one I had to double ballsocket. Then I used Adv ball socket with -90 min and 90 max on all 3 to prevent them from spinning too much. Limiting them with the adv ballsocket REALLY helped reduce freakouts.
Bookmarks