Difference between revisions of "Legacy:GetVersionString"
From Spherical
(created from http://web.archive.org/web/20120504060028/http://www.spheredev.org/wiki/GetVersionString) |
(added navbox) |
||
Line 28: | Line 28: | ||
* [[API:GetKey|GetKey]]() | * [[API:GetKey|GetKey]]() | ||
* [[API:GetSystemFont|GetSystemFont]]() | * [[API:GetSystemFont|GetSystemFont]]() | ||
+ | |||
+ | {{API:Engine/navbox}} |
Latest revision as of 22:27, 1 June 2013
This function produces a string that represents the current version of the Sphere engine that the player is using.
Contents
Usage
string GetVersionString();
Examples
// Display "v1.5"
var font = GetSystemFont();
font.drawText(0, 0, "\"" + GetVersionString() + "\"");
FlipScreen();
GetKey();
Notes
This function is more useful for display purposes, rather than checking and comparing versions of the Sphere engine. If you wish to compare the numeric version of Sphere, consider GetVersion().
GetVersionString
() exists because future releases of Sphere may introduce non-numeric characters into the version. Note the addition of the leading 'v' character to the version number above.
See also
- GetVersion()
- FlipScreen()
- Font.drawString()
- GetKey()
- GetSystemFont()