Part of the
scene-scripting skill. The skill links here when your agent needs the detail.ctx object that summer_run_script hands to func run(ctx):. The core tier (creation helpers, find, save_scene, summary) is in the scene-scripting skill. Call results from ctx are untyped: write var wall = ctx.add_mesh(...), never var wall := ... (GDScript cannot infer a type from an untyped call and refuses to compile).
The geometry & authoring stdlib (geometry tier)
Newer engines extend ctx with a second tier: real geometry (booleans, lathe, sweep, terrain), mesh post-processing (smooth, decimate, UVs, mirror, collision), keyframe animation, and text shaders. Frozen signatures:report entry plus a null/false return, never a crash; every baked mesh carries generated normals (and tangents where UVs exist). On an older engine these helpers are missing — the CSG-node fallback recipe in recipes-3d.md (next to this file) still works everywhere.
The animation stdlib (animation tier)
Character-animation USAGE on top ofanimate() — state machines, method tracks, bone poses, head tracking. Same conventions. Frozen signatures:
animate() with property "blend_shapes/<name>" (value tracks) — no separate helper. The end-to-end recipe (inspect an imported rig’s real clips/bones, locomotion wiring, footstep method tracks, root motion, the raw-GDScript fallback for engines without these helpers) lives in character-animation-wiring — one hop, not duplicated here.
The game-completeness stdlib (game-completeness tier: 2D, UI, gameplay code)
Everything a script needs to produce a GAME, not just a 3D scene: 2D levels, Control trees, persisted signal connections, attached scripts, prefabs, project settings. Same conventions (owner-by-default, return the node,prop_warnings, structured report entries on failure — never silent). 2D helpers work in any edited scene (root may be Node2D or Node); Control helpers parent under the edited root unless a parent is given. Frozen signatures:
summer_run_script itself (which returns engine_lacks_op on engines without RunSceneScript). On an engine that has RunSceneScript but predates this tier, a missing helper is a plain GDScript error (Invalid call to method 'add_ui'…) and, under the default undo: "action", the whole run rolls back. Fall back to what works everywhere:
Undo posture. File-writing helpers (
attach_script, make_prefab) and project-settings helpers (add_autoload, add_input_action, set_main_scene) are covered by the pre-run checkpoint, NOT by the packed-scene undo action — a rolled_back: true result has reverted the scene but not those files or settings. The result’s undo_action note says so whenever any of them ran (files_written: [paths], project_settings_changed: [keys]): read it, and surface no_rewind_point: true to the user before more work of this kind.
Pitfalls
Source:
library/skills/scene-scripting/references/ctx-api.md, rendered from summer-engine@4.3.0 on npm.
