I am new to Box 2d and using this with cocos2d in iphone. I have a bird which has to fly on top of screen in landscape mode for which i set the gravity as gravity.Set(0.0f,10.0f). another object is tied with bird using ropejoint.I have to balance the two tied object as bird is flying with that object.But due to gravity the other object also goes towards top as the bird do. Using equal and opposite force on tied object in draw method solve the issue.
The problem is that using accelerometer to move bird and tied object along X axis(in landscape mode) disturb the equilibrium between tied object and bird and object seems to follow the bird.I want to maintain distance of equilibrium even during movement with accelerometer.
🙁 Dont know what to do..
The problem is that using accelerometer to move bird and tied object along X axis(in landscape mode) disturb the equilibrium between tied object and bird and object seems to follow the bird.I want to maintain distance of equilibrium even during movement with accelerometer.
🙁 Dont know what to do..