Skip to content

Tutorial Set Piece Battles and Narration

johnjohto edited this page Jul 27, 2026 · 1 revision

Tutorial: Set-Piece Battles and Narration

Four event-grammar tools for authoring story beats — scripted fights with stakes, and atmosphere the player can walk through. All of them came from creators building real games on the toolkit.

A fight you're allowed to lose

wild_battle normally treats a loss like any wild loss: whiteout, warp to a Pokémon Center. For a set-piece that's wrong — the warp fires mid-record and the rest of your scene plays in a Pokémon Center. Add no_blackout:

{"cmd": "wild_battle", "species": "species:mewtwo", "level": 70, "no_blackout": true},
{"cmd": "say", "text": "It lets you rise.\fTry again."}

A lost fight continues the record in place — the "beaten, but not thrown out" beat. (trainer_battle has carried the same option all along.)

A fight only one ball can end

catch_only names the single ball item that may resolve an encounter; every other ball is spent and refused before the capture roll:

{"cmd": "wild_battle", "species": "species:mewtwo", "level": 70,
 "catch_only": "MASTER BALL"}

Narration the player walks through

say and notice stop the player — that's right for dialogue, wrong for atmosphere. narrate puts words on screen and keeps the player moving: a borderless band at the top of the frame, visually nothing like a dialogue box, that fades on its own (no button) and is replaced by the next narrate:

{"cmd": "narrate", "text": "A breeze stirs\nthe tall grass.", "frames": 180}

frames is 1/60ths of a second (default 180 = three seconds). One rule, by design: narration never carries consequences — no gifts, no choices — because the player is allowed to walk away from it.

Asking about typing, not species

In scripts, party_has("species:gastly") answers species. For "is the player carrying a Ghost-type?" use the new predicate — it reads each party member's own typing, so it stays correct even for projects with type-shifted individuals:

return if(party_has_type("type:ghost"), 1, 0)

Clone this wiki locally