burst_scene.c
Gust, Flying Attack and the rush bursts.
games/tbs/src/effect/parts/burst_scene.c on GitHub
Gust, Flying Attack and the rush bursts. Part of effect.c, the battle effect object, compiled only through it.
Functions
BattleFx_RunGust
void BattleFx_RunGust(struct BattleEffectArgument *effect)
Gust: the burst scene in mode 6, 7 or 8 as the variant grows, one to three strikes that each fill the canvas with light.
Abilities: Gust (kind 219); Rapid Smash, Sonic Smash, Slice (kind 310).
Used by gBattleFx_EffectHandlers.
BattleFx_RunBearClaw
void BattleFx_RunBearClaw(struct BattleEffectArgument *effect)
Bear Claw: five strikes, the burst scene in mode 0.
Abilities: Bear Claw (kind 317); Counterstrike (kind 342).
Used by gBattleFx_EffectHandlers.
BattleFx_RunRansack
void BattleFx_RunRansack(struct BattleEffectArgument *effect)
Ransack: the same five strikes as Bear Claw (mode 0).
Abilities: Ransack (kind 321); Mad Dash (kind 343).
Used by gBattleFx_EffectHandlers.
BattleFx_RunBacteriaRush
void BattleFx_RunBacteriaRush(struct BattleEffectArgument *effect)
Bacteria Rush: seven strikes in the lime palette (mode 1).
Abilities: Bacteria Rush (kind 328).
Used by gBattleFx_EffectHandlers.
BattleFx_RunFreebiteRush
void BattleFx_RunFreebiteRush(struct BattleEffectArgument *effect)
Freebite Rush: nine strikes in the blue palette (mode 2).
Abilities: Freebite Rush (kind 334).
Used by gBattleFx_EffectHandlers.
BattleFx_RunFlyingAttack
void BattleFx_RunFlyingAttack(struct BattleEffectArgument *effect)
Flying Attack: the burst scene in mode 3, 4 or 5 as the variant grows, one to three strikes.
Abilities: Flying Attack (kind 319); Swift Strike (kind 329).
Used by gBattleFx_EffectHandlers.
BattleFx_RunBurstScene
void BattleFx_RunBurstScene(struct BattleEffectArgument *effect, s32 mode)
Flurry: the user closes on the first target and strikes it again and again; each strike shows an arc (or, in rows with arc sheet 0, a wave for the third and fourth of every four), flashes and throws motes. A strike lands 2 frames after it starts: an odd one jolts the target, and the last knocks it back, shakes the screen harder and ends the attack. The motes wait above the target until their strike releases them, then bounce off the ground and die out.
Called by the six wrappers above it, with the mode their ability needs. Uses PARTICLES 0 to 767 for the motes, 32 a strike, and both blitter slots, rebuilt twice a frame; loads palette colours 0 to 63 from the row's palette resource.
effect: the user and the targets; prelude 1 brings in a Jupiter Djinni
first.
mode : the row of gBurstScene_Records.Used by BattleFx_RunBacteriaRush, BattleFx_RunBearClaw, BattleFx_RunFlyingAttack, BattleFx_RunFreebiteRush, BattleFx_RunGust, BattleFx_RunRansack.
Enumerations
BurstField
enum BurstField
The bytes of a gBurstScene_Records row, one row a mode.
| Value | = | |
|---|---|---|
BURST_SCENE_ARC_SHEET | 0: blue arc A, else B; 1 also draws every strike as an arc | |
BURST_SCENE_PALETTE | the palette's resource (0 to 3) | |
BURST_SCENE_STRIKES | the strikes | |
BURST_SCENE_MOTES | motes thrown by each strike | |
BURST_SCENE_INTERVAL | frames between strikes | |
BURST_SCENE_FRAMES | frames in the whole effect | |
BURST_SCENE_FLASH | 1 fills the canvas on each hit |
Macros
BURST_SCENE_FLASH_CELLS
#define BURST_SCENE_FLASH_CELLS 0x5100
The flash pictures, packed to half width after the arcs.
Used by BattleFx_RunBurstScene.
BURST_SCENE_WAVE_CELLS
#define BURST_SCENE_WAVE_CELLS (Ram_MapCellBuffer + 0x5e00)
The wave pictures, in the map buffer past the motes.
Used by BattleFx_RunBurstScene.