angelpopangel
02-07-2008 15:53:35
Hi,
i am coding a small game in which you have to control a ball on a moving table. You can control the table with the mouse, rotating it around x- and z-axis. Pivot is the center of the table.
I tried to make the table static (no body) and control it by ->pitch() and ->roll().
After tweaking billions of parameters in the worldsystem, the ball rolls satisfying on the table. I always had the prob, that the ball fell through the table when moving the mouse too fast.
But I managed it that the ball stays on top as long as it doesn't fall over the edge.
Now my problem: When the ball comes near the edge of the table and I make a medium to fast move upwards with the edge the ball goes up as if shot with a cannon.
Now my question: Did I go a wrong way from the start? Must I apply forces to the table instead of rotating node/geom for it?
And if yes, how can I make the table react to the forces but NOT bouncing back, when the ball lands on it after being midair and ignore gravity?
Sorry, in case I am a bit unclear. Must be the language and I just lost the Euro2008-Final
Thanks to anyone who is willing to help in advance.
Cheers, Angel
P.S.: The ball only bounces back that extreme, if "hit" with the table. If the ball rushes down from 2435kilometers high onto the table, the ball doesn't bounce
i am coding a small game in which you have to control a ball on a moving table. You can control the table with the mouse, rotating it around x- and z-axis. Pivot is the center of the table.
I tried to make the table static (no body) and control it by ->pitch() and ->roll().
After tweaking billions of parameters in the worldsystem, the ball rolls satisfying on the table. I always had the prob, that the ball fell through the table when moving the mouse too fast.
But I managed it that the ball stays on top as long as it doesn't fall over the edge.
Now my problem: When the ball comes near the edge of the table and I make a medium to fast move upwards with the edge the ball goes up as if shot with a cannon.
Now my question: Did I go a wrong way from the start? Must I apply forces to the table instead of rotating node/geom for it?
And if yes, how can I make the table react to the forces but NOT bouncing back, when the ball lands on it after being midair and ignore gravity?
Sorry, in case I am a bit unclear. Must be the language and I just lost the Euro2008-Final
Thanks to anyone who is willing to help in advance.
Cheers, Angel
P.S.: The ball only bounces back that extreme, if "hit" with the table. If the ball rushes down from 2435kilometers high onto the table, the ball doesn't bounce