include/battle/battle_effect_state.h
The Lost Age's copy of the battle effect state. More…
#include "field/particle.h"#include "battle/battle_effect_params.h"#include "static_assert.h"#include "system.h"#include "types.h"
Included by battle_internal.h, battle_effect_internal.h, battle_effect_table.c and lucky_wheels.c.
Structures
| Name | Description | |
|---|---|---|
struct | BATTLE_EFFECT_STATE | The running battle effect's state: its canvas image, 64 particles, the display registers it stages and its sprites. |
Macros
| Name | Description | |
|---|---|---|
#define | CANVAS_BYTES (128 * 128) | The battle canvas the effects draw into: 128 by 128 pixels, a byte each. |
#define | CANVAS_FILL_WORD (level) PIXELS_8BPP(level) | A word of four canvas pixels at one level, for filling the canvas. |
Enumerations
| Name | Description | |
|---|---|---|
enum | CANVAS_TRANSFER_MODE { CANVAS_COPY, CANVAS_COPY_AND_CLEAR, CANVAS_COPY_AND_FADE, CA … } | How the canvas transfer treats the canvas after each copy (a battle effect's BATTLE_EFFECT_STATE.transferMode, Lucky Wheels' REEL_EFFECT_STATE's); transferValue is its argument. |
enum | CANVAS_FADE_SHARE { CANVAS_FADE_HALF, CANVAS_FADE_THREE_QUARTERS } | CANVAS_COPY_AND_FADE's transferValue: the percentage of each pixel's level kept for the next tick. |
Description
The Lost Age's copy of the battle effect state. The Broken Seal's block with the 64 particles in front of the sprite sheet, the two affine scales after the BG2 reference point, 64 object slots and one more word before the effect.
Macros in detail
CANVAS_BYTES
#define CANVAS_BYTES (128 * 128)
The battle canvas the effects draw into: 128 by 128 pixels, a byte each.
Referenced by btEffectEndCanvasLayer(), btEffectEndElementStreaks(), btEffectOpenCanvasLayer(), btEffectRunAnnihilation(), btEffectRunAzul(), btEffectRunBackgroundFadeIn(), btEffectRunBolt(), btEffectRunBreaths(), btEffectRunByIdRange(), btEffectRunCanvasBurst(), btEffectRunCards(), btEffectRunCastingImpact(), btEffectRunCatastrophe(), btEffectRunCharon(), btEffectRunCloudSwirl(), btEffectRunCoatlicue(), btEffectRunCondemn(), btEffectRunCrescentSlash(), btEffectRunCriticalHit(), btEffectRunCruelRuin(), btEffectRunCybele(), btEffectRunDaedalus(), btEffectRunDiamondBerg(), btEffectRunDjinniEntrance(), btEffectRunEclipse(), btEffectRunElementBurst(), btEffectRunElementPillar(), btEffectRunFallingSword(), btEffectRunFirePuppet(), btEffectRunFlashingStrike(), btEffectRunFlora(), btEffectRunFlurry(), btEffectRunFormChange(), btEffectRunFromTable(), btEffectRunFume(), btEffectRunGaspFamily(), btEffectRunGeode(), btEffectRunHeartbreak(), btEffectRunImpactBurst(), btEffectRunIris(), btEffectRunJudgment(), btEffectRunLifeShear(), btEffectRunMegaera(), btEffectRunMeteorBlow(), btEffectRunPlasma(), btEffectRunPlumeEdge(), btEffectRunRay(), btEffectRunRisingDragon(), btEffectRunRisingDragonEnemy(), btEffectRunSerac() and 15 more.
Definition at line 155 of file battle_effect_state.h.
CANVAS_FILL_WORD
#define CANVAS_FILL_WORD(level) PIXELS_8BPP(level)
A word of four canvas pixels at one level, for filling the canvas.
Referenced by btEffectRunAnnihilation(), btEffectRunAzul(), btEffectRunBackgroundFadeIn(), btEffectRunBallLightning(), btEffectRunBind(), btEffectRunBolt(), btEffectRunBreaths(), btEffectRunCards(), btEffectRunCastingImpact(), btEffectRunCatastrophe(), btEffectRunCharon(), btEffectRunCoatlicue(), btEffectRunCondemn(), btEffectRunCrescentSlash(), btEffectRunCruelRuin(), btEffectRunDaedalusStrike(), btEffectRunDiamondBerg(), btEffectRunDragonFire(), btEffectRunDrainMotes(), btEffectRunEclipse(), btEffectRunFallingSword(), btEffectRunFirePuppet(), btEffectRunFlashingStrike(), btEffectRunFlora(), btEffectRunFlurry(), btEffectRunFormChange(), btEffectRunFume(), btEffectRunGaspFamily(), btEffectRunGeode(), btEffectRunHaunt(), btEffectRunHaures(), btEffectRunHeartbreak(), btEffectRunIris(), btEffectRunJudgment(), btEffectRunLifeShear(), btEffectRunLiquifier(), btEffectRunMegaera(), btEffectRunMegiddo(), btEffectRunMeteorBlow(), btEffectRunMoloch(), btEffectRunOdyssey(), btEffectRunPlasma(), btEffectRunPlumeEdge(), btEffectRunPrism(), btEffectRunRadiantFire(), btEffectRunRay(), btEffectRunRisingDragon(), btEffectRunRisingDragonEnemy(), btEffectRunSerac(), btEffectRunShatteringOpening() and 9 more.
Definition at line 157 of file battle_effect_state.h.
Enumerations in detail
CANVAS_TRANSFER_MODE
enum CANVAS_TRANSFER_MODE
How the canvas transfer treats the canvas after each copy (a battle effect's
BATTLE_EFFECT_STATE.transferMode, Lucky Wheels' REEL_EFFECT_STATE's);
transferValue is its argument.
| Enumerator | Value | Description |
|---|---|---|
CANVAS_COPY | Copy as drawn. | |
CANVAS_COPY_AND_CLEAR | Copy, then fill the canvas with transferValue (0 clears it). | |
CANVAS_COPY_AND_FADE | Copy, keeping half of each pixel's level for the next tick when transferValue is CANVAS_FADE_HALF, and three quarters for any other value. | |
CANVAS_COPY_AND_DARKEN | Copy, then lower each level by a byte of transferValue, stopping at 0. | |
CANVAS_COPY_AND_BRIGHTEN | Copy, then raise each level by a byte of transferValue. |
Definition at line 17 of file battle_effect_state.h.
CANVAS_FADE_SHARE
enum CANVAS_FADE_SHARE
CANVAS_COPY_AND_FADE's transferValue: the percentage of each pixel's level
kept for the next tick.
| Enumerator | Value | Description |
|---|---|---|
CANVAS_FADE_HALF | 50 | |
CANVAS_FADE_THREE_QUARTERS | 75 |
Definition at line 34 of file battle_effect_state.h.