Jump to content
  • Advertisement
durianodour

Java Fixed time for game to model physics

Recommended Posts

Hi, I am a newbie game developer. I need to develop a simple 2D game, it is really simple. 

I have a Human model that should jump every n seconds.

1. User sets different several options in settings. The first option is the game time and the second option is jump count.

2. The Game engine should determine how much time is required to model one single jump, simply by dividing gameTime/jumpCount. As a result we will find the time per one jump.

3. Single jump has some kind of physics. When the human model jumps, it should bend the elbow, knees. Jump starts from the bottommost point to some top point. Up and down. But this doesn't really important and all physics should be considered by moving some point up and down. 

I cannot figure out how should I build my game loop and physics processing to respect user options. If a device cannot draw or process physics at desired time it should be laggy, but the whole game time should as a user has set in settings.

Please suggest a strategy to implement this correctly.

Thanks

Share this post


Link to post
Share on other sites
Advertisement

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • 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!