camera_2d
2D: the view of a 2D scene, orthographic over X/Y. Smooth and sub-pixel by default (any resolution); pixel_perfect draws at a fixed virtual resolution scaled up by whole numbers. Follows an object with a deadzone and look-ahead, kept inside bounds.
In scene text
camera_2d { view_height 1 follow "…" deadzone (0, 1, 0) }Add it in the Inspector (Add Component), in scene text as above, or ask your AI. Fields you leave out keep their defaults.
Fields 19
| Field | Type | Unit / range | What it does |
|---|---|---|---|
view_height | number | units, 1 … 100000 | World units the screen shows top to bottom (the width follows the window). |
follow | text | — | The object it follows while playing (its name). |
deadzone | (x, y, z) | units | The box around the middle the target moves in before the camera follows (width, height). |
look_ahead | number | units, 0 … 10000 | How far ahead of a moving target it looks. |
smoothing | number | s, 0 … 5 | Seconds to catch up (0 snaps). |
bounds_min | (x, y, z) | units | Lower-left corner the screen stays inside (with bounds_max; both zero: no limit). |
bounds_max | (x, y, z) | units | Upper-right corner the screen stays inside. |
background | colour (r, g, b) | — | The colour behind everything. |
pixel_perfect | true / false | — | Pixel-art mode: draw at virtual_width x virtual_height, scaled up by whole numbers. |
virtual_width | number | px, 16 … 4096 | Pixel-art mode: the virtual screen's width. |
virtual_height | number | px, 16 … 4096 | Pixel-art mode: the virtual screen's height. |
palette | text | — | Retro palette every pixel snaps to: "" none, "pocket" (4 greens), "dusk" (8), "arcade" (16). |
light | (x, y, z) | — | The key light's direction on screen (toward the light; x right, y up): rims, emboss and shading follow it. |
exposure | number | 0 … 8 | Grading: brightness multiplier. |
contrast | number | 0 … 4 | Grading: contrast (1 as is). |
saturation | number | 0 … 4 | Grading: colour strength (1 as is, 0 grey). |
vignette | number | 0 … 1 | Grading: darker corners. |
shadow_tint | colour (r, g, b) | — | Grading: multiplies the dark tones (split toning). |
highlight_tint | colour (r, g, b) | — | Grading: multiplies the bright tones. |
Arcwright Beta 2 (0.4.0) · generated from the engine source (25e375c86)Something wrong or missing? Tell us