EGGOXdevelopers

Saved progress and leaderboards

Call Purpose --- --- save(player, key, value) / load(player, key) Personal progress in this game save(key, value) / load(key) Shared values for this game save(

CallPurpose
save(player, key, value) / load(player, key)Personal progress in this game
save(key, value) / load(key)Shared values for this game
save(player, key, nil) / save(key, nil)Forget a value
score(board, player, value)Keep the player's best numeric score
top(board[, n])Best rows as {{name, value}, ...}, up to 50

Keys are 1 to 32 bytes. Values are JSON-compatible numbers, strings, booleans, arrays or string-keyed tables, up to 2048 encoded bytes. Maximum 64 keys per player and 256 global keys. Tables must be shallow, not cyclic. A missing key returns nil. A save is immediately readable in the same handler. The server can refuse oversized or excessive saves; the playtest log reports that refusal. Leaderboards share the global save budget and retain up to 100 scores within the same value-size limit. Do not use keys beginning _board_ for other data.

This page as markdown: /api/saved-progress-and-leaderboards.md