Achievement - stingray.Achievement namespace reference - Stingray Lua API Reference
The interface for accessing the achievement functionality on Steam.
As the object is a singleton (there is only one Achievement), you do not need to pass any Achievement
object to the functions. All the functions operate on the Achievement singleton.
|
Retrieves information about the current state of the operation identified by the specified token.
|
Parameters token : | integer | The token that provides access to the status of the asynchronous operation. |
Returns table |
A table that indicates whether or not the operation is finished, and any errors encountered.
|
|
Clears all achievements that the player has unlocked.
|
Parameters | This function does not accept any parameters. |
Returns | This function does not return any values. |
This function is available in development builds only.
|
unlock ( achievement ) : integer
Unlocks the specified achievements.
|
Parameters achievement : | string+ | The achievement or achievements to unlock. The + notation indicates that there may be one or more instances of the specified type. |
Returns integer |
Returns a token that you can pass to progress() to track the progress of the operation.
|
For example:
|
Indicates whether or not the achievement is unlocked.
|
Parameters achievement : | string | The achievement you want to test. |
Returns boolean |
Returns true if the achievement is unlocked, or false otherwise.
|
For example: