JSON Reference

One JSON file per motion, named after the motion (S1.json), sitting next to the bundle. Attacks walks through writing one; this page is the full list of what you can put in it.

Add the schema line for autocompletion in VSCode:

"$schema": "https://raw.githubusercontent.com/LEAGUE-OF-NINE/motions/refs/heads/main/schema/schema.json"

Time is a fraction, not seconds

Inside a coin, totalDuration is the only value in seconds. Every other time is a fraction of it, between 0.0 and 1.0: start, end, hitCheckers.time, and the start of zooms, rotates and shakes are all multiplied by totalDuration.

So in a coin with "totalDuration": 2.0, a phase at "start": 0.5 fires one second in. (Zoom, rotate and shake durations are the exception: those are in seconds.)

Top level

{
  "coins": [ { ... }, { ... } ]
}

One object per coin, in order. A coin's object is:

FieldTypeMeaning
totalDurationnumberLength of the coin, in seconds.
phasesarrayMovement and damage. See below.
hitCheckersarrayWhen the coin ends.
zoomsarrayCamera zooms.
rotatesarrayCamera rotations.
shakesarrayCamera shakes.
vfxarray of intReuse the character's original VFX tracks, 1-indexed. See Bundles.

totalDuration decides the coin's length even when the animation is a different length. Set it longer than your bundle timeline or sprite motion and the last frame holds until the coin ends; set it shorter and the animation is cut off there. Omit it (or leave it 0) and the coin takes the animation's own length instead.

phases

{
  "type": "GiveDamage",
  "start": 0.3,
  "end": 0.3,
  "steps": 1
}
FieldTypeMeaning
typestringRelative, ToTargetWide, MoveEnemy or GiveDamage. Anything else is ignored.
start / endfractionWhen the phase runs.
stepsintHow many markers to spread evenly from start to end. 1 = a single marker at start. 0 or less = the phase is skipped.

The remaining fields depend on type.

Relative

Moves the character by an offset from where it stands.

FieldTypeDefault
move{x, y, z}0,0,0
isRefreshDirboolfalse

ToTargetWide

Moves the character to the target, stopping short by move.

FieldTypeDefault
move{x, y, z}0,0,0, arrival offset from the target

MoveEnemy

Moves the target rather than the attacker, by move. Same fields as Relative.

GiveDamage

Applies the visual hit: damage numbers, knockback, hit reaction.

FieldTypeDefaultMeaning
damageRatiofloat1.0Fraction of the coin's damage dealt at this marker. Split it across markers for multi-hit skills (e.g. 0.5 and 0.5). Ignored if 0.
damage.multiHitint1Number of visual hits.
damage.isUpAttackboolfalseLaunches the target upward.
damage.multiHitDurationfloat0Spacing between the visual hits.
sturnobjectsee belowKnockback configuration.

sturn:

FieldTypeDefault
sturnTypestringKNOCKBACK
sturnDirstringDIR_TOTARGET
sturnTimingstringALL
forcePowerfloat5.0
randomPowerfloat5.0
airborneAnglefloat0.0
isRotateTargetboolfalse
targetRotateAnglefloat0.0

hitCheckers

Marks the point at which the coin can hand off to the next one.

"hitCheckers": [{ "time": 1.0, "isNextMotionCoinDelay": 0.0 }]

If you leave hitCheckers out, Motions inserts one at 0.15 of the coin.

zooms

"zooms": [{ "start": 0.2, "duration": 0.5, "size": -2, "easeType": "OutQuad" }]
FieldTypeDefaultMeaning
startfractionnoneWhen the zoom begins.
durationsecondsnoneHow long the zoom clip lasts.
attackerbooltrueInclude the attacker in the framing.
targetsbooltrueInclude the targets in the framing.
betweenfloat0Bias the focus point between attacker and targets.
axisYfloat0Vertical offset of the focus point.
sizefloat-2Zoom amount. Negative zooms in when isRelative.
zoomDurationfloat-1Zoom travel time. -1 = use the clip duration.
isRelativebooltrueTreat size as relative to the current zoom.
focusSpeedfloat0.2How fast the camera chases the focus point.
easeTypestringUnsetAny DOTween ease name, e.g. OutQuad, InOutSine.

rotates

"rotates": [{ "start": 0.0, "duration": 0.4, "targetAngle": { "x": 0, "y": 0, "z": 15 } }]
FieldTypeMeaning
startfractionWhen the rotation begins.
durationsecondsHow long it lasts.
targetAngle{x, y, z}Euler angles to rotate the camera to.
focusRotateSpeedfloatHow fast the camera chases the angle.
easeTypestringDOTween ease name.

shakes

"shakes": [{ "start": 0.3, "duration": 0.2, "strength": 0.25 }]
FieldTypeDefault
startfractionnone
durationsecondsnone
strengthfloat0.25
vibratoint120
randomnessfloat90
fadeOutbooltrue