English
TyranoScript tags
Every [ss_*] tag the TyranoScript plugin adds. Installing the plugin, converting your animation and a first scene are on TyranoScript; TyranoBuilder's components write these same tags.
| Tag | Role | Key attributes |
|---|---|---|
[ss_init] | Sound settings. The runtime is already started by [plugin name="ssplayer"], so this is only for changing audio routing | audio=, sounddir=, soundext=, sevolume= (wasm= is set by the plugin) |
[ss_new] | Create player → load ssab → insert on the layer → play | name=(req) storage=(req) anime= layer= page= x= y= scale= loop= visible= zindex= |
[ss_play] | Play / switch animation, optionally queueing a follow-up | name=(req) anime= transition= loop= start= next= nextloop= atframe= |
[ss_show] | Put a player on screen (reposition / entrance animation / fade) | name=(req) x= y= scale= zindex= anime= transition= loop= next= time= wait= |
[ss_hide] | Take a player off screen, keeping it loaded | name=(req) time= wait= |
[ss_fadein] / [ss_fadeout] | Fade every player at once (scene changes) | time= wait= |
[ss_chara] | Link a player to a speaker: talk animation while they speak | name=(req) jname= talk= idle= transition= |
[ss_track] | Lay an animation on a track above the character's own (track 0) | name=(req) track=(req) anime=(req) alpha= blend= loop= transition= |
[ss_track_fade] | Fade how strongly a track applies | name=(req) track=(req) alpha= time= wait= |
[ss_track_clear] | Empty a track | name=(req) track=(req) |
[ss_stop] / [ss_pause] / [ss_resume] | Per-player stop / pause / resume | name=(req) |
[ss_stop_audio] | Stop the sounds a player started, now | name=(req) |
[ss_speed] | Playback speed (1 = as authored) | name=(req) speed=(req) |
[ss_seek] | Move the playhead to a frame | name=(req) frame=(req) |
[ss_section] | Play only a range of frames (omit both ends to clear) | name=(req) start= end= |
[ss_direction] | Forward / backward, once through / ping-pong | name=(req) direction= style= |
[ss_wait] | Wait until the animation ends (one loop if looping) | name=(req) |
[ss_wait_signal] | Wait until the animation fires a signal (the one command= names, if given) | name=(req) command= var= |
[ss_pos] | Instant move / scale / reorder (anchor-accurate, absolute) | name=(req) x= y= scale= zindex= |
[ss_move] | Tweened move / scale (easeOut, non-blocking by default) | name=(req) x= y= scale= time= wait= |
[ss_part_color] | Tint a part, winning over the animation (Normal parts only) | name=(req) part=(req) color=(req) blend= priority= |
[ss_part_visible] | Force-hide a part (or revert it); cascade= takes its descendants too | name=(req) part=(req) hide= cascade= |
[ss_part_cell] | Make a part draw another cell (Normal / mask parts only) | name=(req) part=(req) cellmap=(req) cell=(req) priority= |
[ss_part_clear] | Clear part overrides (every part when part= is omitted) | name=(req) part= |
[ss_free] | Release one player | name=(req) |
[ss_free_all] | Release every player (scene transition / layer clear) | — |
[ss_pause_all] / [ss_resume_all] | Pause / resume all (e.g. around a menu) | — |
[ss_restore] | Rebuild every player from a save. Not needed — the plugin does this itself on load; use it only to make the load wait for the players, or on an engine with no event system | — |
What the shared attributes take:
x/y: Tyrano's normal top-left pixels (config.scWidth × scHeight, default0,0), the same as any other on-screen element. The animation's anchor lands at that point.loop:true= infinite (default) /false= once / a number = that many loops.layer: the Tyrano layer number (higher = in front; default0).pageisfore(default) /back.scale: a scale factor (default1).anime: an animation name inside the.ssab; empty picks the first animation.[ss_play]'sstart: the frame to start from (default-1= from the beginning of the animation, or of its[ss_section]).visible:falseloads the player without showing it — see Preload, show, hide.zindex: stacking order within one layer. Without it, players on the same layer stack in creation order.time: a duration in ms — a fade, or for[ss_move]the travel time.[ss_show]/[ss_hide]default to0(instant),[ss_fadein]/[ss_fadeout]to1000,[ss_track_fade]and[ss_move]to500.wait:trueholds the scenario until the effect finishes — the default for the fades, not for[ss_move].
The rest are described with their tags below.
A tag that fails never stops the scenario. With the engine's debug switch on (;debugMenu.visible = true in data/system/Config.tjs), the reason appears in the engine's own error dialog with the scenario file and line — for example [ss_play] next="Wiat" is not in others/ssdata/Ringo/Ringo.ssab. Turn the switch off for release; the reason then goes only to the browser console.
Preload, show, hide
[ss_new visible="false"] loads a player without displaying it, so a heavy .ssab can be prepared ahead of the scene that needs it and revealed instantly:
[ss_new name="akane" storage="others/ssdata/Akane/Akane.ssab" visible="false"]
[ss_show name="akane" x="640" y="480" time="800"] ; appears, already loaded
[ss_hide name="akane" time="500"] ; off screen, still loaded[ss_hide] keeps the animation loaded (so [ss_show] is instant) and stops its GPU work while off screen; [ss_free] is what actually releases it. [ss_fadeout] / [ss_fadein] fade every player at once for scene changes, and a fade-in brings back exactly the players that were on screen before the fade-out.
Chaining animations
next= queues a follow-up animation on the player, so "enter, then idle" needs no [ss_wait] and never stops the scenario:
[ss_play name="akane" anime="appear" next="wait"] ; once → idle loop
[ss_play name="akane" anime="attack" next="wait" atframe="20"] ; switch at frame 20next= with no loop= plays the current animation once (an infinite loop would never reach its end). nextloop= sets the follow-up's loop count. An animation that ends before reaching its atframe= switches at its end. The next [ss_play] or [ss_show anime=] cancels a queued follow-up.
Crossfades and tracks
transition= (ms) on [ss_play] / [ss_show] crossfades from what is on screen to the new anime= instead of cutting; 0 or omitted cuts, as before. On [ss_show], time= is still the fade onto the screen. On [ss_chara], transition= crossfades between the talk and idle animations. A next= follow-up still cuts.
[ss_play name="akane" anime="smile" transition="300"] ; blend into smile over 0.3 sA crossfade keeps the part overrides and the tracks. A cut to another animation clears the part overrides that are not permanent, and empties the tracks; cutting to the animation already playing changes nothing.
Tracks lay more animations above the character's own one (track 0, the one [ss_play] sets) — a gesture over a walk, an expression over a pose:
[ss_track name="akane" track="1" anime="wave" blend="add" loop="false"] ; wave over the walk
[ss_track_fade name="akane" track="1" alpha="0" time="500"] ; fade it out
[ss_track_clear name="akane" track="1"] ; then empty the tracktrack=is1or above; track 0 is refused.alpha=is how strongly the track applies (default1).blend=ismix(default — blend toward this animation) oradd(add its offset from the setup pose).loop=works as everywhere else; a finished track holds its last frame until it is faded or cleared.transition=crossfades from what the track was playing.[ss_track_fade]fades toalpha=(default0) overtime=ms (default500,0= at once).wait="true"(the default) holds the scenario until the fade ends, but not on a paused or stopped player. It fails on a track[ss_track]has not laid anything on.[ss_track_clear]empties a track at once; fade it to0first to take it off gradually.- Tracks are saved. A save taken during a
[ss_track_fade]restores the track where the fade ends.
Speed, seeking and sections
[ss_speed name="akane" speed="0.5"] ; half speed
[ss_seek name="akane" frame="12"] ; jump to frame 12
[ss_section name="akane" start="10" end="30"] ; loop frames 10–30 only
[ss_direction name="akane" direction="backward" style="pingpong"]Frame numbers count from 0, as SpriteStudio shows them. [ss_seek] keeps a playing animation playing and a paused one paused. [ss_section] moves the playhead to the start of the section; leave out start= or end= for that edge of the animation, and both to go back to the whole of it. An end= before start= is refused: the section stays as it was, and the browser console says why. direction= is forward or backward, and style= is normal (once through) or pingpong.
Speed and direction stay when the animation changes. A section does not, because a frame number means nothing in another animation: [ss_play anime=] and a next= follow-up both drop it. All three are saved.
Waiting for a signal
A signal is a marker an animator places on a frame in SpriteStudio, with a command ID and optional parameters. [ss_wait_signal] holds the scenario until the animation fires one, so "the moment the attack lands" can be written in the scenario:
[ss_play name="akane" anime="attack" loop="false"]
[ss_wait_signal name="akane" command="hit"] ; hold until the attack lands
[quake count="3" time="300" hmax="20"]command= is the command ID set in SpriteStudio; leave it out to take any signal. var="f.sig" stores the command ID of the signal that ended the wait, so an [if] can branch on which one it was. A queued next= follow-up counts as part of the wait. If the animation finishes, or plays a whole loop, without the signal, the wait ends and the reason is reported like any other tag failure — usually a misspelt command ID. Signal parameters are not passed on.
Speaker-linked talk animations
[ss_chara] plays a talk animation while the bound character's line is being typed out, and returns to idle when it ends — the jname idea of TyranoScript's character plugins, expressed as whole SpriteStudio animations rather than a mouth parameter:
[ss_chara name="akane_ss" jname="あかね" talk="talk" idle="wait"]
#あかね
Nice to meet you.[p]jname= matches the #name in your scenario or the Tyrano chara id; left out, it is the player's own name. An empty idle= returns to whatever [ss_play] last set, so an expression change survives the next line. The talk/idle swap is not saved, so a save taken mid-line restores the character in their normal animation. talk="" unbinds. In skip / [nowait] mode the engine prints the whole line at once, and no talk animation flickers past.
Part overrides
The [ss_part_*] tags replace how one part looks, winning over the animation's keyframes (the SS6 PartsColorChange / CellChangeParts / HideSet equivalents).
[ss_part_color name="chr" part="apple" color="#0033FFBF" blend="mul"]
[ss_part_visible name="chr" part="heta" cascade="true"]
[ss_part_cell name="chr" part="apple" cellmap="Ringo" cell="effect3"]
[ss_part_clear name="chr"]color=is#RRGGBB/#RRGGBBAA(alpha defaults to opaque); the#RGBshorthand works too, and so does TyranoScript's own0xRRGGBB.blend=ismix(default) /mul/add/sub, or the numbers0–3.priority=iskeyframe(yield to the next keyframe) /anime(default — hold until the animation changes) /permanent(survives animation changes), or the numbers0–2.cellmap=carries no.ssceextension.- Changing the animation clears everything but
permanent. The saved copy is pruned at the same time, so nothing the runtime discarded comes back on load. Visibility has no priority mode and is always cleared by an animation change. Atransition=crossfade clears none of them.