Skip to reading
Images, Carousels & Choice Controls

30. A compact reference for scripts

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
Source table from 30. A compact reference for scripts, page 51
What you needRead thisSet or change this
Current Check Box / Radio Button stateGetGUIElementProperty(..., "button_pressed", false)ChangeGUIElementProperty, property "checked", Boolean value.
Current Slider valueGetGUIElementProperty(..., "value", 75.0)ChangeGUIElementProperty, property "value", numeric value.
Carousel current entryRead "entries" and "selected_index"; check bounds.Browse with CarouselPrevious / CarouselNext.
Normal Image foregroundAsset identity belongs to the element.property "assetId", value = image asset ID.
Image backgroundSeparate from the foreground.property "backgroundImageAssetId".
Game variableRuntime.variables.get("id", default)SetVariable with name and value.

The identifiers used in this guide#

Source table from 30. A compact reference for scripts, page 51
GUIImportant element IDs
image_labinspect_image, framed_image, animated_image
gallery_labreference_carousel
inventory_labcarried_carousel
settings_labsubtitles_check, hints_check, opacity_slider, settings_art
settings_lab radio groupsprefs_difficulty; prefs_hint_style

Keep element IDs distinct across these examples. Supply the owning GUI ID as well as the element ID when using GUI actions and property helpers.

Screenshots and runtime checks: PCA 3D Adventure Studio 0.86.3.4. Artwork shown is from existing engine project assets. No practice files are included.

Page 51 of 52Permalink
Go to page