yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
special_routines.cc File Reference

Go to the source code of this file.

Namespaces

namespace  yaze
 
namespace  yaze::zelda3
 Zelda 3 specific classes and functions.
 
namespace  yaze::zelda3::draw_routines
 
namespace  yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}
 

Functions

const gfx::TileInfoyaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::TileAtWrapped (std::span< const gfx::TileInfo > tiles, size_t index)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawColumnMajor (gfx::BackgroundBuffer &bg, int base_x, int base_y, int w, int h, std::span< const gfx::TileInfo > tiles, size_t start_index=0)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawRowMajor (gfx::BackgroundBuffer &bg, int base_x, int base_y, int w, int h, std::span< const gfx::TileInfo > tiles, size_t start_index=0)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::Draw1x3NRightwards (const DrawContext &ctx, int columns, size_t start_index, int y_offset=0)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawNx4 (const DrawContext &ctx, int columns, size_t start_index)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::Draw1x5Column (const DrawContext &ctx, int x_offset, size_t start_index)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::Draw4x4ColumnMajor (const DrawContext &ctx, int x_offset, int y_offset, size_t start_index)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawFloorLightGrid (const DrawContext &ctx)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::Draw4x4ColumnMajorTo (gfx::BackgroundBuffer &bg, const RoomObject &object, std::span< const gfx::TileInfo > tiles)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawMany32x32Block (gfx::BackgroundBuffer &bg, int base_x, int base_y, std::span< const gfx::TileInfo > tiles)
 
bool yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::IsAutoStairsDualLayer (int16_t object_id)
 
bool yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::IsStraightInterroomUpper (int16_t object_id)
 
bool yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::IsStraightInterroomLower (int16_t object_id)
 
bool yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::IsSouthLowerStraightInterroomStairs (int16_t object_id)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawWaterHopStairsA (const DrawContext &ctx)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawWaterHopStairsB (const DrawContext &ctx)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawDamFloodGate (const DrawContext &ctx)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::WritePlatformTile (const DrawContext &ctx, int dx, int dy, size_t index)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawPlatform1x3Rightwards (const DrawContext &ctx, int dx, int dy, size_t start_index, int columns)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawPlatform2x2 (const DrawContext &ctx, int dx, int dy, size_t start_index)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawPlatform3x2 (const DrawContext &ctx, int dx, int dy, size_t start_index)
 
std::array< gfx::TileInfo, 3 > yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::LoadMovingWallFillTiles (const DrawContext &ctx)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawMovingWallFill (const DrawContext &ctx, int start_x, int column_count, int height)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawMovingWallPlatform (const DrawContext &ctx, int direction)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawOpenChestPlatformSegment (const DrawContext &ctx, int dy, size_t start_index, int fill_width)
 
void yaze::zelda3::draw_routines::DrawChest (const DrawContext &ctx, int chest_index)
 Draw a small chest with open/closed state support.
 
void yaze::zelda3::draw_routines::DrawNothing (const DrawContext &ctx)
 Draw nothing - represents invisible logic objects or placeholders.
 
void yaze::zelda3::draw_routines::CustomDraw (const DrawContext &ctx)
 Custom draw routine for special objects.
 
void yaze::zelda3::draw_routines::DrawDoorSwitcherer (const DrawContext &ctx)
 Draw door switcher object with state-based graphics.
 
void yaze::zelda3::draw_routines::DrawSomariaLine (const DrawContext &ctx)
 Draw one Somaria path tile at the object anchor.
 
void yaze::zelda3::draw_routines::DrawWaterFace (const DrawContext &ctx)
 Draw a generic 2x2 water-face helper pattern.
 
void yaze::zelda3::draw_routines::DrawLargeCanvasObject (const DrawContext &ctx, int width, int height)
 Draw large canvas object with arbitrary dimensions.
 
void yaze::zelda3::draw_routines::DrawBed4x5 (const DrawContext &ctx)
 Draw a 4x5 bed pattern (row-major)
 
void yaze::zelda3::draw_routines::DrawRightwards3x6 (const DrawContext &ctx)
 Draw a 6x3 pattern via RoomDraw_1x3N_rightwards semantics.
 
void yaze::zelda3::draw_routines::DrawUtility6x3 (const DrawContext &ctx)
 Draw utility 6x3 pattern via RoomDraw_1x3N_rightwards.
 
void yaze::zelda3::draw_routines::DrawUtility3x5 (const DrawContext &ctx)
 Draw utility 3x5 pattern (special row pattern)
 
void yaze::zelda3::draw_routines::DrawVerticalTurtleRockPipe (const DrawContext &ctx)
 Draw vertical Turtle Rock pipe (two stacked 4x3 sections)
 
void yaze::zelda3::draw_routines::DrawHorizontalTurtleRockPipe (const DrawContext &ctx)
 Draw horizontal Turtle Rock pipe (6x4)
 
void yaze::zelda3::draw_routines::DrawLightBeamOnFloor (const DrawContext &ctx)
 Draw floor light beam composed of three 4x4 blocks.
 
void yaze::zelda3::draw_routines::DrawBigLightBeamOnFloor (const DrawContext &ctx)
 Draw state-gated big floor light beam active variant (8x8 footprint)
 
void yaze::zelda3::draw_routines::DrawFloorLight (const DrawContext &ctx)
 Draw unconditional floor light (8x8 footprint)
 
void yaze::zelda3::draw_routines::DrawBossShell4x4 (const DrawContext &ctx)
 Draw boss shell 4x4.
 
void yaze::zelda3::draw_routines::DrawSolidWallDecor3x4 (const DrawContext &ctx)
 Draw solid wall decor 3x4.
 
void yaze::zelda3::draw_routines::DrawArcheryGameTargetDoor (const DrawContext &ctx)
 Draw archery game target door (two 3x3 sections)
 
void yaze::zelda3::draw_routines::DrawGanonTriforceFloorDecor (const DrawContext &ctx)
 Draw Ganon triforce floor decor (three 4x4 sections)
 
void yaze::zelda3::draw_routines::DrawSingle2x2 (const DrawContext &ctx)
 Draw a single 2x2 block (column-major order)
 
void yaze::zelda3::draw_routines::DrawSingle4x4 (const DrawContext &ctx)
 Draw a single 4x4 block (column-major order)
 
void yaze::zelda3::draw_routines::DrawSingle4x3 (const DrawContext &ctx)
 Draw a single 4x3 block (column-major order)
 
void yaze::zelda3::draw_routines::DrawRupeeFloor (const DrawContext &ctx)
 Draw the blue rupee floor pattern (5x8 bounds with gaps)
 
void yaze::zelda3::draw_routines::DrawActual4x4 (const DrawContext &ctx)
 Draw an actual 4x4 tile8 pattern (column-major order)
 
void yaze::zelda3::draw_routines::DrawWaterfall47 (const DrawContext &ctx)
 Draw waterfall object 0x47 pattern.
 
void yaze::zelda3::draw_routines::DrawWaterfall48 (const DrawContext &ctx)
 Draw waterfall object 0x48 pattern.
 
void yaze::zelda3::draw_routines::Draw4x4BlocksIn4x4SuperSquare (const DrawContext &ctx)
 Draw 4x4 solid blocks in a super square grid.
 
void yaze::zelda3::draw_routines::Draw3x3FloorIn4x4SuperSquare (const DrawContext &ctx)
 Draw 3x3 floor pattern in super square units.
 
void yaze::zelda3::draw_routines::Draw4x4FloorIn4x4SuperSquare (const DrawContext &ctx)
 Draw 4x4 floor pattern in super square units.
 
void yaze::zelda3::draw_routines::Draw4x4FloorOneIn4x4SuperSquare (const DrawContext &ctx)
 Draw single 4x4 floor pattern variant.
 
void yaze::zelda3::draw_routines::Draw4x4FloorTwoIn4x4SuperSquare (const DrawContext &ctx)
 Draw two 4x4 floor pattern variant.
 
void yaze::zelda3::draw_routines::DrawBigHole4x4_1to16 (const DrawContext &ctx)
 Draw 4x4 big hole pattern.
 
void yaze::zelda3::draw_routines::DrawSpike2x2In4x4SuperSquare (const DrawContext &ctx)
 Draw 2x2 spike pattern in super square units.
 
void yaze::zelda3::draw_routines::DrawTableRock4x4_1to16 (const DrawContext &ctx)
 Draw 4x4 table rock pattern.
 
void yaze::zelda3::draw_routines::DrawWaterOverlay8x8_1to16 (const DrawContext &ctx)
 Draw water overlay 8x8 pattern.
 
void yaze::zelda3::draw_routines::DrawInterRoomFatStairsUp (const DrawContext &ctx)
 Draw inter-room fat stairs going up (Type 2 object 0x12D)
 
void yaze::zelda3::draw_routines::DrawInterRoomFatStairsDownA (const DrawContext &ctx)
 Draw inter-room fat stairs going down A (Type 2 object 0x12E)
 
void yaze::zelda3::draw_routines::DrawInterRoomFatStairsDownB (const DrawContext &ctx)
 Draw inter-room fat stairs going down B (Type 2 object 0x12F)
 
void yaze::zelda3::draw_routines::DrawSpiralStairs (const DrawContext &ctx, bool going_up, bool is_upper)
 Draw spiral stairs (Type 2 objects 0x138-0x13B)
 
void yaze::zelda3::draw_routines::DrawAutoStairs (const DrawContext &ctx)
 Draw auto stairs (Type 2/3 objects 0x130-0x133, 0x21B-0x21D, 0x233)
 
void yaze::zelda3::draw_routines::DrawStraightInterRoomStairs (const DrawContext &ctx)
 Draw straight inter-room stairs (Type 3 objects 0x21E-0x229)
 
void yaze::zelda3::draw_routines::DrawPrisonCell (const DrawContext &ctx)
 Draw prison cell with bars (Type 3 objects 0x20D, 0x217)
 
void yaze::zelda3::draw_routines::DrawBigKeyLock (const DrawContext &ctx)
 Draw a closed big key lock (Yaze 0xF98 / ASM object 0x218)
 
void yaze::zelda3::draw_routines::DrawBombableFloor (const DrawContext &ctx)
 Draw bombable floor (Type 3 object 0xFC7 / ASM object 0x247)
 
void yaze::zelda3::draw_routines::DrawMovingWallWest (const DrawContext &ctx)
 Draw the west-moving wall (Type 1 object 0xCD)
 
void yaze::zelda3::draw_routines::DrawMovingWallEast (const DrawContext &ctx)
 Draw the east-moving wall (Type 1 object 0xCE)
 
void yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::DrawWaterFaceRows (const DrawContext &ctx, int row_count, int tile_offset)
 
void yaze::zelda3::draw_routines::DrawEmptyWaterFace (const DrawContext &ctx)
 Draw empty water face (Type 3 object 0x200)
 
void yaze::zelda3::draw_routines::DrawSpittingWaterFace (const DrawContext &ctx)
 Draw spitting water face (Type 3 object 0x201)
 
void yaze::zelda3::draw_routines::DrawDrenchingWaterFace (const DrawContext &ctx)
 Draw drenching water face (Type 3 object 0x202)
 
void yaze::zelda3::draw_routines::DrawClosedChestPlatform (const DrawContext &ctx)
 Draw closed chest platform (Type 1 object 0xC1)
 
void yaze::zelda3::draw_routines::DrawOpenChestPlatform (const DrawContext &ctx)
 Draw open chest platform (Type 1 object 0xDC)
 
void yaze::zelda3::draw_routines::DrawChestPlatformHorizontalWall (const DrawContext &ctx)
 Draw chest platform horizontal wall section.
 
void yaze::zelda3::draw_routines::DrawChestPlatformVerticalWall (const DrawContext &ctx)
 Draw chest platform vertical wall section.
 
void yaze::zelda3::draw_routines::RegisterSpecialRoutines (std::vector< DrawRoutineInfo > &registry)
 Register all special/miscellaneous draw routines to the registry.
 

Variables

constexpr int yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::kThievesTownEastAtticRoomId = 0x65
 
constexpr int yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::kMovingWallFillDataOffset = kRoomObjectTileAddress + 0x03D8
 
constexpr std::array< uint16_t, 3 > yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::kMovingWallFallbackFillWords
 
constexpr int yaze::zelda3::draw_routines::anonymous_namespace{special_routines.cc}::kWaterFaceWidthTiles = 4