# Future Position of a Ball/ time takes to travel

This topic is 3206 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

## Recommended Posts

Hi I am working on a soccer game and trying find the time to travel a distance when applied certain amount of force. How do I calculate the friction for the environment I am using bullet physics engine. It has damping , angular damping and bunch of other params. such as friction , hit friction and what not. I have read the APIs and it says that damping is the only resistance that is applied to the objects. So i set my friction to (-damping) but it does not produce right values. time to travel Ogre::Real speed = force /m_Mass; Ogre::Real DistanceToCover = A.distance(B); Ogre::Real friction = ? Ogre::Real term = speed*speed + 2.0f*DistanceToCover*friction; //if (u^2 + 2as) is negative it means the ball cannot reach point B. if (term <= 0.0) return -1.0f; Ogre::Real v = Ogre::Math::Sqrt(term); //it IS possible for the ball to reach B and we know its speed when it //gets there, so now it's easy to calculate the time using the equation // // t = v-u // --- // a // return (v-speed)/friction; Thanks a bunch in advanced.

1. 1
2. 2
Rutin
19
3. 3
4. 4
khawk
14
5. 5

• 13
• 26
• 10
• 11
• 44
• ### Forum Statistics

• Total Topics
633743
• Total Posts
3013643
×