GetStorageValue

From Onset Developer Wiki
Revision as of 18:12, 21 January 2021 by BlueMountains (talk | contribs) (Created page with "{{Info|Function|Client|1.4.2}} {{FuncDescription|Can be used to save/read a variable/value on the client. Useful for some settings. Values can be retrieved with GetStorage...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
GetStorageValue

Type: Function
Context: Client
Introduced: v1.4.2

Description

Can be used to save/read a variable/value on the client. Useful for some settings.

Values can be retrieved with GetStorageValue.

Syntax

GetStorageValue(key)

Parameters

  • key
    The name of this value.

Return Value

  • Returns the value that has bee set for this key. If it does not exist "nil" (nothing) will be returned.

Example

print(GetStorageValue("var_str"))
print(GetStorageValue("var_int"))
print(GetStorageValue("var_float"))
print(GetStorageValue("var_bool"))

See also