
At first, I tried to zero the linear and angular velocity upon impact and setGravity to (0,0,0), but this didn't work because of how the solver works... I'm assuming what happens is the object collides, penetrates slightly, I zero the linear/angular velocity, and then the solver applies an impulse to counteract the penetration and the sphere is in motion again. No stick.
The idea I'm running with now is to store the normal of collision upon impact and use a btGeneric6DofConstraint to restrict linear movement to a 2D plane. This isn't working very well either because of the penetration issue... if I set the constraint when the sphere is still slightly inside the cube, then you can't move at all. If I set the constraint too late then the sphere is already out of contact with the cube. Plus, the collision between a sphere and cube is one tiny point and it seems like it's too easy to lose this contact (which breaks the 'sticky' mode).
Any suggestions on how to approach this problem?