Show raw api
{
"functions": [
{
"name": "new",
"desc": "Constructs a new SettingProperty.",
"params": [
{
"name": "serviceBag",
"desc": "",
"lua_type": "ServiceBag"
},
{
"name": "player",
"desc": "",
"lua_type": "Player"
},
{
"name": "definition",
"desc": "",
"lua_type": "SettingDefinition"
}
],
"returns": [
{
"desc": "",
"lua_type": "SettingProperty<T>"
}
],
"function_type": "static",
"source": {
"line": 23,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
},
{
"name": "Observe",
"desc": "Observes the value of the setting property",
"params": [],
"returns": [
{
"desc": "",
"lua_type": "Observable<T>"
}
],
"function_type": "method",
"source": {
"line": 43,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
},
{
"name": "SetValue",
"desc": "Sets the value of the setting property. Will warn if it cannot do so.\n\n:::tip\nUse [PromiseSetValue] to ensure value is set.\n:::",
"params": [
{
"name": "value",
"desc": "",
"lua_type": "T"
}
],
"returns": [],
"function_type": "method",
"source": {
"line": 106,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
},
{
"name": "PromiseValue",
"desc": "Promises the value of the setting once it's loaded.",
"params": [],
"returns": [
{
"desc": "",
"lua_type": "Promise<T>"
}
],
"function_type": "method",
"source": {
"line": 120,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
},
{
"name": "PromiseSetValue",
"desc": "Promises to set the value",
"params": [
{
"name": "value",
"desc": "",
"lua_type": "T"
}
],
"returns": [
{
"desc": "",
"lua_type": "Promise"
}
],
"function_type": "method",
"source": {
"line": 133,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
},
{
"name": "RestoreDefault",
"desc": "Restores the setting to the default value",
"params": [],
"returns": [],
"function_type": "method",
"source": {
"line": 143,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
},
{
"name": "PromiseRestoreDefault",
"desc": "Restores the setting to the default value. This is different than setting to the default value\nbecause it means there is no \"user-set\" value which could lead to values changing if\ndefaults change.",
"params": [],
"returns": [
{
"desc": "",
"lua_type": "Promise"
}
],
"function_type": "method",
"source": {
"line": 159,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
}
],
"properties": [],
"types": [],
"name": "SettingProperty",
"desc": "",
"source": {
"line": 4,
"path": "src/settings/src/Shared/Setting/SettingProperty.lua"
}
}