studio

FolioTier 2

@headshake

Sway a sprite's head side to side - a gesture of disagreement or disbelief.

Use @headshake to sway a shown sprite from side to side for a refusal, skepticism, or disbelief. The gesture returns the sprite to its starting position without changing its frame. Pair it with a line of dialogue or let it carry a silent response.

intensity controls the distance of the sway, and duration controls how long it lasts. Start with the defaults, then lower intensity for hesitation or raise it for a firmer response.

The story waits for the gesture to finish by default. Set wait=false to let the next event run while the sprite moves. target names the sprite to animate; use @shake for an impact tremble instead of a deliberate head gesture.

Parameters

ParameterKindRequiredDefaultNotes
targetstringyes""Sprite tag to target.
intensitynumberno0.70-1 × multiplier. Default 0.7.
durationnumberno0.450.2-1.5 seconds. Default 0.45.
waitbooleannotrueBlock for the effect's duration when true; false fires and continues so effects can overlap.

Canonical example

sprite show ada
say "Ada": "No way."
@headshake(target=ada)

@headshake sways the sprite that target matches from side to side, then settles back to rest. It reads as disagreement or disbelief - the "no" to @nod's "yes" - without swapping the sprite's state image.

intensity scales how far the sway travels (0.7 is the everyday default); duration is how long it runs. Keep both modest so the gesture reads as body language, not a glitch.

Notes

@headshake is a gesture effect - a one-shot reaction that returns the sprite exactly where it started. Distinct from @shake, which is a decaying jitter (impact tremble) rather than a deliberate head movement. It runs on the Pixi stage.

See also

  • @nod - the "yes" counterpart
  • @shake - impact jitter, not a head gesture
  • sprite - mounts the sprite that target matches