settings.get

Returns the value of a setting. If the setting doesn't exists, the second argument will be returned.

ExampleGet the value of a setting
Get the value of the setting "shell.autocomplete" and print it.
Code
<nowiki>print(settings.get("shell.autocomplete"))</nowiki>
Output
true

settings.get
Function
Syntax
settings.get(
  • name : string
  • default : any
)

Returns any value
API settings
Source CC:Tweaked (source)

,

This article is issued from Computercraft. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.