Alchemy
Loading...
Searching...
No Matches

DisplayTransitionState Struct Reference

The display transition state (heap block 31): two pages of window edges for every line, the dissolve's solid tile, and the transition's mode and progress. More...

#include <graphics/display_transition.h>

Data Fields

u16 pages [2][322]
 Window edges, two pages: WININ and WINOUT, then a WIN0H and WIN1H pair, each (left << 8 | right), for each of the 160 lines.
u32 solidTile [8]
 The dissolve's solid tile, one 8 by 8 tile of 4-bit pixels.
u16 mode
 The window transition's shape: modes are listed at DisplayTransition_UpdateScanlineTable.
u16 value
 The progress, moved from start to end over duration frames: bit 5 says whether the transition opens or closes, the low 5 bits how far it is.
s32 centreX
 16.16 fixed-point pixels: the centre of the ellipse around a point (mode 8), set by the Reveal effect.
s32 centreY
 as centreX: the target's z less its y
s16 mask
 WINOUT, or WININ by mode: 0x3f3f or 63 when a transition starts.
s16 active
 WININ, or WINOUT by mode: 1 when a transition starts.
u8 unk538
 not named by TBS code
u8 page
 the pages entry shown; the next is built in the other
s8 start
 the value's first step
s8 end
 the value's last step; 64 hides BG1 to BG3 and sprites
s8 duration
 frames; 0 when the value is not moving
s8 step
 frames
s8 nextMode
 The mode taken when the value reaches its end; 0 ends the transition.

Detailed Description

The display transition state (heap block 31): two pages of window edges for every line, the dissolve's solid tile, and the transition's mode and progress.

Definition at line 56 of file display_transition.h.

Field Documentation

◆ pages

u16 DisplayTransitionState::pages[2][322]

Window edges, two pages: WININ and WINOUT, then a WIN0H and WIN1H pair, each (left << 8 | right), for each of the 160 lines.

Definition at line 59 of file display_transition.h.

Referenced by AffineEffect_UpdateFrame(), BattleFx_StartWindowHBlankDma(), and DisplayTransition_UpdateScanlineTable().

◆ solidTile

u32 DisplayTransitionState::solidTile[8]

The dissolve's solid tile, one 8 by 8 tile of 4-bit pixels.

Definition at line 61 of file display_transition.h.

Referenced by DisplayTransition_FillTilemapAndSolidTile().

◆ mode

u16 DisplayTransitionState::mode

The window transition's shape: modes are listed at DisplayTransition_UpdateScanlineTable.

Definition at line 64 of file display_transition.h.

Referenced by DisplayTransition_Finish(), DisplayTransition_InitializeBattleEffectState(), DisplayTransition_InitializeState(), DisplayTransition_Start(), and DisplayTransition_UpdateScanlineTable().

◆ value

u16 DisplayTransitionState::value

◆ centreX

s32 DisplayTransitionState::centreX

16.16 fixed-point pixels: the centre of the ellipse around a point (mode 8), set by the Reveal effect.

Definition at line 70 of file display_transition.h.

Referenced by DisplayTransition_UpdateScanlineTable(), and FieldFx_RunReveal().

◆ centreY

s32 DisplayTransitionState::centreY

as centreX: the target's z less its y

Definition at line 71 of file display_transition.h.

Referenced by DisplayTransition_UpdateScanlineTable(), and FieldFx_RunReveal().

◆ mask

◆ active

◆ unk538

u8 DisplayTransitionState::unk538

not named by TBS code

Definition at line 76 of file display_transition.h.

◆ page

u8 DisplayTransitionState::page

the pages entry shown; the next is built in the other

Definition at line 77 of file display_transition.h.

Referenced by AffineEffect_UpdateFrame(), BattleFx_StartWindowHBlankDma(), and DisplayTransition_UpdateScanlineTable().

◆ start

s8 DisplayTransitionState::start

◆ end

s8 DisplayTransitionState::end

the value's last step; 64 hides BG1 to BG3 and sprites

Definition at line 79 of file display_transition.h.

Referenced by DisplayTransition_Finish(), DisplayTransition_Start(), DisplayTransition_UpdateScanlineTable(), and WorldMap_BeginEvent().

◆ duration

s8 DisplayTransitionState::duration

◆ step

◆ nextMode

s8 DisplayTransitionState::nextMode

The mode taken when the value reaches its end; 0 ends the transition.

Definition at line 83 of file display_transition.h.

Referenced by DisplayTransition_UpdateScanlineTable(), Fuchin_EndRevealLighting(), and ResetSceneTransitionEffect().