Skip to content

Search

Documentation

settings

Every setting the engine, its plugins and the game declare, by path: physics/solver_iterations is [physics] solver_iterations in project.toml. define…

On this page

Every setting the engine, its plugins and the game declare, by path: physics/solver_iterations is [physics] solver_iterations in project.toml. define adds your own; [override.<platform>] tables answer per platform.

10 functions, 0 constants. Scripts reach it as settings::.

Functions

Argument kinds are the script values a call passes: node is a node handle, any a table or value of any kind, fn a callback.

function acts on what it does
all() -> [settings::Setting] — Every defined setting as { path, scope, spec }, in definition order.
base(string) -> any — What the file says, ignoring every override: what a settings screen edits.
clear(string) — Forget one value, so the next write drops the key: how an override is removed.
define(string, any) — Declare a setting of your own: type, default, and optionally min, max, options, help, order and applies. A path starting editor/ is kept on this machine; anything else ships with the game.
get(string) -> any — One setting's value here: the narrowest [override.<tag>] this platform answers to, else what was set, else what its definition defaults to, else nil.
known_tags() -> [str] — Every tag a project may write an override for: the engine's, then the project's own from [export] tags.
merge_toml(string) — Read values out of a TOML text, folding them onto what is already loaded.
overrides(string) -> [str] — The tags this project holds an override for at path, in tag order.
set(string, any) — Change one setting, in memory. Whether it takes effect now or on the next run is the setting's own business; all reports it as applies.
to_toml(string, string) -> string — The text one scope would write, starting from existing so anything no setting describes survives. Scope is "project" or "editor".

Are you sure?