Agreed! And if you *do* end up having to perform this clamping on dt, because it is larger than 'max_dt', then you could display some feedback to the user, like the 'tortoise' (or was it a snail?) icon on Quake. A flicker of it after fullscreen is no big deal, but if it pops up continuously, then the user at least knows your game isn't running as fast as it should be.
On May 6, 8:48 pm, Bruce Smith <[email protected]> wrote: > FYI, there are quite a few examples of this in pyglet games, including > delta-v, and (shameless plug) my recent Pyweek entry "Outlawn". > > One thing I recently discovered about using dt -- it can be very long in > some cases. For example, it is noticeably longer than usual on the next > update after toggling whether the window is fullscreen, and it is > *extremely* long if you sleep your computer and wake it up later! So to use > it safely, max it out at a "maximum sensible timestep". (Unfortunately I > only noticed this after pyweek was over.) > > On Wed, May 6, 2009 at 11:15 AM, Mike Rooney <[email protected]> wrote: > > > Don't forget to take into account dt when doing your movement as well. > > You probably want to use it is a multiplier on your movement factor so > > it moves the same number of pixels per second regardless of framerate! --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "pyglet-users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/pyglet-users?hl=en -~----------~----~----~----~------~----~------~--~---
