Physics - joint rotation limit not working

I have a character with a "head" and a "tail". I attach them together with a pivot joint, but I only want the tail to rotate a maximum of 5 degrees in either direction:

1
2
3
myJoint = physics.newJoint( "pivot", head, tail, head.x, head.y )
myJoint.isLimitEnabled = true
myJoint:setRotationLimits( -5, 5 )
views:1353 update:2011/9/28 8:56:32
corona forums © 2003-2011