Buoyancy rotation control

atsakir

02-03-2006 11:15:25

I am working on a project where i move a boat inside a river. When the boat collides with the banks, it "rocks" obviously. I want to limit the roll and pitch of the boat so that it doesn't exceed certain limits (say 5-10 degrees) I tried using AngularDamping to do that but it only controls how fast the pitch and roll return to 0. I thought about putting "if" statements to limit the increase of rotation around the X and Z axes but I figure that if I do that the boat will stay at the top limit of rotation as long as the relevant torque (or is it Omega in this case?) continues to increase or decrease. Any Ideas?

Horizon

02-03-2006 16:56:54

Do it in a similar way as limiting a joint. Try to calculate the force necessary to stop the boat in that position and apply those.

walaber

02-03-2006 23:03:41

or make a custom joint that limits rotation about the axis' you are interested in.