1
vote
2answers
110 views

What torque should I apply in Bullet to maintain a vertical orientation?

I have a RigidBody in Bullet. Each frame, I want to apply torque to correct its orientation toward an upright position (i.e. near-zero pitch and roll). I know its angular velocity and orientation. ...
1
vote
0answers
26 views

PhysX - Revolute joint around unit vector

I'm using a right-handed coordinate system with (0,0,-1) = forward, (1,0,0) = right and (0,1,0) = up. PhysX version is 3.3.0. I have a unit vector which represents the axis around which my actor is ...
4
votes
1answer
231 views

How do I make a cube move by rolling?

I am learning jMonkeyEngine by making some small games with it. I have a simple rectangular cube that I want the player to be able to roll around the game world. When he presses the arrow keys, the ...
0
votes
0answers
199 views

Spin wheel with gesture in Andengine

I want to implement Fortune wheel in Andengine. The wheel would start spinning based on the speed of a finger fling. Then it would stop slowly like real Fortune wheel. What I am able to do now is to ...
5
votes
3answers
329 views

How do you calculate the rotational velocity of a flying object?

When a arrow shaped object is fired it slowly adjusts it's rotation to match the direction it is moving. But what is the actual physics behind it? The question is: How many degrees does the ship ...
1
vote
1answer
291 views

Making player movement direction follow players facing direction

if (controller.isGrounded) { moveDirection = new Vector3 (Input.GetAxis ("Horizontal"), 0, Input.GetAxis ("Vertical")); moveDirection = ...
1
vote
1answer
713 views

Need to translate a Rotation Matrix to Rotation y, x, z OpenGL & Jitter for 3D Game

I am using the Jitter Physics engine which gives a rotation matrix: M11 M12 M13 M21 M22 M23 M21 M32 M33 And I need it so OpenGL can use it for rotation GL.Rotate(xr, 1, 0, 0) GL.Rotate(yr, 0, 1, ...
5
votes
1answer
482 views

Calculate gears rotation for a realtime simulation

Hi I'm trying to do a game with real time simulations of gears. There is a big Gear with inside a smaller gear. I managed to draw gears with different diameters but equal size teeth, but if i try to ...
1
vote
1answer
377 views

Rotating a cube using jBullet collisions

How would one go about rotating/flipping a cube with the physics of jBullet? Here is my Draw method for my cube object: public void Draw() { // center point posX, posY, posZ float ...
6
votes
2answers
2k views

How to implement friction in a physics engine based on “Advanced Character Physics”

I have implemented a physics engine based on the concepts in the classic text Advanced Character Physics by Thomas Jakobsen. Friction is only discussed very briefly in the article and Jakobsen himself ...
2
votes
1answer
2k views

How to control a spaceship near a planet in Unity3D?

Right now I have spaceship orbiting a small planet. I'm trying to make an effective control system for that spaceship, but it always end up spinning out of control. After spinning the ship to change ...