Stun
A stun: no casting, a running windup stopped, no walking
blocks Activate by holderMoveSpeed x 0stack refreshA stun, lifted from the ARPG slice's content\arena.ledger (Stunned) and the caster's hex that lays it from content\enemies.ledger (Hex). A stunned actor casts nothing, a windup it has running stops Blocked, and it walks nowhere: the game reads MoveSpeed each frame, so the stun reaches the feet through the stat. A stun more starts its second again.
1
# A stun, lifted from the ARPG slice's content\arena.ledger (Stunned) and the caster's hex that lays it from2
# content\enemies.ledger (Hex). A stunned actor casts nothing, a windup it has running stops Blocked, and it walks3
# nowhere: the game reads MoveSpeed each frame, so the stun reaches the feet through the stat. A stun more starts its4
# second again.6
rate 607
stat MaxHealth8
stat MoveSpeed9
pool Health max MaxHealth10
damage Health11
link team12
allegiance team13
tags Unit Spell Stun15
effect Stunned16
tags Stun17
stack refresh18
lasts 1s19
blocks Activate by holder20
MoveSpeed x 022
ability Hex23
tags Spell24
target one enemy having Unit within 1125
cooldown 4s26
windup 1.5s27
broken by Damage of holder when event.landed >= 2028
deal 15 to target29
apply Stunned to target31
archetype Side33
archetype Caster34
tags Unit35
base MaxHealth 3536
base MoveSpeed 337
full Health38
grants Hex1
catalog stun.ledger3
# The stun's numbers, from Stunned and Hex: a 1.5 s windup, 15 and a 1 s stun. Two casters of sides r and b stand4
# 5 apart.6
play "hexed: at 1.5 s, 15 and a stun; stunned, it can't walk or cast, and a second later it can"7
make r Side8
make b Side9
make a Caster with team = r at 0 010
make t Caster with team = b at 5 011
act a Hex at t12
expect done13
advance 1.5s14
expect t.Health = 20 from content: the Caster's 35 less Hex's 1515
expect t has Stunned16
expect t.MoveSpeed = 0 from content: Stunned's MoveSpeed x 017
act t Hex at a18
expect refused Blocked19
save20
advance 1s21
expect t lacks Stunned22
expect t.MoveSpeed = 3 from content: the Caster's base 3, the stun gone23
act t Hex at a24
expect done26
play "a stun mid-windup stops it Blocked, and nothing lands"27
make r Side28
make b Side29
make a Caster with team = r at 0 030
make t Caster with team = b at 5 031
act a Hex at t32
expect done33
advance 0.5s34
apply Stunned to a35
expect a stopped Hex Blocked36
advance 1.5s37
expect t.Health = 35 from content: the Caster's 35, nothing landedRun it yourself
ledger check content/cookbook/mechanics/stun.ledger content/cookbook/mechanics/stun.play
ledger play content/cookbook/mechanics/stun.play