Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Opened 15 years ago

Closed 15 years ago

#306 closed enhancement (wontfix)

Extend Clock class

Reported by: rgrieder Owned by: nobody
Priority: minor Milestone: Version 0.3 Codename: Castor
Component: misc Version: 0.2.0
Keywords: clock, time Cc:
Referenced By: References:

Description

The Clock? class is used to precisely measure time by means of the operation system internal timer. When GameStates are ticked, they get a reference to a Clock object. But this may not be the only usage. Every Level needs to have a Clock that can be paused and resumed.
That implies some changes in Clock: You have to be able to tick it from outside. I therefore suggest putting the current contents of Clock to a new RealTimeClock (or a suitable name) class and rewriting Clock so that it gets ticked with a RealTimeClock object (which supports getDeltaTime()).
Feel free to examine the Clock class and its usage and then decide what is the best concept for us. The text above is only a suggestion. But clearly, this topic has to be dealt with soon.

Change History (1)

comment:1 Changed 15 years ago by rgrieder

  • Resolution set to wontfix
  • Status changed from new to closed

Revised: Use the Scene class to accumulate time. This would require reorganising it a bit to tick it's content (instead of GSRoot). The clock class should stay.

Since the ticket then seems almost insignificant, I close it.

Note: See TracTickets for help on using tickets.