Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Animation timer

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

If you intended to correct an error in the post then please contact us.

Recommended Posts

Good question..
I dont think there is a specific way of calculating the frame time but you should probably hard code it..Like as hes reloading the gun it would be slower than hes firing it..just play around thats all.

Share this post

Link to post
Share on other sites
Work out the speed you want the animation to run at. For example, if you want it to take 1 second for him to fire - then you want to do one frame of the animation every 1/9th of a second.

You will probably have a timer in place already to time other stuff - so every time 1/9th of a second has gone by, display the next frame.

If for some reason you are getting less than 9 frames per second, simply skip a frame or two depending on the speed. Obviously this applies for everything at any speed. Once you have a speed and a time you can adjust things accordingly - the same principle applies for distance, speed, forces etc.

"Absorb what is useful, reject what is useless, and add what is specifically your own." - Lee Jun Fan

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!