Skip to Content
The Alchemy Project

struct MAP_GRID_LAYER_SCROLL

One background layer of the field map: its scroll position, origin, parallax against the view, drift and wrap, and its first map metatile.

Declared in map_grid.h.

Fields

NameDescription
FIXEDx, y , y16.16 fixed-point pixels
FIXEDoffsetX, offsetY , offsetY16.16 fixed-point pixels
FIXEDscaleX, scaleY , scaleY16.16 fixed point, toFIXED(1) moves with the view
FIXEDspeedX, speedY , speedY16.16 fixed-point pixels per tick
FIXEDphaseX, phaseY , phaseY16.16 fixed-point pixels
Uint16maskX, maskY , maskYa drifting layer's wrap mask, in 8-pixel tiles
MAP_GRID_METATILE *metatilesthe layer's first metatile in the map metatile buffer

Description

One background layer of the field map: its scroll position, origin, parallax against the view, drift and wrap, and its first map metatile.

struct MAP_GRID_LAYER_SCROLL

Referenced by fdMapGridCopyMetatileIndexRect(), fdMapGridCopyMetatileRect(), fdMapGridCopyMetatileTilesRect(), fdMapGridLoadMap(), fdMapGridSetCameraCenter(), fdMapGridUpdateLayerScroll(), scAltinPeakDrainFirstWater(), scAltinPeakDrainSecondWater(), scAltinPeakDrainThirdWater(), scInit(), scLunpaFortressCheckGroundFloorPatrol(), scLunpaFortressCheckHallPatrol(), scLunpaFortressCheckPatrolPair(), scMercuryLighthouseAerieAlexAppears(), scMercuryLighthouseAerieCallLift(), scMercuryLighthouseAerieLowerLift(), scMercuryLighthouseAerieRaiseLift(), scMercuryLighthouseRideLift(), scTolbiShipDeckRockDeck(), scTolbiSpringDrainSpring(), scTretTreeBranchUpdateBg3ScrollSplit(), scVaultCaveRunRumble(), scVenusLighthouseStepOnEastWallSwitch(), scVenusLighthouseStepOnWallSwitch() and scVenusLighthouseStepOnWestWallSwitch().

Definition at line 185 of file map_grid.h.

Fields in detail

x, y

FIXED x, y

16.16 fixed-point pixels

offsetX, offsetY

FIXED offsetX, offsetY

16.16 fixed-point pixels

scaleX, scaleY

FIXED scaleX, scaleY

16.16 fixed point, toFIXED(1) moves with the view

speedX, speedY

FIXED speedX, speedY

16.16 fixed-point pixels per tick

phaseX, phaseY

FIXED phaseX, phaseY

16.16 fixed-point pixels

maskX, maskY

Uint16 maskX, maskY

a drifting layer's wrap mask, in 8-pixel tiles

metatiles

MAP_GRID_METATILE *metatiles

the layer's first metatile in the map metatile buffer