Ball in bullet stops moving?

I’m trying to make a game in bullet… it has a ball which rolls around inside a bigger ball. The ball inside is the dynamic object. It rolls around and works perfectly at first, but after a while comes to a complete stop and nothing can convince it to move again. It won’t even fall… I tried deleting the big ball after the small ball had stopped, and the little ball just hung in the air.
Why is this? Bullet problems?

File: www.terragna.com/~plantperson/bullet_problem.blend
Rotate the big ball using arrow key and A and D
Delete the big ball with Space

The ball is deactivated after a while, this is a common optimization in physics engines. Some activation code needs to be added to the motion actuator, so it will move again.

Until it is fixed (next release) you can disable physics de-activation with a python script for now:

import PhysicsConstraints
PhysicsConstraints.setDeactivationTime(0.f)

Erwin

It didn’t work… I attached it to a non-true Always sensor. The console says:

Syntax Error: Invalid Syntax
PYTHON ERROR
File "fix", line 3
PhysicsConstraints.setDeactivationTime(0.f)
                                                            ^

The arrow points to the “f”

PlantPerson,
I was having the same problem and I put this script in and changed the f to 0 then it worked so the final script looked like this:

import PhysicsConstraints
PhysicsConstraints.setDeactivationTime(0.0) 

This should mean that it never gets deacitvated. I’m gonna try it in one of my bigger projects (and probably post again to find help if it doesn’t work with that high complexity :wink: ). Hope it works for your project!

Thanks, GeneralJ, and welcome to elYsiun!

I thought about changing the f, but not being a python expert, I decided to let it alone. (Even though it was a problem.) I guess I just didn’t know what to replace it with. I will try your suggestion.

Ok, I downloaded your file and applied the script. It seems to be working just fine now. You can download an arcive with your revised file and another silly example file I made to test the script here:
http://j-space.homedns.org/blender/yourfilewithscriptfixandmyweakexample.zip

Thanks for the welcome, I’m really exited about all the attention the game engine has been getting lately! I can’t wait to see more cool projects from you guys, and finnish my own. :smiley: