I'm having a weird problem with the physics engine. I'm trying to build a very straight-forward setup with a ball, which I want to push around the level. However, as I move the ball, I quickly hit an invisible box around the ball, preventing movement beyond a small distance. It doesn't matter where I place the ball in the level... the box is always there around the starting position of the ball.
My level consists of only 3 objects: a skybox, a terrain map, and the ball.
Am I missing some settings that are constraining the ball to a bounding box?
I'm including the code I'm using to setup and run the ball:
------------------------------------------------------------------
//**************************************************************
// action for initing and running the ball
//**************************************************************
action aBall_InitAndUpdate ()
{
// setup physics body for the ball
phent_settype(my, PH_RIGID, PH_SPHERE);
phent_setmass(my, 5, PH_SPHERE);
phent_setfriction(my, 50);
phent_setdamping(my, 0, 0);
phent_setelasticity(my, 75, 100);
my.shadow = on;
my.passable = off;
// update loop of the car
while (1)
{
if (key_cuu == ON)
{
phent_addvelcentral(my, vector(-10, 0, 0));
}
if (key_cud == ON)
{
phent_addvelcentral(my, vector(10, 0, 0));
}
if (key_cul == ON)
{
phent_addvelcentral(my, vector(0, -10, 0));
}
if (key_cur == ON)
{
phent_addvelcentral(my, vector(0, 10, 0));
}
if (key_pgup == ON)
{
phent_addvelcentral(my, vector(0, 0, 10));
}
if (key_pgdn == ON)
{
phent_addvelcentral(my, vector(0, 0, -10));
}
wait(1);
}
}
------------------------------------------------------------
Thanks for any help!
-Doug