Enfusion Script API
|
Type storing timestamps of the world. More...
Public Member Functions | |
proto external WorldTimestamp | PlusSeconds (float seconds) |
proto external WorldTimestamp | PlusMilliseconds (float milliseconds) |
proto external float | DiffMilliseconds (WorldTimestamp other) |
proto external int | Compare (WorldTimestamp other) |
proto external bool | Equals (WorldTimestamp other) |
proto external bool | Greater (WorldTimestamp other) |
proto external bool | GreaterEqual (WorldTimestamp other) |
proto external bool | Less (WorldTimestamp other) |
proto external bool | LessEqual (WorldTimestamp other) |
Public Member Functions inherited from pointer | |
proto string | ToString () |
Type storing timestamps of the world.
When a world is created, its timestamp starts at 0. Internal timestamp format is opaque and units used are not specified. However, timestamps guarantee enough precision to provide results in milliseconds, and overflow effects will take at least 100,000 (hundred thousand) years to become observable.
Note that timestamp precision is much higher than what can be represented accurately by float
before rounding occurs. For example, when storing duration in milliseconds in a float
, the highest value that can be stored before rounding occurs is 16,777,216 ms (approximately 4.5 hours).
proto external int WorldTimestamp.Compare | ( | WorldTimestamp | other | ) |
proto external float WorldTimestamp.DiffMilliseconds | ( | WorldTimestamp | other | ) |
proto external bool WorldTimestamp.Equals | ( | WorldTimestamp | other | ) |
proto external bool WorldTimestamp.Greater | ( | WorldTimestamp | other | ) |
proto external bool WorldTimestamp.GreaterEqual | ( | WorldTimestamp | other | ) |
proto external bool WorldTimestamp.Less | ( | WorldTimestamp | other | ) |
proto external bool WorldTimestamp.LessEqual | ( | WorldTimestamp | other | ) |
proto external WorldTimestamp WorldTimestamp.PlusMilliseconds | ( | float | milliseconds | ) |
proto external WorldTimestamp WorldTimestamp.PlusSeconds | ( | float | seconds | ) |