src/battle_effect/battle_effect_target_motes.c
The status motes of Taint, Delude, Paralyze, Heartrender, Mystic Flame, Demon Fire and Drown, then Sleep's sheep and Curse's flames. More…
Included by battle_effect.c.
Macros
| Name | Description | |
|---|---|---|
#define | TARGET_MOTES_START_WIDE (mode) | Styles whose motes start in a wide ball, and run on TARGET_MOTES_WIDE_RUN_ON ticks after the last target's motes start. |
#define | TARGET_MOTES_CLOSE_IN (mode) | Styles whose motes close in on the target; the others rise. |
#define | TARGET_MOTES_RIPPLE (mode) | Every style but Taint's smokes and Paralyze ripples the canvas. |
#define | TARGET_MOTES 512 | motes scattered at the start |
#define | TARGET_MOTES_SLOTS 64 | particles reserved for each target |
#define | TARGET_MOTES_CYCLE 24 | ticks of a mote's image cycle |
#define | TARGET_MOTES_PER_TARGET 16 | The motes about each target: TARGET_MOTES_PER_TARGET, or Demon Fire's orbs or Drown's drops. |
#define | DEMON_FIRE_ORBS 24 | |
#define | DROWN_DROPS 32 | |
#define | TARGET_MOTES_STAGGER 8 | The ticks between one target's motes starting and the next's. |
#define | TARGET_MOTES_RUN_ON 32 | The ticks the effect runs on after the last target's motes start. |
#define | TARGET_MOTES_WIDE_RUN_ON 64 | |
#define | TARGET_MOTES_DAMAGE_END_TICKS 32 | The ticks the effect runs on after the damage shows. |
#define | DEMON_FIRE_LEAP_TICKS 14 | |
#define | DEMON_FIRE_APPROACH_TICKS 16 | |
#define | DROWN_DROP_WIDTH 12 | VortexSheet's water drop, after its three 16x64 swirls. |
#define | DROWN_DROP_HEIGHT 24 | |
#define | DROWN_DROP_PICTURE (3 * 16 * 64) | |
#define | SLEEP_TICKS 148 | |
#define | SLEEP_SEEDED 32 | Particles cleared at the start. |
#define | SLEEP_SHEEP 12 | Sheep dropped. |
#define | SLEEP_SHEEP_STAGGER 4 | The sheep drop SLEEP_SHEEP_STAGGER ticks apart; the targets fall asleep SLEEP_TARGET_STAGGER ticks apart from SLEEP_ASLEEP_TICK, and the damage shows at SLEEP_DAMAGE_TICK. |
#define | SLEEP_ASLEEP_TICK 64 | |
#define | SLEEP_TARGET_STAGGER 16 | |
#define | SLEEP_DAMAGE_TICK 80 | |
#define | SLEEP_GROUND_Y toFIXED(92) | The ground the sheep were meant to bounce off. |
#define | SHEEP_WIDTH 32 | SheepSheet: four pictures, then the four drawn flipped. |
#define | SHEEP_HEIGHT 32 | |
#define | SHEEP_PICTURES 4 | |
#define | SHEEP_TUMBLE_STEP 16 | A sheep's variant counts its tumble, z a tick: it turns to its next picture every SHEEP_TUMBLE_STEP. |
#define | CURSE_CANDLE_TICKS 72 | how long each target's candle burns |
#define | CURSE_STAGGER 16 | The ticks between one target's candle and the next's. |
#define | CURSE_FLICKER_TICKS 6 | The flame flickers through its pictures, CURSE_FLICKER_TICKS a picture. |
#define | CURSE_FLAME_WIDTH 16 | FlameColumnSheet: the flame's nine pictures, then the candle. |
#define | CURSE_FLAME_HEIGHT 12 | |
#define | CURSE_FLAME_PICTURES 9 | |
#define | CURSE_CANDLE_WIDTH 16 | |
#define | CURSE_CANDLE_HEIGHT 20 | |
#define | CURSE_CANDLE_PICTURE (CURSE_FLAME_PICTURES * PICTURE_BYTES(CURSE_FLAME)) |
Enumerations
| Name | Description | |
|---|---|---|
enum | TARGET_MOTES_MODE { TARGET_MOTES_TAINT, TARGET_MOTES_PINK_SMOKE, TARGET_MOTES_DE … } | The target motes' styles (btEffectRunTargetMotes), each named for the effect that plays it. |
enum | anonymous enum { TARGET_MOTES_GLINT_PICTURES } | Where Paralyze keeps its glint images in state->sheet. |
Functions
| Name | Description | |
|---|---|---|
void | btEffectRunTaint (BATTLE_EFFECT_PARM *args) | Lime smoke swirls in on each target, or pink smoke for a stronger variant. |
void | btEffectRunUnusedPinkSmoke (BATTLE_EFFECT_PARM *args) | Pink smoke swirls in on each target, as Taint shows it for a stronger variant. |
void | btEffectRunDelude (BATTLE_EFFECT_PARM *args) | Cyan smoke rises around each target. |
void | btEffectRunParalyze (BATTLE_EFFECT_PARM *args) | Smoke rises around each target, and glints sparkle near it. |
void | btEffectRunHeartrender (BATTLE_EFFECT_PARM *args) | Hearts close in on each target, turning as they come. |
void | btEffectRunMysticFlame (BATTLE_EFFECT_PARM *args) | Glowing orbs spiral in on each target. |
void | btEffectRunDemonFire (BATTLE_EFFECT_PARM *args) | Glowing orbs in Mars Djinn colours rise around each target, and then the user steps up to the first target and strikes it. |
void | btEffectRunDrown (BATTLE_EFFECT_PARM *args) | Thirty-two water drops spiral in on each target. |
void | btEffectRunTargetMotes (BATTLE_EFFECT_PARM *args, Uint32 mode) | Around each target in turn, motes (smoke, hearts, orbs) close in on it or rise, and the target flashes. |
void | btEffectRunSleep (BATTLE_EFFECT_PARM *args) | Twelve sheep drop onto the targets' side, tumbling, and each target falls asleep in turn. |
void | btEffectRunCurse (BATTLE_EFFECT_PARM *args) | A candle stands on each target's head in turn, a small flame burning on it. |
Description
The status motes of Taint, Delude, Paralyze, Heartrender, Mystic Flame, Demon
Fire and Drown, then Sleep's sheep and Curse's flames. Part of
battle_effect.c.
Macros in detail
TARGET_MOTES_START_WIDE
#define TARGET_MOTES_START_WIDE(mode)
Styles whose motes start in a wide ball, and run on TARGET_MOTES_WIDE_RUN_ON
ticks after the last target's motes start.
Referenced by btEffectRunTargetMotes().
Definition at line 96 of file battle_effect_target_motes.c.
TARGET_MOTES_CLOSE_IN
#define TARGET_MOTES_CLOSE_IN(mode)
Styles whose motes close in on the target; the others rise.
Referenced by btEffectRunTargetMotes().
Definition at line 101 of file battle_effect_target_motes.c.
TARGET_MOTES_RIPPLE
#define TARGET_MOTES_RIPPLE(mode)
Every style but Taint's smokes and Paralyze ripples the canvas.
Referenced by btEffectRunTargetMotes().
Definition at line 106 of file battle_effect_target_motes.c.
TARGET_MOTES
#define TARGET_MOTES 512
motes scattered at the start
Referenced by btEffectRunTargetMotes().
Definition at line 115 of file battle_effect_target_motes.c.
TARGET_MOTES_SLOTS
#define TARGET_MOTES_SLOTS 64
particles reserved for each target
Referenced by btEffectRunTargetMotes().
Definition at line 116 of file battle_effect_target_motes.c.
TARGET_MOTES_CYCLE
#define TARGET_MOTES_CYCLE 24
ticks of a mote's image cycle
Referenced by btEffectRunTargetMotes().
Definition at line 117 of file battle_effect_target_motes.c.
TARGET_MOTES_PER_TARGET
#define TARGET_MOTES_PER_TARGET 16
The motes about each target: TARGET_MOTES_PER_TARGET, or Demon Fire's orbs or
Drown's drops.
Referenced by btEffectRunTargetMotes().
Definition at line 121 of file battle_effect_target_motes.c.
DEMON_FIRE_ORBS
#define DEMON_FIRE_ORBS 24
Referenced by btEffectRunTargetMotes().
Definition at line 122 of file battle_effect_target_motes.c.
DROWN_DROPS
#define DROWN_DROPS 32
Referenced by btEffectRunTargetMotes().
Definition at line 123 of file battle_effect_target_motes.c.
TARGET_MOTES_STAGGER
#define TARGET_MOTES_STAGGER 8
The ticks between one target's motes starting and the next's.
Referenced by btEffectRunTargetMotes().
Definition at line 125 of file battle_effect_target_motes.c.
TARGET_MOTES_RUN_ON
#define TARGET_MOTES_RUN_ON 32
The ticks the effect runs on after the last target's motes start.
Referenced by btEffectRunTargetMotes().
Definition at line 127 of file battle_effect_target_motes.c.
TARGET_MOTES_WIDE_RUN_ON
#define TARGET_MOTES_WIDE_RUN_ON 64
Referenced by btEffectRunTargetMotes().
Definition at line 128 of file battle_effect_target_motes.c.
TARGET_MOTES_DAMAGE_END_TICKS
#define TARGET_MOTES_DAMAGE_END_TICKS 32
The ticks the effect runs on after the damage shows. Demon Fire's user sets
off DEMON_FIRE_LEAP_TICKS before then and reaches the first target over
DEMON_FIRE_APPROACH_TICKS, striking it as the damage shows.
Referenced by btEffectRunTargetMotes().
Definition at line 132 of file battle_effect_target_motes.c.
DEMON_FIRE_LEAP_TICKS
#define DEMON_FIRE_LEAP_TICKS 14
Referenced by btEffectRunTargetMotes().
Definition at line 133 of file battle_effect_target_motes.c.
DEMON_FIRE_APPROACH_TICKS
#define DEMON_FIRE_APPROACH_TICKS 16
Referenced by btEffectRunTargetMotes().
Definition at line 134 of file battle_effect_target_motes.c.
DROWN_DROP_WIDTH
#define DROWN_DROP_WIDTH 12
VortexSheet's water drop, after its three 16x64 swirls.
Referenced by btEffectRunTargetMotes().
Definition at line 136 of file battle_effect_target_motes.c.
DROWN_DROP_HEIGHT
#define DROWN_DROP_HEIGHT 24
Referenced by btEffectRunTargetMotes().
Definition at line 137 of file battle_effect_target_motes.c.
DROWN_DROP_PICTURE
#define DROWN_DROP_PICTURE (3 * 16 * 64)
Referenced by btEffectRunTargetMotes().
Definition at line 138 of file battle_effect_target_motes.c.
SLEEP_TICKS
#define SLEEP_TICKS 148
Referenced by btEffectRunSleep().
Definition at line 437 of file battle_effect_target_motes.c.
SLEEP_SEEDED
#define SLEEP_SEEDED 32
Particles cleared at the start.
Referenced by btEffectRunSleep().
Definition at line 439 of file battle_effect_target_motes.c.
SLEEP_SHEEP
#define SLEEP_SHEEP 12
Sheep dropped.
Referenced by btEffectRunSleep().
Definition at line 441 of file battle_effect_target_motes.c.
SLEEP_SHEEP_STAGGER
#define SLEEP_SHEEP_STAGGER 4
The sheep drop SLEEP_SHEEP_STAGGER ticks apart; the targets fall asleep
SLEEP_TARGET_STAGGER ticks apart from SLEEP_ASLEEP_TICK, and the damage shows
at SLEEP_DAMAGE_TICK.
Referenced by btEffectRunSleep().
Definition at line 445 of file battle_effect_target_motes.c.
SLEEP_ASLEEP_TICK
#define SLEEP_ASLEEP_TICK 64
Referenced by btEffectRunSleep().
Definition at line 446 of file battle_effect_target_motes.c.
SLEEP_TARGET_STAGGER
#define SLEEP_TARGET_STAGGER 16
Referenced by btEffectRunSleep().
Definition at line 447 of file battle_effect_target_motes.c.
SLEEP_DAMAGE_TICK
#define SLEEP_DAMAGE_TICK 80
Referenced by btEffectRunSleep().
Definition at line 448 of file battle_effect_target_motes.c.
SLEEP_GROUND_Y
#define SLEEP_GROUND_Y toFIXED(92)
The ground the sheep were meant to bounce off.
Referenced by btEffectRunSleep().
Definition at line 450 of file battle_effect_target_motes.c.
SHEEP_WIDTH
#define SHEEP_WIDTH 32
SheepSheet: four pictures, then the four drawn flipped.
Referenced by btEffectRunSleep().
Definition at line 452 of file battle_effect_target_motes.c.
SHEEP_HEIGHT
#define SHEEP_HEIGHT 32
Referenced by btEffectRunSleep().
Definition at line 453 of file battle_effect_target_motes.c.
SHEEP_PICTURES
#define SHEEP_PICTURES 4
Referenced by btEffectRunSleep().
Definition at line 454 of file battle_effect_target_motes.c.
SHEEP_TUMBLE_STEP
#define SHEEP_TUMBLE_STEP 16
A sheep's variant counts its tumble, z a tick: it turns to its next picture
every SHEEP_TUMBLE_STEP.
Referenced by btEffectRunSleep().
Definition at line 457 of file battle_effect_target_motes.c.
CURSE_CANDLE_TICKS
#define CURSE_CANDLE_TICKS 72
how long each target's candle burns
Referenced by btEffectRunCurse().
Definition at line 577 of file battle_effect_target_motes.c.
CURSE_STAGGER
#define CURSE_STAGGER 16
The ticks between one target's candle and the next's.
Referenced by btEffectRunCurse().
Definition at line 579 of file battle_effect_target_motes.c.
CURSE_FLICKER_TICKS
#define CURSE_FLICKER_TICKS 6
The flame flickers through its pictures, CURSE_FLICKER_TICKS a picture.
Referenced by btEffectRunCurse().
Definition at line 581 of file battle_effect_target_motes.c.
CURSE_FLAME_WIDTH
#define CURSE_FLAME_WIDTH 16
FlameColumnSheet: the flame's nine pictures, then the candle.
Referenced by btEffectRunCurse().
Definition at line 584 of file battle_effect_target_motes.c.
CURSE_FLAME_HEIGHT
#define CURSE_FLAME_HEIGHT 12
Referenced by btEffectRunCurse().
Definition at line 585 of file battle_effect_target_motes.c.
CURSE_FLAME_PICTURES
#define CURSE_FLAME_PICTURES 9
Referenced by btEffectRunCurse().
Definition at line 586 of file battle_effect_target_motes.c.
CURSE_CANDLE_WIDTH
#define CURSE_CANDLE_WIDTH 16
Referenced by btEffectRunCurse().
Definition at line 587 of file battle_effect_target_motes.c.
CURSE_CANDLE_HEIGHT
#define CURSE_CANDLE_HEIGHT 20
Referenced by btEffectRunCurse().
Definition at line 588 of file battle_effect_target_motes.c.
CURSE_CANDLE_PICTURE
#define CURSE_CANDLE_PICTURE (CURSE_FLAME_PICTURES * PICTURE_BYTES(CURSE_FLAME))
Referenced by btEffectRunCurse().
Definition at line 589 of file battle_effect_target_motes.c.
Enumerations in detail
TARGET_MOTES_MODE
enum TARGET_MOTES_MODE
The target motes' styles (btEffectRunTargetMotes), each named for the effect
that plays it.
| Enumerator | Value | Description |
|---|---|---|
TARGET_MOTES_TAINT | lime smoke closing in | |
TARGET_MOTES_PINK_SMOKE | pink smoke closing in; Taint's stronger variant | |
TARGET_MOTES_DELUDE | cyan smoke rising | |
TARGET_MOTES_PARALYZE | smoke rising, with glints | |
TARGET_MOTES_HEARTRENDER | hearts closing in | |
TARGET_MOTES_MYSTIC_FLAME | glowing orbs closing in | |
TARGET_MOTES_DROWN | water drops closing in | |
TARGET_MOTES_DEMON_FIRE | orbs in Mars Djinn colours rising, then a strike |
Definition at line 7 of file battle_effect_target_motes.c.
anonymous enum
enum { TARGET_MOTES_GLINT_PICTURES }
Where Paralyze keeps its glint images in state->sheet.
| Enumerator | Value | Description |
|---|---|---|
TARGET_MOTES_GLINT_PICTURES | 9600 |
Definition at line 110 of file battle_effect_target_motes.c.
Functions in detail
btEffectRunTaint
void btEffectRunTaint(BATTLE_EFFECT_PARM *args)
Lime smoke swirls in on each target, or pink smoke for a stronger variant.
Abilities: Taint, Poison.


References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers.
Definition at line 28 of file battle_effect_target_motes.c.
btEffectRunUnusedPinkSmoke
void btEffectRunUnusedPinkSmoke(BATTLE_EFFECT_PARM *args)
Pink smoke swirls in on each target, as Taint shows it for a stronger variant. No effect table entry in The Broken Seal points here.
References btEffectRunTargetMotes().
Definition at line 40 of file battle_effect_target_motes.c.
btEffectRunDelude
void btEffectRunDelude(BATTLE_EFFECT_PARM *args)
Cyan smoke rises around each target.
Abilities: Delude, Confuse, Mist.



References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers.
Definition at line 48 of file battle_effect_target_motes.c.
btEffectRunParalyze
void btEffectRunParalyze(BATTLE_EFFECT_PARM *args)
Smoke rises around each target, and glints sparkle near it.
Abilities: Paralyze.

References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers.
Definition at line 56 of file battle_effect_target_motes.c.
btEffectRunHeartrender
void btEffectRunHeartrender(BATTLE_EFFECT_PARM *args)
Hearts close in on each target, turning as they come.
Abilities: Heartrender.
References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers.
Definition at line 64 of file battle_effect_target_motes.c.
btEffectRunMysticFlame
void btEffectRunMysticFlame(BATTLE_EFFECT_PARM *args)
Glowing orbs spiral in on each target.
Abilities: Mystic Flame.
References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers and btEffectRunCastingImpact().
Definition at line 72 of file battle_effect_target_motes.c.
btEffectRunDemonFire
void btEffectRunDemonFire(BATTLE_EFFECT_PARM *args)
Glowing orbs in Mars Djinn colours rise around each target, and then the user steps up to the first target and strikes it.
Abilities: Demon Fire.
References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers.
Definition at line 81 of file battle_effect_target_motes.c.
btEffectRunDrown
void btEffectRunDrown(BATTLE_EFFECT_PARM *args)
Thirty-two water drops spiral in on each target.
Abilities: Drown.
References btEffectRunTargetMotes().
Referenced by BattleEffectHandlers.
Definition at line 89 of file battle_effect_target_motes.c.
btEffectRunTargetMotes
void btEffectRunTargetMotes(BATTLE_EFFECT_PARM *args, Uint32 mode)
Around each target in turn, motes (smoke, hearts, orbs) close in on it or rise, and the target flashes.
References BattleEffectGlintPictureHeights, BattleEffectGlintPictures, BattleEffectGlintPictureWidths, btCameraShake(), btEffectArmBg2AffineHBlankDMA(), btEffectEndCanvasLayer(), btEffectStartCanvasLayer(), btEffectTintBattler(), btEffectTransferCanvas(), btMotionApplyKnockbackStub(), btMotionApproachTargetStub(), btObjectGetStub(), btProjectionPoint(), btProjectionScaledUnit(), btResourceLoadAndDecompress(), Sint32, state, syCloseEvent(), syCos(), syHeapSlotRelease(), syMatrixTranslateVector(), syRandom(), syResourceGetTableEntry(), syRotX(), syRotY(), sySetEvent(), sySin(), sySoundPlayStub(), sySquartIWRAM(), syWordsCopy() and TargetMotesGlintFlips.
Referenced by btEffectRunDelude(), btEffectRunDemonFire(), btEffectRunDrown(), btEffectRunHeartrender(), btEffectRunMysticFlame(), btEffectRunParalyze(), btEffectRunTaint() and btEffectRunUnusedPinkSmoke().
Definition at line 142 of file battle_effect_target_motes.c.
btEffectRunSleep
void btEffectRunSleep(BATTLE_EFFECT_PARM *args)
Twelve sheep drop onto the targets' side, tumbling, and each target falls asleep in turn.
Abilities: Sleep.

References btEffectTintBattler(), btObjectGetStub(), btResourceLoadAndDecompress(), Sint32, state, syMatrixTranslateVector(), syRandom() and sySoundPlayStub().
Referenced by BattleEffectHandlers.
Definition at line 463 of file battle_effect_target_motes.c.
btEffectRunCurse
void btEffectRunCurse(BATTLE_EFFECT_PARM *args)
A candle stands on each target's head in turn, a small flame burning on it.
Abilities: Curse; Lucid Prophecy.

References btEffectTransferCanvas(), btProjectionScaledUnit(), btResourceLoadAndDecompress(), Sint32, state, syRandom(), sySetEvent() and sySoundPlayStub().
Referenced by BattleEffectHandlers.
Definition at line 594 of file battle_effect_target_motes.c.