Skip to Content
The Alchemy Project

src/scene/shared/map_grid_panel.c

Crossbone Isle Cave (SceneIdCrossboneIsleSteppingStones to SceneIdCrossboneIsleDragonStatue) and Kolima Forest (SceneIdKolimaForestFloodgate): drawing a stretch of the layout, in one of the states kept elsewhere in it (such as the water raised or not), straight into the background's tile map.

Included by crossbone_isle_stepping_stones.c and kolima_forest_floodgate.c.

Macros

NameDescription
#defineSCREEN_BLOCK_METATILES (BG_SCREEN_WIDTH / 2)Metatiles across and down a screen block: 32 tiles square, two tiles a metatile.

Functions

NameDescription
static voidscMapGridDrawMetatilePanel (Sint32 x, Sint32 y, Sint32 width, Sint32 height, Sint32 plane, Sint32 destX, Sint32 destY)Draws the width by height metatiles from metatile (x, y) of the layout into screen block 5 at metatile (destX, destY), wrapping every SCREEN_BLOCK_METATILES metatiles.

Description

Crossbone Isle Cave (SceneIdCrossboneIsleSteppingStones to SceneIdCrossboneIsleDragonStatue) and Kolima Forest (SceneIdKolimaForestFloodgate): drawing a stretch of the layout, in one of the states kept elsewhere in it (such as the water raised or not), straight into the background's tile map.

Macros in detail

SCREEN_BLOCK_METATILES

#define SCREEN_BLOCK_METATILES (BG_SCREEN_WIDTH / 2)

Metatiles across and down a screen block: 32 tiles square, two tiles a metatile.

Referenced by scMapGridDrawMetatilePanel().

Definition at line 11 of file map_grid_panel.c.

Functions in detail

scMapGridDrawMetatilePanel

static void scMapGridDrawMetatilePanel(Sint32 x, Sint32 y, Sint32 width, Sint32 height, Sint32 plane, Sint32 destX, Sint32 destY)

Draws the width by height metatiles from metatile (x, y) of the layout into screen block 5 at metatile (destX, destY), wrapping every SCREEN_BLOCK_METATILES metatiles. The block is cut into horizontal planes of SCREEN_BLOCK_METATILES metatile rows; plane picks which one is drawn into.

References Sint32 and width.

Referenced by scCrossboneIsleSteppingStonesAnimateWaterLevel() and scKolimaForestFloodgateFlipFloodgateSwitch().

Definition at line 17 of file map_grid_panel.c.