Skip to Content
The Alchemy Project

src/battle_effect/battle_effect_fume.c

Fume. More…

Included by battle_effect.c.

Structures

NameDescription
structCORNEROne corner of the plume: signed x, y and depth.

Macros

NameDescription
#defineFUME_TICKS 50
#defineFUME_HIT_TICK 22The tick the plume's head reaches the target and the target is hit.
#defineFUME_SEGMENTS 33The plume is FUME_SEGMENTS pairs of corners, laid in the map cell buffer: the corners, those btRenderTransformVertices makes of them at FUME_STRIP_VERTICES, and the plume's mesh at FUME_STRIP_MESH, whose quads each take 4 texels of SmokeBandSheet's flames across and its 32 down.
#defineFUME_CORNERS (FUME_SEGMENTS * 2)
#defineFUME_QUADS (FUME_SEGMENTS - 1)
#defineFUME_STRIP_VERTICES (RamMapMetatileBuffer + 4096)
#defineFUME_STRIP_MESH (RamMapMetatileBuffer + 8192)
#defineFUME_ARC_GROWTH 44The plume arcs from the caster over to the target.
#defineFUME_ARC_SPAN 988
#defineFUME_THICKNESS 24The plume thickens 4 pixels a segment from its tail up to FUME_THICKNESS, times the level's width.
#defineFUME_SWAY 4The plume sways up to FUME_SWAY pixels at its head, less towards its tail, a wave that runs along it a segment a tick.
#defineFUME_DIM_TICK 34From this tick the plume dims, 8 shades a tick.
#defineFUME_HEAD_SCALE (width) ((width) * 28 / 32)The head's scale, seven eighths of the plume's width.
#defineFUME_BURSTS_MAX 32The fireballs that burst from the target: FUME_BURSTS_MAX are set out at the hit, four more showing each tick, and a level draws FumeLevels' FUME_SPARKS of them.
#defineFUME_BURST_PICTURE_TICKS 4
#defineFUME_BURST_TICKS 24
#defineFUME_FLASH_BURST_PICTURES 2048Where FlashBurstSheet is decoded in the effect's pictures.
#defineFUME_DRAGON_HEAD_PICTURES 16384Where ClawSlashSheet, a dragon's head of flame, is decoded in the effect's pictures.

Functions

NameDescription
voidbtEffectRunFume (BATTLE_EFFECT_PARM *args)A plume of flames rises from the caster and arcs over onto the target, a dragon's head of fire at its front.

Description

Fume. Part of battle_effect.c.

Macros in detail

FUME_TICKS

#define FUME_TICKS 50

Referenced by btEffectRunFume().

Definition at line 11 of file battle_effect_fume.c.

FUME_HIT_TICK

#define FUME_HIT_TICK 22

The tick the plume's head reaches the target and the target is hit.

Referenced by btEffectRunFume().

Definition at line 13 of file battle_effect_fume.c.

FUME_SEGMENTS

#define FUME_SEGMENTS 33

The plume is FUME_SEGMENTS pairs of corners, laid in the map cell buffer: the corners, those btRenderTransformVertices makes of them at FUME_STRIP_VERTICES, and the plume's mesh at FUME_STRIP_MESH, whose quads each take 4 texels of SmokeBandSheet's flames across and its 32 down.

Referenced by btEffectRunFume().

Definition at line 18 of file battle_effect_fume.c.

FUME_CORNERS

#define FUME_CORNERS (FUME_SEGMENTS * 2)

Referenced by btEffectRunFume().

Definition at line 19 of file battle_effect_fume.c.

FUME_QUADS

#define FUME_QUADS (FUME_SEGMENTS - 1)

Referenced by btEffectRunFume().

Definition at line 20 of file battle_effect_fume.c.

FUME_STRIP_VERTICES

#define FUME_STRIP_VERTICES (RamMapMetatileBuffer + 4096)

Referenced by btEffectRunFume().

Definition at line 21 of file battle_effect_fume.c.

FUME_STRIP_MESH

#define FUME_STRIP_MESH (RamMapMetatileBuffer + 8192)

Referenced by btEffectRunFume().

Definition at line 22 of file battle_effect_fume.c.

FUME_ARC_GROWTH

#define FUME_ARC_GROWTH 44

The plume arcs from the caster over to the target. Its head goes FUME_ARC_GROWTH further each tick, and from the level's FUME_TAIL_START its tail follows, each up to FUME_ARC_SPAN; a point's angle on the arc is FUME_SEGMENTS times its place.

Referenced by btEffectRunFume().

Definition at line 27 of file battle_effect_fume.c.

FUME_ARC_SPAN

#define FUME_ARC_SPAN 988

Referenced by btEffectRunFume().

Definition at line 28 of file battle_effect_fume.c.

FUME_THICKNESS

#define FUME_THICKNESS 24

The plume thickens 4 pixels a segment from its tail up to FUME_THICKNESS, times the level's width.

Referenced by btEffectRunFume().

Definition at line 31 of file battle_effect_fume.c.

FUME_SWAY

#define FUME_SWAY 4

The plume sways up to FUME_SWAY pixels at its head, less towards its tail, a wave that runs along it a segment a tick.

Referenced by btEffectRunFume().

Definition at line 34 of file battle_effect_fume.c.

FUME_DIM_TICK

#define FUME_DIM_TICK 34

From this tick the plume dims, 8 shades a tick.

Referenced by btEffectRunFume().

Definition at line 36 of file battle_effect_fume.c.

FUME_HEAD_SCALE

#define FUME_HEAD_SCALE(width) ((width) * 28 / 32)

The head's scale, seven eighths of the plume's width.

Referenced by btEffectRunFume().

Definition at line 38 of file battle_effect_fume.c.

FUME_BURSTS_MAX

#define FUME_BURSTS_MAX 32

The fireballs that burst from the target: FUME_BURSTS_MAX are set out at the hit, four more showing each tick, and a level draws FumeLevels' FUME_SPARKS of them. Each shows FlashBurstSheet's six pictures in turn, FUME_BURST_PICTURE_TICKS apiece, for FUME_BURST_TICKS.

Referenced by btEffectRunFume().

Definition at line 44 of file battle_effect_fume.c.

FUME_BURST_PICTURE_TICKS

#define FUME_BURST_PICTURE_TICKS 4

Referenced by btEffectRunFume().

Definition at line 45 of file battle_effect_fume.c.

FUME_BURST_TICKS

#define FUME_BURST_TICKS 24

Referenced by btEffectRunFume().

Definition at line 46 of file battle_effect_fume.c.

FUME_FLASH_BURST_PICTURES

#define FUME_FLASH_BURST_PICTURES 2048

Where FlashBurstSheet is decoded in the effect's pictures.

Referenced by btEffectRunFume().

Definition at line 49 of file battle_effect_fume.c.

FUME_DRAGON_HEAD_PICTURES

#define FUME_DRAGON_HEAD_PICTURES 16384

Where ClawSlashSheet, a dragon's head of flame, is decoded in the effect's pictures.

Referenced by btEffectRunFume().

Definition at line 52 of file battle_effect_fume.c.

Functions in detail

btEffectRunFume

void btEffectRunFume(BATTLE_EFFECT_PARM *args)

A plume of flames rises from the caster and arcs over onto the target, a dragon's head of fire at its front. As the head strikes, the screen flashes white, the target is thrown back and fireballs burst from it; the plume follows its head down and fades. The stronger the level, the thicker the plume, the more fireballs and the harder the shake.

Abilities: Fume, Serpent Fume, Dragon Fume.

References BattleEffectSquareCorners, BattleEffectSquareMesh, btCameraShake(), btEffectCountDownBattlerTints(), btEffectEndCanvasLayer(), btEffectPosProjectBattler(), btEffectStartActorMotion(), btEffectStartCanvasLayer(), btEffectTintBattler(), btEffectTransferCanvas(), btParticleAdvanceWithGravity2D(), btRenderAllocateModelList(), btRenderBuildQuadStrip(), btRenderDrawModelList(), btRenderTransformVertices(), btResourceLoadAndDecompress(), FumeLevels, MapGridMetatileBuffer, Sint32, syCloseEvent(), syCos(), syHeapRelease(), syHeapSlotRelease(), syInitMatrix(), syMatrixScaleUniform(), syRandom(), syRotY(), syRotZ(), syScale(), sySin() and syTranslate().

Referenced by BattleEffectHandlers.

Definition at line 61 of file battle_effect_fume.c.