reskate.progression.getneeds theprogression.readpermission.reskate.settings.game,reskate.settings.namesandreskate.settings.gameplayneed thesettings.readpermission.reskate.settings.setandreskate.settings.hold_gameplayneed thesettings.writepermission.
Progression
reskate.progression.get()
The local player’s progress, as their profile has it.
Needs the
progression.read permission.Settings
The game’s engine settings, by name, as the console shows them.reskate.settings.game(name)
A setting’s value now.
The setting’s name, as
names() lists it. At most 120 characters; longer raises an error.The value as the console shows it, or
nil for a name there is none of, or a value that cannot be read now. Numbers come back as text: use tonumber.Needs the
settings.read permission.reskate.settings.names()
Every setting name known so far: those listed from the engine’s settings this session, and those remembered from earlier ones.
Needs the
settings.read permission.reskate.settings.set(name, value)
Holds a game setting at a value of yours for as long as your plugin keeps it. When you let go, or your plugin stops, the setting goes back to the value it had when you first set it, unless something else has changed it since: then it stays as that left it.
The setting’s name, as
names() lists it. At most 120 characters; longer raises an error.The value, as the console takes it: text of at most 200 characters, a number, or
true and false. nil lets go.When
ok is false:"no game setting is called \"<name>\""."<plugin> holds <name>": another plugin set it first."<name> changes how the game plays, so it cannot be changed during a multiplayer session"."a plugin holds at most 32 settings"."sound settings are the player's: no plugin changes how loud the game is": a setting whose name says volume, audio, sound, mute, loud, speaker, voip, voice, sfx or dynamic range.- The game’s own reason, for a value the setting cannot take.
Needs the
settings.write permission. During a multiplayer session, settings that change how the game plays are refused, as they are from the console: those of the SimulationTime, Physics, PhysicsQuality, FBCorePhysics, DingoGameplay, DingoActivity, DingoThrowdowns, DingoThrowdown, DelMarGame, AutoPlayers and SkaterRecord groups. One your plugin held before the session goes back when it starts. Letting go of a setting you do not hold does nothing.Gameplay options
The player’s on and off gameplay preferences, as the game reads them while you play. A plugin can hold one at a value of its own for a moment, such as a controller layer that needs a preference set one way while its scheme runs. Nothing is saved: the player’s profile, and the game’s own Settings screen, keep the player’s value. An option is known by the name the game reads it by. A name is known only once the game has read that option this session; before that,gameplay returns nil and hold_gameplay refuses it.
reskate.settings.gameplay(name)
The player’s own value of a gameplay option, whatever a plugin holds.
The option’s name, 1 to 120 characters, with no zero byte. Anything else raises an error.
Needs the
settings.read permission.reskate.settings.hold_gameplay(name, value)
Holds a gameplay option at value for the next 300 ms, as the game reads it during play.
When
ok is false:"gameplay input is unavailable": the game window does not have the focus, ReSkate’s menu is open, or the game holds gameplay input."the host has turned boosts off", in a session whose host turned boosts off, or"not while a throwdown runs"(unless the game’s stock physics is on, as a game mode has it)."this boolean gameplay option has not been read by the game yet"."<plugin> holds this gameplay option": another plugin’s hold is live."at most 32 gameplay options per plugin".
Needs the
settings.write permission. A hold lasts 300 ms: call it every tick to keep it. One plugin holds each option at a time, and a plugin holds at most 32 at once. The trainer’s own overrides come first. While the player is changing settings in the game’s menu, the game reads the player’s value. A name that is not 1 to 120 characters, or a value that is not a boolean or nil, raises an error. Letting go always works, and when the plugin stops its holds end.