Delta Time

This is a place for everything and nothing.

Moderator: PPS-Leaders

Post Reply
User avatar
beni
Baron Vladimir Harkonnen
Posts: 949
Joined: Tue Oct 03, 2006 9:15 am
Location: Zurich
Contact:

Delta Time

Post by beni » Tue Nov 10, 2015 3:03 pm

When you develop on Orxonox you might have noticed that when we move around things in our world, we do so by multiplying with some delta time. Of course when we apply forces from the physics engine it's a bit different, but in the end proper simulation has to be sure how much time has passed between two cycles.. or in this case in between two frames.

That way you can achieve constant speed even with variable frame rate. It doesn't make sense that the player can't move as quickly when there are many enemies around that need to be rendered and that need some AI cycles as well. In fact it's bad design, it affects gameplay and it just makes the game unfair. In the most important (or most beautiful) moments of the game you want the player to be absolutely in control and not slow them down for some silly reasons.

Interestingly Bethesda doesn't care about this issue as the latest video from Fallout4 proves:
https://www.youtube.com/watch?v=r4EHjFkVw-s

You can clearly see that higher framerate = faster movement, faster physics etc. The player is therefore stronger and better when he has a better computer or graphics card or playing on low settings. Interestingly enough double the framerate doens't result in double the speed for motion or physics, so they did something to compensate for it, but they did it wrong.
"I'm Commander Shepard and this is my favorite forum on the internet."

User avatar
x3n
Baron Vladimir Harkonnen
Posts: 810
Joined: Mon Oct 30, 2006 5:40 pm
Contact:

Re: Delta Time

Post by x3n » Tue Nov 10, 2015 8:11 pm

:wallbash:

In some games these effects happen because they use animations with discrete steps. So e.g. the "reload" animation has 10 steps and is supposed to take 1 second. Every step needs at least one frame, so if you have less than 10 frames per second, reloading takes longer than a second. This can be avoided with continuous animations or if you decouple the visuals (i.e. the animation) from the logic (which means that you always reload in 1 second, but the animation may show a small delay or simply stops after 1 second).

But here in this video it seems like the whole physics engine is affected. That's ridiculous.


By the way, as far as I know, in Orxonox the physics engine runs always at 60Hz. This means that if we have more than 60fps, the physics engine won't be updated in some frames. And if we have less than 60fps, the physics engine will sometimes update twice (or more often) per frame.

This ensures that the physics simulation runs at a constant pace. Not only will physical objects move with constant speed (this is already covered by the 'dt' factor), but they also move with equally sized steps (independent of the visual representation). This ensures that physical objects will not accidentally 'tunnel' through walls at low fps.
Fabian 'x3n' Landau, Orxonox developer

User avatar
beni
Baron Vladimir Harkonnen
Posts: 949
Joined: Tue Oct 03, 2006 9:15 am
Location: Zurich
Contact:

Re: Delta Time

Post by beni » Thu Nov 12, 2015 10:31 am

Oh, I didn't know our physics engine is capped :oops: Anyway, as long as it's constant it doesn't matter.

Well, just as a follow up: Fallout4 has sold over 1.2 million times on Steam in the first 24 hours since its release (including pre-orders).

So even though this is a fuck-up, it's not damaging their sales, so they won't fix it any time soon.
"I'm Commander Shepard and this is my favorite forum on the internet."

Post Reply

Who is online

Users browsing this forum: No registered users and 2 guests