Alchemy
Loading...
Searching...
No Matches

BattleFxScene Struct Reference

The work of a Psynergy effect scene: its caster and target, where it takes place, the map state it restores and its 24 effect slots. More...

#include <battle/fx_scene.h>

Data Fields

s32 angle
 1/65536 turns
s32 x
 16.16 fixed-point pixels
s32 y
 16.16 fixed-point pixels
s32 z
 16.16 fixed-point pixels
void * mainObject
 the caster's object
void * child
 the target's object, or NULL
s16 firstObjectId
 the caster's object id
s16 secondObjectId
 the target's object id, -1 for none
u16 action
 the ability id
s16 fieldKind
 the ability's field kind (FIELD_KIND_)
s8 enabled
 Set at the start: Force then aims in front of the caster; cleared once the target has been dispatched.
u8 mode
 where the effect runs; MODE_WORLD_MAP on the world map
s8 visible
 set at the start: the caster flashes with a sound
s8 active
 set at the start: the ability's name is announced
void(*) finishCallback (void)
 run, when set, as Ply's effect ends
u8 unk28 [0x0c]
 not named by TBS code
s8 childOption
 Set by some scenes before an effect; Carry, Frost, Force and Reveal treat the target differently with it.
s8 childMode
 set by some scenes: Frost and Force leave the target be
u8 unk36 [2]
 not named by TBS code
u8 unk40 [4]
 not named by TBS code
u8 savedPalette
 the target's first sprite's param, saved likewise
u8 lit
 set in two Mercury Lighthouse maps; not read by name
u16 tileSlot
 resource entry holding the spark tiles
u16 unk48
 not named by TBS code
u16 freeBlocks
 512 less the free resource blocks at the start
struct EffectSlot slots [24]
u8 unk718 [2]
 not named by TBS code
s16 arcTileSlot
 resource entry of Avoid's and Retreat's arcs
s8 messageMode
 the announcement's box mode: 1, a scene adds 8
u8 unk71d [3]
 not named by TBS code
void(*) savedCallback (union FieldObject *object)
 The target's update hook and script, saved at the start and restored when Move or Carry lets it go.
const s32 * savedScript
s32 savedShakeX
 The map's shake and its decay, restored when the effect ends.
s32 savedShakeY
s32 savedShakeDecay

Detailed Description

The work of a Psynergy effect scene: its caster and target, where it takes place, the map state it restores and its 24 effect slots.

Definition at line 31 of file fx_scene.h.

Field Documentation

◆ angle

◆ x

◆ y

◆ z

◆ mainObject

◆ child

◆ firstObjectId

s16 BattleFxScene::firstObjectId

◆ secondObjectId

s16 BattleFxScene::secondObjectId

the target's object id, -1 for none

Definition at line 39 of file fx_scene.h.

Referenced by BattleFx_ClearChildValueOnMismatch(), BattleFx_DispatchRequestKind(), BattleFx_Run(), and BattleFx_SetupObjectPair().

◆ action

u16 BattleFxScene::action

the ability id

Definition at line 40 of file fx_scene.h.

Referenced by BattleFx_LoadActionEffectResources(), and EventObject_Initialize().

◆ fieldKind

◆ enabled

s8 BattleFxScene::enabled

Set at the start: Force then aims in front of the caster; cleared once the target has been dispatched.

Definition at line 44 of file fx_scene.h.

Referenced by BattleFx_DispatchRequestKind(), BattleFx_LoadActionEffectResources(), FieldFx_RunCatch(), FieldFx_RunForce(), FieldFx_RunFrost(), FieldFx_RunFrostOnTarget(), FieldFx_RunPly(), and FieldFx_RunWhirlwind().

◆ mode

u8 BattleFxScene::mode

where the effect runs; MODE_WORLD_MAP on the world map

Definition at line 45 of file fx_scene.h.

Referenced by AltmillerCave_ReleaseWallBurst(), BattleFx_LoadActionEffectResources(), and EventObject_Initialize().

◆ visible

s8 BattleFxScene::visible

set at the start: the caster flashes with a sound

Definition at line 46 of file fx_scene.h.

Referenced by BattleFx_LoadActionEffectResources(), and EventObject_Initialize().

◆ active

s8 BattleFxScene::active

set at the start: the ability's name is announced

Definition at line 47 of file fx_scene.h.

Referenced by AltmillerCave_ReleaseWallBurst(), BattleFx_LoadActionEffectResources(), and EventObject_Initialize().

◆ finishCallback

void(*) BattleFxScene::finishCallback(void)

run, when set, as Ply's effect ends

Definition at line 48 of file fx_scene.h.

Referenced by FieldFx_RunPly().

◆ unk28

u8 BattleFxScene::unk28[0x0c]

not named by TBS code

Definition at line 49 of file fx_scene.h.

◆ childOption

s8 BattleFxScene::childOption

Set by some scenes before an effect; Carry, Frost, Force and Reveal treat the target differently with it.

Definition at line 52 of file fx_scene.h.

Referenced by AltmillerCave_EndReveal(), BabiLighthouse_EnableChildOption(), Event_DouseCastAtStorm(), Event_StartDousingTravelMarker(), FieldFx_RunForce(), FieldFx_RunFrost(), Fuchin_EndRevealLighting(), and ResetSceneTransitionEffect().

◆ childMode

s8 BattleFxScene::childMode

◆ unk36

u8 BattleFxScene::unk36[2]

not named by TBS code

Definition at line 54 of file fx_scene.h.

◆ savedCallback

void(*) BattleFxScene::savedCallback(union FieldObject *object)

The target's update hook and script, saved at the start and restored when Move or Carry lets it go.

Definition at line 58 of file fx_scene.h.

Referenced by BattleFx_SetupObjectPair().

◆ savedScript

const s32* BattleFxScene::savedScript

Definition at line 59 of file fx_scene.h.

Referenced by BattleFx_SetupObjectPair().

◆ unk40

u8 BattleFxScene::unk40[4]

not named by TBS code

Definition at line 61 of file fx_scene.h.

◆ savedPalette

u8 BattleFxScene::savedPalette

the target's first sprite's param, saved likewise

Definition at line 62 of file fx_scene.h.

Referenced by BattleFx_SetupObjectPair().

◆ lit

u8 BattleFxScene::lit

set in two Mercury Lighthouse maps; not read by name

Definition at line 63 of file fx_scene.h.

Referenced by BattleFx_LoadActionEffectResources().

◆ tileSlot

◆ unk48

u16 BattleFxScene::unk48

not named by TBS code

Definition at line 65 of file fx_scene.h.

◆ freeBlocks

u16 BattleFxScene::freeBlocks

512 less the free resource blocks at the start

Definition at line 66 of file fx_scene.h.

Referenced by BattleFx_LoadActionEffectResources().

◆ savedShakeX

s32 BattleFxScene::savedShakeX

The map's shake and its decay, restored when the effect ends.

Definition at line 69 of file fx_scene.h.

Referenced by BattleEffect_CleanupSceneObjects(), and BattleFx_LoadActionEffectResources().

◆ savedShakeY

s32 BattleFxScene::savedShakeY

◆ savedShakeDecay

s32 BattleFxScene::savedShakeDecay

◆ slots

◆ unk718

u8 BattleFxScene::unk718[2]

not named by TBS code

Definition at line 74 of file fx_scene.h.

◆ arcTileSlot

s16 BattleFxScene::arcTileSlot

resource entry of Avoid's and Retreat's arcs

Definition at line 75 of file fx_scene.h.

Referenced by BattleFx_SpawnDescendingArcParticles(), and FieldFx_RunAvoid().

◆ messageMode

s8 BattleFxScene::messageMode

the announcement's box mode: 1, a scene adds 8

Definition at line 76 of file fx_scene.h.

Referenced by BattleFx_LoadActionEffectResources(), EventObject_Initialize(), and MercuryLighthouse_MiaCastsPlyOnEntrance().

◆ unk71d

u8 BattleFxScene::unk71d[3]

not named by TBS code

Definition at line 77 of file fx_scene.h.