Scroll
A viewport onto something larger than itself — an inventory, a quest log, a tall settings page — clipped to its own box. Its content size is measured from what is laid out inside it, or typed. Follow End keeps a log on its newest line.
On this page
Add it
+ Add node → Scroll View creates a node with it already on. Already have a node for it? Add component → ScrollComponent.
From a script
A script on the same node writes these fields by name. ScrollComponent is the name to pass.
rgs
set_point("ScrollComponent", "content", vec2(0.0, 0.0));
set_number("ScrollComponent", "wheel", 48.0);
set_flag("ScrollComponent", "drag", true);
set_flag("ScrollComponent", "follow_end", false); Fields
| Field | Script name | Kind | Default | What it does |
|---|---|---|---|---|
| Content | content | two numbers (x, y) | (0, 0) | How big the thing being looked at is, in UI units — or zero on an axis to measure it instead. |
| Wheel | wheel | number, at least 1 | 48 | How far one wheel notch scrolls. |
| Drag | drag | checkbox | on | Whether dragging the viewport itself pans it. |
| Follow End | follow_end | checkbox | off | While the view is scrolled to its end, new content keeps it there, until the player scrolls back. |