Teleporting

sparkprime
Posts: 508
Joined: Fri May 30, 2008 2:51 am
Location: Ossining, New York

Teleporting

Post by sparkprime »

If I need to move an object instantaneously from one place to another, should I be deleting its physical presence and recreate it in the new position? Also what should I do to avoid teleporting something inside something else.

thanks
Wavesonics
Posts: 71
Joined: Thu May 22, 2008 8:03 pm

Re: Teleporting

Post by Wavesonics »

This is a good question I would like to know the answer as well, is there a preference which will be safer in keeping the simulation stable?
yassim
Posts: 12
Joined: Tue Jun 26, 2007 2:33 am

Re: Teleporting

Post by yassim »

While I havn't tried it in bullet, I would be suggesting to do a reinsert (take it out, then put it back in. You may have to heart beat it in between).
Do check if you teleporting into something, try using the shape as a query before doing the insert.
ihar3d
Posts: 25
Joined: Wed Jan 23, 2008 11:28 am

Re: Teleporting

Post by ihar3d »

Try to use translate(const btVector3& v) method in btRigdBody.
sparkprime
Posts: 508
Joined: Fri May 30, 2008 2:51 am
Location: Ossining, New York

Re: Teleporting

Post by sparkprime »

will translate tear a path through the other objects smashing them all out of the way?