21 if (frame->
frame == 0xFF) {
37 switch (task->
state) {
40 for (i = 0; i < 4; i++) {
48 for (j = 0; j < 4; j++) {
GfxState GFX
GFX: the graphics state and its methods.
s32 FIELDSTG_stepEffectAnim(EffectAnim *anim, AnimFrame *frames, s32 depth)
Steps one of an effect's animations, catching up on up to 4 frames, and returns its frame,...
void FIELDSTG_updateEffect(FieldEffect *task)
An effect's update: draws its animations at its spot until they end.
FieldEffect * FIELDSTG_createEffect(s32 x, s32 y, s32 set)
Creates the effect of a set at (x, y)
#define TASK_INIT
Tasks: every game object is a task, a heap block that starts with this header and is updated once per...
#define FIELD_LAYER_MAP
the map, its objects and characters, and the menus
FIELDSTG.PRO: the field mode, where the player walks around the map.
#define FIELD_SPRITES_FILE
The field's effect sprites (FIELDSTG_drawSpotEffect): the discs number their files differently.
AnimFrame * FIELDSTG_effectAnims[][4]
FIELDSTG_updateEffect's animations of each set.
FileCache FILE_CACHE
The file cache.
void initSpriteDrawer(SpriteDrawer *obj)
Clears a sprite drawer to neutral (no scale, gray tint, follows the scroll), gives it its methods and...
One frame of a sprite animation; frame 0xFF ends it (or loops it)
An animation of an FieldEffect (FIELDSTG_stepEffectAnim)
An effect of up to four animations at a spot (FIELDSTG_createEffect)
void(* setState)(struct FieldEffect *task, s32 state)
s16 set
the row of FIELDSTG_effectAnims
void(* nextState)(struct FieldEffect *task)
void *(* getEntry)(u32 fileAndIndex)
s32(* getFrameTime)(void)
struct Layer *(* getLayer)(s32 id)
A drawing layer (GFX.funcs.createLayer): a DRAWENV with a pair of ordering tables,...
Draws sprites from a sprite sheet (such as file 0x277, the menu graphics): a sheet has a table of fra...
void(* setLayer)()
(layer, depth)
void(* setClutRow)()
(row)
void(* draw)()
(sheet, frame, x, y)
void(* setTexture)()
(x, y)
void * createTask(void(*update)(), s32 size, s32 childrenSize)
createTaskWithId for a task nothing needs to find