volcano.c
Volcano.
games/tbs/src/effect/parts/volcano.c on GitHub
Volcano. Part of effect.c, the battle effect object, compiled only through it.
Functions
BattleFx_RunVolcano
void BattleFx_RunVolcano(struct BattleEffectArgument *effect)
One, two or four columns of fire (gVolcano_Counts by effect->variant) rise near the far edge on the targets' side, at the depths of gVolcano_Depths, starting at gVolcano_StartFrames; each erupts with a fountain of 200 sparks and keeps spitting more, and each eruption knocks the targets back.
Abilities: Volcano, Eruption, Pyroclasm, Lava Shower, Molten Bath, Magma Storm (kind 13).
The battle shows the damage on frame 16. Variant 0 is red, 2 orange; variant 2 also swings the camera round over the first 64 frames.
work->particles 0 to 3 are the pillars' feet, battle positions in 16.16. Sets REG_BLDALPHA, loads the red or orange palette into the first 64 background colours (variant 1 keeps the fire pillar sheet's), turns the camera's yaw (variant 2) and sets work->shakeFrames at each eruption.
Used by gBattleFx_EffectHandlers.
Macros, without a comment: VOLCANO_FRAMES, VOLCANO_ERUPTION, VOLCANO_TRICKLE, VOLCANO_SPARK_POOL, VOLCANO_FLAME_IMAGE_ODD, VOLCANO_FLAME_IMAGE_EVEN.