Millisecs() ?

BlitzMax Forums/BlitzMax Programming/Millisecs() ?

Sarge(Posted 2005) [#1]
In the blitzmax docs why does it say that Millisecs is the time since the blitzmax window is created, when it really is the time that the system started up.


FlameDuck(Posted 2005) [#2]
In the blitzmax docs why does it say that Millisecs is the time since the blitzmax window is created,
Because that's how it used to be, until some bright spark mentioned that it would screw up SeedRnd Millisecs()

when it really is the time that the system started up.
It isn't. It is effectivly "random". On Linux it's the time since the epoch.


Sarge(Posted 2005) [#3]
It isn't. It is effectivly "random". On Linux it's the time since the epoch.

Millisecs returns timeGetTime,

timeGetTime from msdn:
The timeGetTime function retrieves the system time, in milliseconds. The system time is the time elapsed since Windows was started.


FlameDuck(Posted 2005) [#4]
The timeGetTime function retrieves the system time, in milliseconds. The system time is the time elapsed since Windows was started.
The time since Windows was started, isn't really helpful for Mac and Linux users.


Sarge(Posted 2005) [#5]
Yea, i was just talking about Windows not linux or mac.


Tom Darby(Posted 2005) [#6]
...in any case, best practice is to use MilliSecs() as a delta-timer and not an absolute timer--that is, use MilliSecs() to increment timer variables and refer to those variables for determining how much time has elapsed since any given moment. This way you avoid cross-platform inconsistencies (and integer wrap-around wonkiness) entirely.