Eliminate METATILE_ID() macro

This commit is contained in:
GriffinR 2020-07-02 00:17:14 -04:00
parent c84f98a7ff
commit 8589e138a8
7 changed files with 214 additions and 214 deletions

View File

@ -87,12 +87,12 @@ bool8 ShouldDoBrailleDigEffect(void)
void DoBrailleDigEffect(void) void DoBrailleDigEffect(void)
{ {
MapGridSetMetatileIdAt(16, 8, METATILE_ID(Cave, SealedChamberEntrance_TopLeft)); MapGridSetMetatileIdAt(16, 8, METATILE_Cave_SealedChamberEntrance_TopLeft);
MapGridSetMetatileIdAt(17, 8, METATILE_ID(Cave, SealedChamberEntrance_TopMid)); MapGridSetMetatileIdAt(17, 8, METATILE_Cave_SealedChamberEntrance_TopMid);
MapGridSetMetatileIdAt(18, 8, METATILE_ID(Cave, SealedChamberEntrance_TopRight)); MapGridSetMetatileIdAt(18, 8, METATILE_Cave_SealedChamberEntrance_TopRight);
MapGridSetMetatileIdAt(16, 9, METATILE_ID(Cave, SealedChamberEntrance_BottomLeft) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(16, 9, METATILE_Cave_SealedChamberEntrance_BottomLeft | METATILE_COLLISION_MASK);
MapGridSetMetatileIdAt(17, 9, METATILE_ID(Cave, SealedChamberEntrance_BottomMid)); MapGridSetMetatileIdAt(17, 9, METATILE_Cave_SealedChamberEntrance_BottomMid);
MapGridSetMetatileIdAt(18, 9, METATILE_ID(Cave, SealedChamberEntrance_BottomRight) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 9, METATILE_Cave_SealedChamberEntrance_BottomRight | METATILE_COLLISION_MASK);
DrawWholeMapView(); DrawWholeMapView();
PlaySE(SE_BAN); PlaySE(SE_BAN);
FlagSet(FLAG_SYS_BRAILLE_DIG); FlagSet(FLAG_SYS_BRAILLE_DIG);
@ -280,12 +280,12 @@ void UseRegirockHm_Callback(void)
void DoBrailleRegirockEffect(void) void DoBrailleRegirockEffect(void)
{ {
MapGridSetMetatileIdAt(14, 26, METATILE_ID(Cave, SealedChamberEntrance_TopLeft)); MapGridSetMetatileIdAt(14, 26, METATILE_Cave_SealedChamberEntrance_TopLeft);
MapGridSetMetatileIdAt(15, 26, METATILE_ID(Cave, SealedChamberEntrance_TopMid)); MapGridSetMetatileIdAt(15, 26, METATILE_Cave_SealedChamberEntrance_TopMid);
MapGridSetMetatileIdAt(16, 26, METATILE_ID(Cave, SealedChamberEntrance_TopRight)); MapGridSetMetatileIdAt(16, 26, METATILE_Cave_SealedChamberEntrance_TopRight);
MapGridSetMetatileIdAt(14, 27, METATILE_ID(Cave, SealedChamberEntrance_BottomLeft) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(14, 27, METATILE_Cave_SealedChamberEntrance_BottomLeft | METATILE_COLLISION_MASK);
MapGridSetMetatileIdAt(15, 27, METATILE_ID(Cave, SealedChamberEntrance_BottomMid)); MapGridSetMetatileIdAt(15, 27, METATILE_Cave_SealedChamberEntrance_BottomMid);
MapGridSetMetatileIdAt(16, 27, METATILE_ID(Cave, SealedChamberEntrance_BottomRight) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(16, 27, METATILE_Cave_SealedChamberEntrance_BottomRight | METATILE_COLLISION_MASK);
DrawWholeMapView(); DrawWholeMapView();
PlaySE(SE_BAN); PlaySE(SE_BAN);
FlagSet(FLAG_SYS_REGIROCK_PUZZLE_COMPLETED); FlagSet(FLAG_SYS_REGIROCK_PUZZLE_COMPLETED);
@ -319,12 +319,12 @@ void UseRegisteelHm_Callback(void)
void DoBrailleRegisteelEffect(void) void DoBrailleRegisteelEffect(void)
{ {
MapGridSetMetatileIdAt(14, 26, METATILE_ID(Cave, SealedChamberEntrance_TopLeft)); MapGridSetMetatileIdAt(14, 26, METATILE_Cave_SealedChamberEntrance_TopLeft);
MapGridSetMetatileIdAt(15, 26, METATILE_ID(Cave, SealedChamberEntrance_TopMid)); MapGridSetMetatileIdAt(15, 26, METATILE_Cave_SealedChamberEntrance_TopMid);
MapGridSetMetatileIdAt(16, 26, METATILE_ID(Cave, SealedChamberEntrance_TopRight)); MapGridSetMetatileIdAt(16, 26, METATILE_Cave_SealedChamberEntrance_TopRight);
MapGridSetMetatileIdAt(14, 27, METATILE_ID(Cave, SealedChamberEntrance_BottomLeft) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(14, 27, METATILE_Cave_SealedChamberEntrance_BottomLeft | METATILE_COLLISION_MASK);
MapGridSetMetatileIdAt(15, 27, METATILE_ID(Cave, SealedChamberEntrance_BottomMid)); MapGridSetMetatileIdAt(15, 27, METATILE_Cave_SealedChamberEntrance_BottomMid);
MapGridSetMetatileIdAt(16, 27, METATILE_ID(Cave, SealedChamberEntrance_BottomRight) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(16, 27, METATILE_Cave_SealedChamberEntrance_BottomRight | METATILE_COLLISION_MASK);
DrawWholeMapView(); DrawWholeMapView();
PlaySE(SE_BAN); PlaySE(SE_BAN);
FlagSet(FLAG_SYS_REGISTEEL_PUZZLE_COMPLETED); FlagSet(FLAG_SYS_REGISTEEL_PUZZLE_COMPLETED);

View File

@ -3816,7 +3816,7 @@ static void SpriteCB_DeoxysRockFragment(struct Sprite* sprite)
sprite->pos1.y += 12; sprite->pos1.y += 12;
break; break;
} }
if ((u16)(sprite->pos1.x + 4) > 248 || sprite->pos1.y < -4 || sprite->pos1.y > 164) if ((u16)(sprite->pos1.x + 4) > DISPLAY_WIDTH + 8 || sprite->pos1.y < -4 || sprite->pos1.y > DISPLAY_HEIGHT + 4)
DestroySprite(sprite); DestroySprite(sprite);
} }
@ -3834,7 +3834,7 @@ bool8 FldEff_MoveDeoxysRock(struct Sprite* sprite)
xPos = (gFieldEffectArguments[3] - xPos) * 16; xPos = (gFieldEffectArguments[3] - xPos) * 16;
yPos = (gFieldEffectArguments[4] - yPos) * 16; yPos = (gFieldEffectArguments[4] - yPos) * 16;
ShiftObjectEventCoords(object, gFieldEffectArguments[3] + 7, gFieldEffectArguments[4] + 7); ShiftObjectEventCoords(object, gFieldEffectArguments[3] + 7, gFieldEffectArguments[4] + 7);
taskId = CreateTask(Task_MoveDeoxysRock, 0x50); taskId = CreateTask(Task_MoveDeoxysRock, 80);
gTasks[taskId].data[1] = object->spriteId; gTasks[taskId].data[1] = object->spriteId;
gTasks[taskId].data[2] = gSprites[object->spriteId].pos1.x + xPos; gTasks[taskId].data[2] = gSprites[object->spriteId].pos1.x + xPos;
gTasks[taskId].data[3] = gSprites[object->spriteId].pos1.y + yPos; gTasks[taskId].data[3] = gSprites[object->spriteId].pos1.y + yPos;

View File

@ -216,9 +216,9 @@ void Task_HandleTruckSequence(u8 taskId)
data[1]++; data[1]++;
if (data[1] == 120) if (data[1] == 120)
{ {
MapGridSetMetatileIdAt(11, 8, METATILE_ID(InsideOfTruck, ExitLight_Top)); MapGridSetMetatileIdAt(11, 8, METATILE_InsideOfTruck_ExitLight_Top);
MapGridSetMetatileIdAt(11, 9, METATILE_ID(InsideOfTruck, ExitLight_Mid)); MapGridSetMetatileIdAt(11, 9, METATILE_InsideOfTruck_ExitLight_Mid);
MapGridSetMetatileIdAt(11, 10, METATILE_ID(InsideOfTruck, ExitLight_Bottom)); MapGridSetMetatileIdAt(11, 10, METATILE_InsideOfTruck_ExitLight_Bottom);
DrawWholeMapView(); DrawWholeMapView();
PlaySE(SE_TRACK_DOOR); PlaySE(SE_TRACK_DOOR);
DestroyTask(taskId); DestroyTask(taskId);
@ -230,9 +230,9 @@ void Task_HandleTruckSequence(u8 taskId)
void ExecuteTruckSequence(void) void ExecuteTruckSequence(void)
{ {
MapGridSetMetatileIdAt(11, 8, METATILE_ID(InsideOfTruck, DoorClosedFloor_Top)); MapGridSetMetatileIdAt(11, 8, METATILE_InsideOfTruck_DoorClosedFloor_Top);
MapGridSetMetatileIdAt(11, 9, METATILE_ID(InsideOfTruck, DoorClosedFloor_Mid)); MapGridSetMetatileIdAt(11, 9, METATILE_InsideOfTruck_DoorClosedFloor_Mid);
MapGridSetMetatileIdAt(11, 10, METATILE_ID(InsideOfTruck, DoorClosedFloor_Bottom)); MapGridSetMetatileIdAt(11, 10, METATILE_InsideOfTruck_DoorClosedFloor_Bottom);
DrawWholeMapView(); DrawWholeMapView();
ScriptContext2_Enable(); ScriptContext2_Enable();
CpuFastFill(0, gPlttBufferFaded, 0x400); CpuFastFill(0, gPlttBufferFaded, 0x400);

View File

@ -656,9 +656,9 @@ void MauvilleGymPressSwitch(void)
for (i = 0; i < ARRAY_COUNT(sMauvilleGymSwitchCoords); i++) for (i = 0; i < ARRAY_COUNT(sMauvilleGymSwitchCoords); i++)
{ {
if (i == gSpecialVar_0x8004) if (i == gSpecialVar_0x8004)
MapGridSetMetatileIdAt(sMauvilleGymSwitchCoords[i].x, sMauvilleGymSwitchCoords[i].y, METATILE_ID(MauvilleGym, PressedSwitch)); MapGridSetMetatileIdAt(sMauvilleGymSwitchCoords[i].x, sMauvilleGymSwitchCoords[i].y, METATILE_MauvilleGym_PressedSwitch);
else else
MapGridSetMetatileIdAt(sMauvilleGymSwitchCoords[i].x, sMauvilleGymSwitchCoords[i].y, METATILE_ID(MauvilleGym, RaisedSwitch)); MapGridSetMetatileIdAt(sMauvilleGymSwitchCoords[i].x, sMauvilleGymSwitchCoords[i].y, METATILE_MauvilleGym_RaisedSwitch);
} }
} }
@ -673,83 +673,83 @@ void MauvilleGymSetDefaultBarriers(void)
{ {
switch (MapGridGetMetatileIdAt(x, y)) switch (MapGridGetMetatileIdAt(x, y))
{ {
case METATILE_ID(MauvilleGym, GreenBeamH1_On): case METATILE_MauvilleGym_GreenBeamH1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH1_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH1_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH2_On): case METATILE_MauvilleGym_GreenBeamH2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH2_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH2_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH3_On): case METATILE_MauvilleGym_GreenBeamH3_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH3_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH3_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH4_On): case METATILE_MauvilleGym_GreenBeamH4_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH4_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH4_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH1_Off): case METATILE_MauvilleGym_GreenBeamH1_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH1_On)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH1_On);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH2_Off): case METATILE_MauvilleGym_GreenBeamH2_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH2_On)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH2_On);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH3_Off): case METATILE_MauvilleGym_GreenBeamH3_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH3_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH3_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH4_Off): case METATILE_MauvilleGym_GreenBeamH4_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH4_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH4_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH1_On): case METATILE_MauvilleGym_RedBeamH1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH1_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH1_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH2_On): case METATILE_MauvilleGym_RedBeamH2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH2_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH2_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH3_On): case METATILE_MauvilleGym_RedBeamH3_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH3_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH3_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH4_On): case METATILE_MauvilleGym_RedBeamH4_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH4_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH4_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH1_Off): case METATILE_MauvilleGym_RedBeamH1_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH1_On)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH1_On);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH2_Off): case METATILE_MauvilleGym_RedBeamH2_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH2_On)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH2_On);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH3_Off): case METATILE_MauvilleGym_RedBeamH3_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH3_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH3_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH4_Off): case METATILE_MauvilleGym_RedBeamH4_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH4_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH4_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamV1_On): case METATILE_MauvilleGym_GreenBeamV1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleBottom_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleBottom_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamV2_On): case METATILE_MauvilleGym_GreenBeamV2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, FloorTile)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_FloorTile);
break; break;
case METATILE_ID(MauvilleGym, RedBeamV1_On): case METATILE_MauvilleGym_RedBeamV1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleBottom_Off) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleBottom_Off | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, RedBeamV2_On): case METATILE_MauvilleGym_RedBeamV2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, FloorTile)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_FloorTile);
break; break;
case METATILE_ID(MauvilleGym, PoleBottom_On): case METATILE_MauvilleGym_PoleBottom_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamV1_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamV1_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, FloorTile): case METATILE_MauvilleGym_FloorTile:
if (MapGridGetMetatileIdAt(x, y - 1) == METATILE_ID(MauvilleGym, GreenBeamV1_On)) if (MapGridGetMetatileIdAt(x, y - 1) == METATILE_MauvilleGym_GreenBeamV1_On)
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamV2_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamV2_On | METATILE_COLLISION_MASK);
else else
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamV2_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamV2_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, PoleBottom_Off): case METATILE_MauvilleGym_PoleBottom_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamV1_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamV1_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, PoleTop_Off): case METATILE_MauvilleGym_PoleTop_Off:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleTop_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleTop_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, PoleTop_On): case METATILE_MauvilleGym_PoleTop_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleTop_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleTop_Off);
break; break;
} }
} }
@ -763,7 +763,7 @@ void MauvilleGymDeactivatePuzzle(void)
const struct UCoords8 *switchCoords = sMauvilleGymSwitchCoords; const struct UCoords8 *switchCoords = sMauvilleGymSwitchCoords;
for (i = ARRAY_COUNT(sMauvilleGymSwitchCoords) - 1; i >= 0; i--) for (i = ARRAY_COUNT(sMauvilleGymSwitchCoords) - 1; i >= 0; i--)
{ {
MapGridSetMetatileIdAt(switchCoords->x, switchCoords->y, METATILE_ID(MauvilleGym, PressedSwitch)); MapGridSetMetatileIdAt(switchCoords->x, switchCoords->y, METATILE_MauvilleGym_PressedSwitch);
switchCoords++; switchCoords++;
} }
for (y = 12; y < 24; y++) for (y = 12; y < 24; y++)
@ -772,42 +772,42 @@ void MauvilleGymDeactivatePuzzle(void)
{ {
switch (MapGridGetMetatileIdAt(x, y)) switch (MapGridGetMetatileIdAt(x, y))
{ {
case METATILE_ID(MauvilleGym, GreenBeamH1_On): case METATILE_MauvilleGym_GreenBeamH1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH1_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH1_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH2_On): case METATILE_MauvilleGym_GreenBeamH2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH2_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH2_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH3_On): case METATILE_MauvilleGym_GreenBeamH3_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH3_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH3_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamH4_On): case METATILE_MauvilleGym_GreenBeamH4_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, GreenBeamH4_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_GreenBeamH4_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH1_On): case METATILE_MauvilleGym_RedBeamH1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH1_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH1_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH2_On): case METATILE_MauvilleGym_RedBeamH2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH2_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH2_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH3_On): case METATILE_MauvilleGym_RedBeamH3_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH3_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH3_Off);
break; break;
case METATILE_ID(MauvilleGym, RedBeamH4_On): case METATILE_MauvilleGym_RedBeamH4_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, RedBeamH4_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_RedBeamH4_Off);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamV1_On): case METATILE_MauvilleGym_GreenBeamV1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleBottom_On) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleBottom_On | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, RedBeamV1_On): case METATILE_MauvilleGym_RedBeamV1_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleBottom_Off) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleBottom_Off | METATILE_COLLISION_MASK);
break; break;
case METATILE_ID(MauvilleGym, GreenBeamV2_On): case METATILE_MauvilleGym_GreenBeamV2_On:
case METATILE_ID(MauvilleGym, RedBeamV2_On): case METATILE_MauvilleGym_RedBeamV2_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, FloorTile)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_FloorTile);
break; break;
case METATILE_ID(MauvilleGym, PoleTop_On): case METATILE_MauvilleGym_PoleTop_On:
MapGridSetMetatileIdAt(x, y, METATILE_ID(MauvilleGym, PoleTop_Off)); MapGridSetMetatileIdAt(x, y, METATILE_MauvilleGym_PoleTop_Off);
break; break;
} }
} }
@ -817,11 +817,11 @@ void MauvilleGymDeactivatePuzzle(void)
static const bool8 sSlidingDoorNextFrameDelay[] = {0, 1, 1, 1, 1}; static const bool8 sSlidingDoorNextFrameDelay[] = {0, 1, 1, 1, 1};
static const u16 sPetalburgGymSlidingDoorMetatiles[] = { static const u16 sPetalburgGymSlidingDoorMetatiles[] = {
METATILE_ID(PetalburgGym, SlidingDoor_Frame0), METATILE_PetalburgGym_SlidingDoor_Frame0,
METATILE_ID(PetalburgGym, SlidingDoor_Frame1), METATILE_PetalburgGym_SlidingDoor_Frame1,
METATILE_ID(PetalburgGym, SlidingDoor_Frame2), METATILE_PetalburgGym_SlidingDoor_Frame2,
METATILE_ID(PetalburgGym, SlidingDoor_Frame3), METATILE_PetalburgGym_SlidingDoor_Frame3,
METATILE_ID(PetalburgGym, SlidingDoor_Frame4), METATILE_PetalburgGym_SlidingDoor_Frame4,
}; };
void PetalburgGymSlideOpenRoomDoors(void) void PetalburgGymSlideOpenRoomDoors(void)
@ -1096,30 +1096,30 @@ static void PCTurnOnEffect_1(s16 isPcTurnedOn, s8 dx, s8 dy)
{ {
if (gSpecialVar_0x8004 == PC_LOCATION_OTHER) if (gSpecialVar_0x8004 == PC_LOCATION_OTHER)
{ {
tileId = METATILE_ID(Building, PC_Off); tileId = METATILE_Building_PC_Off;
} }
else if (gSpecialVar_0x8004 == PC_LOCATION_BRENDANS_HOUSE) else if (gSpecialVar_0x8004 == PC_LOCATION_BRENDANS_HOUSE)
{ {
tileId = METATILE_ID(BrendansMaysHouse, BrendanPC_Off); tileId = METATILE_BrendansMaysHouse_BrendanPC_Off;
} }
else if (gSpecialVar_0x8004 == PC_LOCATION_MAYS_HOUSE) else if (gSpecialVar_0x8004 == PC_LOCATION_MAYS_HOUSE)
{ {
tileId = METATILE_ID(BrendansMaysHouse, MayPC_Off); tileId = METATILE_BrendansMaysHouse_MayPC_Off;
} }
} }
else else
{ {
if (gSpecialVar_0x8004 == PC_LOCATION_OTHER) if (gSpecialVar_0x8004 == PC_LOCATION_OTHER)
{ {
tileId = METATILE_ID(Building, PC_On); tileId = METATILE_Building_PC_On;
} }
else if (gSpecialVar_0x8004 == PC_LOCATION_BRENDANS_HOUSE) else if (gSpecialVar_0x8004 == PC_LOCATION_BRENDANS_HOUSE)
{ {
tileId = METATILE_ID(BrendansMaysHouse, BrendanPC_On); tileId = METATILE_BrendansMaysHouse_BrendanPC_On;
} }
else if (gSpecialVar_0x8004 == PC_LOCATION_MAYS_HOUSE) else if (gSpecialVar_0x8004 == PC_LOCATION_MAYS_HOUSE)
{ {
tileId = METATILE_ID(BrendansMaysHouse, MayPC_On); tileId = METATILE_BrendansMaysHouse_MayPC_On;
} }
} }
MapGridSetMetatileIdAt(gSaveBlock1Ptr->pos.x + dx + 7, gSaveBlock1Ptr->pos.y + dy + 7, tileId | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(gSaveBlock1Ptr->pos.x + dx + 7, gSaveBlock1Ptr->pos.y + dy + 7, tileId | METATILE_COLLISION_MASK);
@ -1153,15 +1153,15 @@ static void PCTurnOffEffect(void)
} }
if (gSpecialVar_0x8004 == 0) if (gSpecialVar_0x8004 == 0)
{ {
tileId = METATILE_ID(Building, PC_Off); tileId = METATILE_Building_PC_Off;
} }
else if (gSpecialVar_0x8004 == 1) else if (gSpecialVar_0x8004 == 1)
{ {
tileId = METATILE_ID(BrendansMaysHouse, BrendanPC_Off); tileId = METATILE_BrendansMaysHouse_BrendanPC_Off;
} }
else if (gSpecialVar_0x8004 == 2) else if (gSpecialVar_0x8004 == 2)
{ {
tileId = METATILE_ID(BrendansMaysHouse, MayPC_Off); tileId = METATILE_BrendansMaysHouse_MayPC_Off;
} }
MapGridSetMetatileIdAt(gSaveBlock1Ptr->pos.x + dx + 7, gSaveBlock1Ptr->pos.y + dy + 7, tileId | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(gSaveBlock1Ptr->pos.x + dx + 7, gSaveBlock1Ptr->pos.y + dy + 7, tileId | METATILE_COLLISION_MASK);
DrawWholeMapView(); DrawWholeMapView();
@ -1196,13 +1196,13 @@ static void LotteryCornerComputerEffect(struct Task *task)
task->data[3] = 0; task->data[3] = 0;
if (task->data[4] != 0) if (task->data[4] != 0)
{ {
MapGridSetMetatileIdAt(18, 8, METATILE_ID(Shop, Laptop1_Normal) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 8, METATILE_Shop_Laptop1_Normal | METATILE_COLLISION_MASK);
MapGridSetMetatileIdAt(18, 9, METATILE_ID(Shop, Laptop2_Normal) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 9, METATILE_Shop_Laptop2_Normal | METATILE_COLLISION_MASK);
} }
else else
{ {
MapGridSetMetatileIdAt(18, 8, METATILE_ID(Shop, Laptop1_Flash) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 8, METATILE_Shop_Laptop1_Flash | METATILE_COLLISION_MASK);
MapGridSetMetatileIdAt(18, 9, METATILE_ID(Shop, Laptop2_Flash) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 9, METATILE_Shop_Laptop2_Flash | METATILE_COLLISION_MASK);
} }
DrawWholeMapView(); DrawWholeMapView();
task->data[4] ^= 1; task->data[4] ^= 1;
@ -1216,8 +1216,8 @@ static void LotteryCornerComputerEffect(struct Task *task)
void EndLotteryCornerComputerEffect(void) void EndLotteryCornerComputerEffect(void)
{ {
MapGridSetMetatileIdAt(18, 8, METATILE_ID(Shop, Laptop1_Normal) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 8, METATILE_Shop_Laptop1_Normal | METATILE_COLLISION_MASK);
MapGridSetMetatileIdAt(18, 9, METATILE_ID(Shop, Laptop2_Normal) | METATILE_COLLISION_MASK); MapGridSetMetatileIdAt(18, 9, METATILE_Shop_Laptop2_Normal | METATILE_COLLISION_MASK);
DrawWholeMapView(); DrawWholeMapView();
} }
@ -1751,38 +1751,38 @@ const u8 *const gDeptStoreFloorNames[] =
static const u16 sElevatorWindowTiles_Ascending[][3] = static const u16 sElevatorWindowTiles_Ascending[][3] =
{ {
{ {
METATILE_ID(BattleFrontier, Elevator_Top0), METATILE_BattleFrontier_Elevator_Top0,
METATILE_ID(BattleFrontier, Elevator_Top1), METATILE_BattleFrontier_Elevator_Top1,
METATILE_ID(BattleFrontier, Elevator_Top2) METATILE_BattleFrontier_Elevator_Top2
}, },
{ {
METATILE_ID(BattleFrontier, Elevator_Mid0), METATILE_BattleFrontier_Elevator_Mid0,
METATILE_ID(BattleFrontier, Elevator_Mid1), METATILE_BattleFrontier_Elevator_Mid1,
METATILE_ID(BattleFrontier, Elevator_Mid2) METATILE_BattleFrontier_Elevator_Mid2
}, },
{ {
METATILE_ID(BattleFrontier, Elevator_Bottom0), METATILE_BattleFrontier_Elevator_Bottom0,
METATILE_ID(BattleFrontier, Elevator_Bottom1), METATILE_BattleFrontier_Elevator_Bottom1,
METATILE_ID(BattleFrontier, Elevator_Bottom2) METATILE_BattleFrontier_Elevator_Bottom2
}, },
}; };
static const u16 sElevatorWindowTiles_Descending[][3] = static const u16 sElevatorWindowTiles_Descending[][3] =
{ {
{ {
METATILE_ID(BattleFrontier, Elevator_Top0), METATILE_BattleFrontier_Elevator_Top0,
METATILE_ID(BattleFrontier, Elevator_Top2), METATILE_BattleFrontier_Elevator_Top2,
METATILE_ID(BattleFrontier, Elevator_Top1) METATILE_BattleFrontier_Elevator_Top1
}, },
{ {
METATILE_ID(BattleFrontier, Elevator_Mid0), METATILE_BattleFrontier_Elevator_Mid0,
METATILE_ID(BattleFrontier, Elevator_Mid2), METATILE_BattleFrontier_Elevator_Mid2,
METATILE_ID(BattleFrontier, Elevator_Mid1) METATILE_BattleFrontier_Elevator_Mid1
}, },
{ {
METATILE_ID(BattleFrontier, Elevator_Bottom0), METATILE_BattleFrontier_Elevator_Bottom0,
METATILE_ID(BattleFrontier, Elevator_Bottom2), METATILE_BattleFrontier_Elevator_Bottom2,
METATILE_ID(BattleFrontier, Elevator_Bottom1) METATILE_BattleFrontier_Elevator_Bottom1
}, },
}; };

View File

@ -52,26 +52,26 @@ static const TaskFunc sPerStepCallbacks[] =
// they are in pairs but declared as 1D array // they are in pairs but declared as 1D array
static const struct PacifidlogMetatileOffsets sHalfSubmergedBridgeMetatileOffsets[] = static const struct PacifidlogMetatileOffsets sHalfSubmergedBridgeMetatileOffsets[] =
{ {
{ 0, 0, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Vertical0)}, {0, 1, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Vertical1)}, { 0, 0, METATILE_Pacifidlog_HalfSubmergedLogs_Vertical0}, {0, 1, METATILE_Pacifidlog_HalfSubmergedLogs_Vertical1},
{ 0, -1, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Vertical0)}, {0, 0, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Vertical1)}, { 0, -1, METATILE_Pacifidlog_HalfSubmergedLogs_Vertical0}, {0, 0, METATILE_Pacifidlog_HalfSubmergedLogs_Vertical1},
{ 0, 0, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Horizontal0)}, {1, 0, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Horizontal1)}, { 0, 0, METATILE_Pacifidlog_HalfSubmergedLogs_Horizontal0}, {1, 0, METATILE_Pacifidlog_HalfSubmergedLogs_Horizontal1},
{-1, 0, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Horizontal0)}, {0, 0, METATILE_ID(Pacifidlog, HalfSubmergedLogs_Horizontal1)} {-1, 0, METATILE_Pacifidlog_HalfSubmergedLogs_Horizontal0}, {0, 0, METATILE_Pacifidlog_HalfSubmergedLogs_Horizontal1}
}; };
static const struct PacifidlogMetatileOffsets sFullySubmergedBridgeMetatileOffsets[] = static const struct PacifidlogMetatileOffsets sFullySubmergedBridgeMetatileOffsets[] =
{ {
{ 0, 0, METATILE_ID(Pacifidlog, SubmergedLogs_Vertical0)}, {0, 1, METATILE_ID(Pacifidlog, SubmergedLogs_Vertical1)}, { 0, 0, METATILE_Pacifidlog_SubmergedLogs_Vertical0}, {0, 1, METATILE_Pacifidlog_SubmergedLogs_Vertical1},
{ 0, -1, METATILE_ID(Pacifidlog, SubmergedLogs_Vertical0)}, {0, 0, METATILE_ID(Pacifidlog, SubmergedLogs_Vertical1)}, { 0, -1, METATILE_Pacifidlog_SubmergedLogs_Vertical0}, {0, 0, METATILE_Pacifidlog_SubmergedLogs_Vertical1},
{ 0, 0, METATILE_ID(Pacifidlog, SubmergedLogs_Horizontal0)}, {1, 0, METATILE_ID(Pacifidlog, SubmergedLogs_Horizontal1)}, { 0, 0, METATILE_Pacifidlog_SubmergedLogs_Horizontal0}, {1, 0, METATILE_Pacifidlog_SubmergedLogs_Horizontal1},
{-1, 0, METATILE_ID(Pacifidlog, SubmergedLogs_Horizontal0)}, {0, 0, METATILE_ID(Pacifidlog, SubmergedLogs_Horizontal1)} {-1, 0, METATILE_Pacifidlog_SubmergedLogs_Horizontal0}, {0, 0, METATILE_Pacifidlog_SubmergedLogs_Horizontal1}
}; };
static const struct PacifidlogMetatileOffsets sFloatingBridgeMetatileOffsets[] = static const struct PacifidlogMetatileOffsets sFloatingBridgeMetatileOffsets[] =
{ {
{ 0, 0, METATILE_ID(Pacifidlog, FloatingLogs_Vertical0)}, {0, 1, METATILE_ID(Pacifidlog, FloatingLogs_Vertical1)}, { 0, 0, METATILE_Pacifidlog_FloatingLogs_Vertical0}, {0, 1, METATILE_Pacifidlog_FloatingLogs_Vertical1},
{ 0, -1, METATILE_ID(Pacifidlog, FloatingLogs_Vertical0)}, {0, 0, METATILE_ID(Pacifidlog, FloatingLogs_Vertical1)}, { 0, -1, METATILE_Pacifidlog_FloatingLogs_Vertical0}, {0, 0, METATILE_Pacifidlog_FloatingLogs_Vertical1},
{ 0, 0, METATILE_ID(Pacifidlog, FloatingLogs_Horizontal0)}, {1, 0, METATILE_ID(Pacifidlog, FloatingLogs_Horizontal1)}, { 0, 0, METATILE_Pacifidlog_FloatingLogs_Horizontal0}, {1, 0, METATILE_Pacifidlog_FloatingLogs_Horizontal1},
{-1, 0, METATILE_ID(Pacifidlog, FloatingLogs_Horizontal0)}, {0, 0, METATILE_ID(Pacifidlog, FloatingLogs_Horizontal1)} {-1, 0, METATILE_Pacifidlog_FloatingLogs_Horizontal0}, {0, 0, METATILE_Pacifidlog_FloatingLogs_Horizontal1}
}; };
// Each element corresponds to a y coordinate row in the sootopolis gym 1F map. // Each element corresponds to a y coordinate row in the sootopolis gym 1F map.
@ -106,10 +106,10 @@ static const u16 sSootopolisGymIceRowVars[] =
}; };
static const u16 sMuddySlopeMetatiles[] = { static const u16 sMuddySlopeMetatiles[] = {
METATILE_ID(General, MuddySlope_Frame0), METATILE_General_MuddySlope_Frame0,
METATILE_ID(General, MuddySlope_Frame3), METATILE_General_MuddySlope_Frame3,
METATILE_ID(General, MuddySlope_Frame2), METATILE_General_MuddySlope_Frame2,
METATILE_ID(General, MuddySlope_Frame1) METATILE_General_MuddySlope_Frame1
}; };
static void Task_RunPerStepCallback(u8 taskId) static void Task_RunPerStepCallback(u8 taskId)
@ -381,11 +381,11 @@ static void SetLoweredForetreeBridgeMetatile(s16 x, s16 y)
{ {
switch (MapGridGetMetatileIdAt(x, y)) switch (MapGridGetMetatileIdAt(x, y))
{ {
case METATILE_ID(Fortree, BridgeOverGrass_Raised): case METATILE_Fortree_BridgeOverGrass_Raised:
MapGridSetMetatileIdAt(x, y, METATILE_ID(Fortree, BridgeOverGrass_Lowered)); MapGridSetMetatileIdAt(x, y, METATILE_Fortree_BridgeOverGrass_Lowered);
break; break;
case METATILE_ID(Fortree, BridgeOverTrees_Raised): case METATILE_Fortree_BridgeOverTrees_Raised:
MapGridSetMetatileIdAt(x, y, METATILE_ID(Fortree, BridgeOverTrees_Lowered)); MapGridSetMetatileIdAt(x, y, METATILE_Fortree_BridgeOverTrees_Lowered);
break; break;
} }
} }
@ -398,11 +398,11 @@ static void SetNormalFortreeBridgeMetatile(s16 x, s16 y)
{ {
switch (MapGridGetMetatileIdAt(x, y)) switch (MapGridGetMetatileIdAt(x, y))
{ {
case METATILE_ID(Fortree, BridgeOverGrass_Lowered): case METATILE_Fortree_BridgeOverGrass_Lowered:
MapGridSetMetatileIdAt(x, y, METATILE_ID(Fortree, BridgeOverGrass_Raised)); MapGridSetMetatileIdAt(x, y, METATILE_Fortree_BridgeOverGrass_Raised);
break; break;
case METATILE_ID(Fortree, BridgeOverTrees_Lowered): case METATILE_Fortree_BridgeOverTrees_Lowered:
MapGridSetMetatileIdAt(x, y, METATILE_ID(Fortree, BridgeOverTrees_Raised)); MapGridSetMetatileIdAt(x, y, METATILE_Fortree_BridgeOverTrees_Raised);
break; break;
} }
} }
@ -530,7 +530,7 @@ void SetSootopolisGymCrackedIceMetatiles(void)
for (y = 0; y < height; y++) for (y = 0; y < height; y++)
{ {
if (IsIcePuzzleCoordVisited(x, y) == TRUE) if (IsIcePuzzleCoordVisited(x, y) == TRUE)
MapGridSetMetatileIdAt(x + 7, y + 7, METATILE_ID(SootopolisGym, Ice_Cracked)); MapGridSetMetatileIdAt(x + 7, y + 7, METATILE_SootopolisGym_Ice_Cracked);
} }
} }
} }
@ -585,7 +585,7 @@ static void SootopolisGymIcePerStepCallback(u8 taskId)
x = data[4]; x = data[4];
y = data[5]; y = data[5];
PlaySE(SE_RU_BARI); PlaySE(SE_RU_BARI);
MapGridSetMetatileIdAt(x, y, METATILE_ID(SootopolisGym, Ice_Cracked)); MapGridSetMetatileIdAt(x, y, METATILE_SootopolisGym_Ice_Cracked);
CurrentMapDrawMetatileAt(x, y); CurrentMapDrawMetatileAt(x, y);
MarkIcePuzzleCoordVisited(x - 7, y - 7); MarkIcePuzzleCoordVisited(x - 7, y - 7);
data[1] = 1; data[1] = 1;
@ -601,7 +601,7 @@ static void SootopolisGymIcePerStepCallback(u8 taskId)
x = data[4]; x = data[4];
y = data[5]; y = data[5];
PlaySE(SE_RU_GASYAN); PlaySE(SE_RU_GASYAN);
MapGridSetMetatileIdAt(x, y, METATILE_ID(SootopolisGym, Ice_Broken)); MapGridSetMetatileIdAt(x, y, METATILE_SootopolisGym_Ice_Broken);
CurrentMapDrawMetatileAt(x, y); CurrentMapDrawMetatileAt(x, y);
data[1] = 1; data[1] = 1;
} }
@ -621,10 +621,10 @@ static void AshGrassPerStepCallback(u8 taskId)
data[2] = y; data[2] = y;
if (MetatileBehavior_IsAshGrass(MapGridGetMetatileBehaviorAt(x, y))) if (MetatileBehavior_IsAshGrass(MapGridGetMetatileBehaviorAt(x, y)))
{ {
if (MapGridGetMetatileIdAt(x, y) == METATILE_ID(Fallarbor, AshGrass)) if (MapGridGetMetatileIdAt(x, y) == METATILE_Fallarbor_AshGrass)
StartAshFieldEffect(x, y, METATILE_ID(Fallarbor, NormalGrass), 4); StartAshFieldEffect(x, y, METATILE_Fallarbor_NormalGrass, 4);
else else
StartAshFieldEffect(x, y, METATILE_ID(Lavaridge, NormalGrass), 4); StartAshFieldEffect(x, y, METATILE_Lavaridge_NormalGrass, 4);
if (CheckBagHasItem(ITEM_SOOT_SACK, 1)) if (CheckBagHasItem(ITEM_SOOT_SACK, 1))
{ {
@ -693,7 +693,7 @@ static void SetMuddySlopeMetatile(s16 *data, s16 x, s16 y)
MapGridSetMetatileIdAt(x, y, tile); MapGridSetMetatileIdAt(x, y, tile);
CurrentMapDrawMetatileAt(x, y); CurrentMapDrawMetatileAt(x, y);
MapGridSetMetatileIdAt(x, y, METATILE_ID(General, MuddySlope_Frame0)); MapGridSetMetatileIdAt(x, y, METATILE_General_MuddySlope_Frame0);
} }
static void Task_MuddySlope(u8 taskId) static void Task_MuddySlope(u8 taskId)

View File

@ -17,45 +17,45 @@ static void Task_DrawTeleporterCable(u8 taskId);
#define LAST_ESCALATOR_STAGE (ESCALATOR_STAGES - 1) #define LAST_ESCALATOR_STAGE (ESCALATOR_STAGES - 1)
static const u16 sElevatorMetatiles_1F_0[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_1F_0[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator1F_Tile0_Frame2), METATILE_PokemonCenter_Elevator1F_Tile0_Frame2,
METATILE_ID(PokemonCenter, Elevator1F_Tile0_Frame1), METATILE_PokemonCenter_Elevator1F_Tile0_Frame1,
METATILE_ID(PokemonCenter, Elevator1F_Tile0_Frame0) METATILE_PokemonCenter_Elevator1F_Tile0_Frame0
}; };
static const u16 sElevatorMetatiles_1F_1[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_1F_1[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator1F_Tile1_Frame2), METATILE_PokemonCenter_Elevator1F_Tile1_Frame2,
METATILE_ID(PokemonCenter, Elevator1F_Tile1_Frame1), METATILE_PokemonCenter_Elevator1F_Tile1_Frame1,
METATILE_ID(PokemonCenter, Elevator1F_Tile1_Frame0) METATILE_PokemonCenter_Elevator1F_Tile1_Frame0
}; };
static const u16 sElevatorMetatiles_1F_2[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_1F_2[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator1F_Tile2_Frame2), METATILE_PokemonCenter_Elevator1F_Tile2_Frame2,
METATILE_ID(PokemonCenter, Elevator1F_Tile2_Frame1), METATILE_PokemonCenter_Elevator1F_Tile2_Frame1,
METATILE_ID(PokemonCenter, Elevator1F_Tile2_Frame0) METATILE_PokemonCenter_Elevator1F_Tile2_Frame0
}; };
static const u16 sElevatorMetatiles_1F_3[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_1F_3[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator1F_Tile3_Frame2), METATILE_PokemonCenter_Elevator1F_Tile3_Frame2,
METATILE_ID(PokemonCenter, Elevator1F_Tile3_Frame1), METATILE_PokemonCenter_Elevator1F_Tile3_Frame1,
METATILE_ID(PokemonCenter, Elevator1F_Tile3_Frame0) METATILE_PokemonCenter_Elevator1F_Tile3_Frame0
}; };
static const u16 sElevatorMetatiles_2F_0[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_2F_0[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator2F_Tile0_Frame0), METATILE_PokemonCenter_Elevator2F_Tile0_Frame0,
METATILE_ID(PokemonCenter, Elevator2F_Tile0_Frame1), METATILE_PokemonCenter_Elevator2F_Tile0_Frame1,
METATILE_ID(PokemonCenter, Elevator2F_Tile0_Frame2) METATILE_PokemonCenter_Elevator2F_Tile0_Frame2
}; };
static const u16 sElevatorMetatiles_2F_1[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_2F_1[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator2F_Tile1_Frame0), METATILE_PokemonCenter_Elevator2F_Tile1_Frame0,
METATILE_ID(PokemonCenter, Elevator2F_Tile1_Frame1), METATILE_PokemonCenter_Elevator2F_Tile1_Frame1,
METATILE_ID(PokemonCenter, Elevator2F_Tile1_Frame2) METATILE_PokemonCenter_Elevator2F_Tile1_Frame2
}; };
static const u16 sElevatorMetatiles_2F_2[ESCALATOR_STAGES] = { static const u16 sElevatorMetatiles_2F_2[ESCALATOR_STAGES] = {
METATILE_ID(PokemonCenter, Elevator2F_Tile2_Frame0), METATILE_PokemonCenter_Elevator2F_Tile2_Frame0,
METATILE_ID(PokemonCenter, Elevator2F_Tile2_Frame1), METATILE_PokemonCenter_Elevator2F_Tile2_Frame1,
METATILE_ID(PokemonCenter, Elevator2F_Tile2_Frame2) METATILE_PokemonCenter_Elevator2F_Tile2_Frame2
}; };
#define tState data[0] #define tState data[0]

View File

@ -110,24 +110,24 @@ const struct SpriteSheet gMirageTowerCeilingCrumbleSpriteSheets[] =
static const struct MetatileCoords sInvisibleMirageTowerMetatiles[] = static const struct MetatileCoords sInvisibleMirageTowerMetatiles[] =
{ {
{18, 53, METATILE_ID(Mauville, DeepSand_Center)}, {18, 53, METATILE_Mauville_DeepSand_Center},
{19, 53, METATILE_ID(Mauville, DeepSand_Center)}, {19, 53, METATILE_Mauville_DeepSand_Center},
{20, 53, METATILE_ID(Mauville, DeepSand_Center)}, {20, 53, METATILE_Mauville_DeepSand_Center},
{18, 54, METATILE_ID(Mauville, DeepSand_Center)}, {18, 54, METATILE_Mauville_DeepSand_Center},
{19, 54, METATILE_ID(Mauville, DeepSand_Center)}, {19, 54, METATILE_Mauville_DeepSand_Center},
{20, 54, METATILE_ID(Mauville, DeepSand_Center)}, {20, 54, METATILE_Mauville_DeepSand_Center},
{18, 55, METATILE_ID(Mauville, DeepSand_Center)}, {18, 55, METATILE_Mauville_DeepSand_Center},
{19, 55, METATILE_ID(Mauville, DeepSand_Center)}, {19, 55, METATILE_Mauville_DeepSand_Center},
{20, 55, METATILE_ID(Mauville, DeepSand_Center)}, {20, 55, METATILE_Mauville_DeepSand_Center},
{18, 56, METATILE_ID(Mauville, DeepSand_Center)}, {18, 56, METATILE_Mauville_DeepSand_Center},
{19, 56, METATILE_ID(Mauville, DeepSand_Center)}, {19, 56, METATILE_Mauville_DeepSand_Center},
{20, 56, METATILE_ID(Mauville, DeepSand_Center)}, {20, 56, METATILE_Mauville_DeepSand_Center},
{18, 57, METATILE_ID(Mauville, DeepSand_BottomMid)}, {18, 57, METATILE_Mauville_DeepSand_BottomMid},
{19, 57, METATILE_ID(Mauville, DeepSand_BottomMid)}, {19, 57, METATILE_Mauville_DeepSand_BottomMid},
{20, 57, METATILE_ID(Mauville, DeepSand_BottomMid)}, {20, 57, METATILE_Mauville_DeepSand_BottomMid},
{18, 58, METATILE_ID(General, SandPit_Center)}, {18, 58, METATILE_General_SandPit_Center},
{19, 58, METATILE_ID(General, SandPit_Center)}, {19, 58, METATILE_General_SandPit_Center},
{20, 58, METATILE_ID(General, SandPit_Center)}, {20, 58, METATILE_General_SandPit_Center},
}; };
static const union AnimCmd gSpriteAnim_8617DEC[] = static const union AnimCmd gSpriteAnim_8617DEC[] =