GameStorage | CraytaKit
Skip to main content

GameStorage

Class Functions

Class Function NameReturn TypeDescriptionTags
GameStorage.GetCounter(string counterName, function callback)NoneGet the value of a global counter for this game. Global counters are shared between all servers running the game and saved between sessions. The value is returned by calling the callback function with the value as an argument. Global counters are always whole (integer) numbersServer Only
GameStorage.UpdateCounter(string counterName, number increment, function callback)NoneUpdate the value of a global counter for this game by adding increment to the existing value. Global counters are shared between all servers running the game and saved between sessions. The new incremented value is returned by calling the callback function with the value as an argument. Global counters are always whole (integer) numbersServer Only
GameStorage.UpdateCounter(string counterName, number increment)NoneUpdate the value of a global counter for this game by adding increment to the existing value. Global counters are shared between all servers running the game and saved between sessions. Global counters are always whole (integer) numbersServer Only

Examples

© 2024 CraytaKit