Hello,
how can i get a bullet (rigidbody) to bounce like this from a wall(rigidbody):
what parameters do i have to tune?
thanks,
tommy
How to get a "perfect" bounce
-
- Posts: 26
- Joined: Mon Jun 01, 2009 2:21 pm
- Location: Sweden
Re: How to get a "perfect" bounce
You should tweak restitution. A value of one should give a fully elastic bounce.
-
- Posts: 2
- Joined: Fri Jan 07, 2011 6:51 pm
Re: How to get a "perfect" bounce
i tried to set m_restitution to 1. but the ball still bounces in random directions
-
- Posts: 26
- Joined: Mon Jun 01, 2009 2:21 pm
- Location: Sweden
Re: How to get a "perfect" bounce
Oh you are talking about the actual directions.
Restitution has nothing to do with that obviously.
What will control the direction is the normal or the collision.
Is your ball a sphere shape?
If it is a hull or triangulated ball it will not have smooth normals and is thus bound to bounce in a more erratic way. You should not get random directions though. If so then debug what normals you are actually getting.
Restitution has nothing to do with that obviously.
What will control the direction is the normal or the collision.
Is your ball a sphere shape?
If it is a hull or triangulated ball it will not have smooth normals and is thus bound to bounce in a more erratic way. You should not get random directions though. If so then debug what normals you are actually getting.