SFML community forums
Help => System => Topic started by: Rodd on April 29, 2018, 11:57:03 pm
-
Hello,
why the method asMicroseconds() returns Int64 and not UInt64 in Time.hpp ? :)
-
Because sf::Time can represent a negative amount of time.
You can pass negative values to functions that return sf::Time and it has an unary - operator.
It's mentioned in the tutorial too so it's not a mistake or oversight: https://www.sfml-dev.org/tutorials/2.4/system-time.php