Hi all,
I have done what suggested in this post
http://www.slembcke.net/forums/viewtopi ... e59c25d639
to predict the path of a body without taking into account collisions.
Now I would like to predict the path by also considering bounces. Is there any way to do that?
Thank you in advance
Andrea
predict the path of a shape considering bounces
-
- Posts: 5
- Joined: Thu Jun 30, 2011 1:22 pm
- Contact:
- slembcke
- Site Admin
- Posts: 4166
- Joined: Tue Aug 14, 2007 7:13 pm
- Contact:
Re: predict the path of a shape considering bounces
Not in general without copying the entire space then stepping the entire thing forward through time. This would be ridiculously expensive.
If you just want to get the path of a bullet bouncing off of static geometry you can represent the bullet using short raycasts and calculate simple elastic collisions from the collision normals. This would be about as expensive as using shape queries.
If you just want to get the path of a bullet bouncing off of static geometry you can represent the bullet using short raycasts and calculate simple elastic collisions from the collision normals. This would be about as expensive as using shape queries.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
-
- Posts: 5
- Joined: Thu Jun 30, 2011 1:22 pm
- Contact:
Re: predict the path of a shape considering bounces
suppose I just would like to take into account bounces against a specific object would it be more feasible? how should I do that? creating another space with the two objects and pushing it forward? is there an easier way?
- slembcke
- Site Admin
- Posts: 4166
- Joined: Tue Aug 14, 2007 7:13 pm
- Contact:
Re: predict the path of a shape considering bounces
That would work, but it sounds pretty complicated to get it right. There isn't really a simpler way to do it.
Can't sleep... Chipmunks will eat me...
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Check out our latest projects! -> http://howlingmoonsoftware.com/wordpress/
Who is online
Users browsing this forum: No registered users and 29 guests