Skip to reading
BASIC Scripting

Find a helper for a common job

Edition 0.86.4.1 HF1

0.86.4.1 Hotfix 1 edition. Earlier lessons and screenshots retain their original version context; revised references and supplements describe the newer behavior.

Download PDFView PDF page

DESK REFERENCE

A helper answers a question or performs a small operation. A gameplay action changes what the game does. You can use both in the same function.

Source table from Find a helper for a common job, page 34
TextLower, Upper and Trim prepare an answer. Replace edits a piece of text. Split and Join move between strings and lists.
Numbers and positionsClamp keeps a value in bounds. RandomInt picks a whole number in an inclusive range. Distance and Vector3 are useful for positions.
GUIGetGUIElementProperty(gui, element, property, fallback) reads one control. SetGUIElementProperty(gui, element, property, value) updates it. SetGUIProperty can change the whole GUI.
Stored game dataReadTextFile and ReadJSONFile accept a fallback. WriteTextFile and WriteJSONFile report whether the write succeeded. FileExists tests a path.
Story progressInventoryCount(item, character) counts a character’s items. HasVisited(room, character) checks room history. The character argument is optional for both.
CommunicateCallScript passes an argument list to a named function. EMIT EVENT sends a dictionary to a listener. RETURN sends one result to the caller.
Page 34 of 86Permalink
Go to page