Changes between Version 3 and Version 4 of code/doc/Clock
- Timestamp:
- Apr 12, 2017, 10:38:48 PM (8 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
code/doc/Clock
v3 v4 1 1 = Clock = 2 [[TracNav(TracNav/TOC_Development)]]3 2 4 3 The clock class serves as an object that distributes time. It is created in RootGameState at the very beginning of start() which denotes the start of the game. [[br]] … … 6 5 In Order to get the current time, call getMicroseconds() and you will get the time stored by capture(). If you want to receive the current real time, call getRealMicroseconds(). This doesn't store the time however.[[br]] 7 6 [[br]] 8 The idea is that the Clock object is handed over to every GameStatevia constant reference in the tick() method.[br]7 The idea is that the Clock object is handed over to every [wiki:GameStates GameState] via constant reference in the tick() method.[br] 9 8 You should not attempt to use the Clock for the game level time. There is another class for that, which gets ticked too. [[br]] 10 9 [[br]]