Review changes
This commit is contained in:
@@ -354,9 +354,9 @@
|
||||
#define B_ANIM_BAIT_THROW 0x4
|
||||
#define B_ANIM_ITEM_KNOCKOFF 0x5
|
||||
#define B_ANIM_TURN_TRAP 0x6
|
||||
#define B_ANIM_HELD_ITEM_EFFECT 0x7
|
||||
#define B_ANIM_HELD_ITEM_EFFECT 0x7
|
||||
#define B_ANIM_SMOKEBALL_ESCAPE 0x8
|
||||
#define B_ANIM_FOCUS_BAND 0x9
|
||||
#define B_ANIM_FOCUS_BAND 0x9
|
||||
#define B_ANIM_RAIN_CONTINUES 0xA
|
||||
#define B_ANIM_SUN_CONTINUES 0xB
|
||||
#define B_ANIM_SANDSTORM_CONTINUES 0xC
|
||||
|
||||
+3
-8
@@ -356,9 +356,8 @@ void FreeMonMarkingsMenu(void)
|
||||
u16 i;
|
||||
|
||||
for (i = 0; i < 3; i++)
|
||||
{
|
||||
FreeSpriteTilesByTag(sMenu->baseTileTag + i);
|
||||
}
|
||||
|
||||
FreeSpritePaletteByTag(sMenu->basePaletteTag);
|
||||
FreeSpritePaletteByTag(sMenu->basePaletteTag + 1);
|
||||
for (i = 0; i < ARRAY_COUNT(sMenu->windowSprites); i++)
|
||||
@@ -385,20 +384,16 @@ bool8 HandleMonMarkingsMenuInput(void)
|
||||
|
||||
if (JOY_NEW(DPAD_UP))
|
||||
{
|
||||
s8 pos;
|
||||
PlaySE(SE_SELECT);
|
||||
pos = --sMenu->cursorPos;
|
||||
if (pos < 0)
|
||||
if (--sMenu->cursorPos < 0)
|
||||
sMenu->cursorPos = SELECTION_CANCEL;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
if (JOY_NEW(DPAD_DOWN))
|
||||
{
|
||||
s8 pos;
|
||||
PlaySE(SE_SELECT);
|
||||
pos = ++sMenu->cursorPos;
|
||||
if (pos > SELECTION_CANCEL)
|
||||
if (++sMenu->cursorPos > SELECTION_CANCEL)
|
||||
sMenu->cursorPos = 0;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
@@ -595,25 +595,25 @@ void InitItemInfoWindow(void)
|
||||
|
||||
bool8 UpdateItemInfoWindowSlideIn(void)
|
||||
{
|
||||
s32 i, var;
|
||||
s32 i, pos;
|
||||
|
||||
if (gPSSData->itemInfoWindowOffset == 0)
|
||||
return FALSE;
|
||||
|
||||
gPSSData->itemInfoWindowOffset--;
|
||||
var = 25 - gPSSData->itemInfoWindowOffset;
|
||||
for (i = 0; i < var; i++)
|
||||
pos = 25 - gPSSData->itemInfoWindowOffset;
|
||||
for (i = 0; i < pos; i++)
|
||||
{
|
||||
WriteSequenceToBgTilemapBuffer(0, GetBgAttribute(0, BG_ATTR_BASETILE) + 0x14 + gPSSData->itemInfoWindowOffset + i, i, 12, 1, 8, 15, 25);
|
||||
}
|
||||
|
||||
DrawItemInfoWindow(var);
|
||||
DrawItemInfoWindow(pos);
|
||||
return (gPSSData->itemInfoWindowOffset != 0);
|
||||
}
|
||||
|
||||
bool8 UpdateItemInfoWindowSlideOut(void)
|
||||
{
|
||||
s32 i, var;
|
||||
s32 i, pos;
|
||||
|
||||
if (gPSSData->itemInfoWindowOffset == 25)
|
||||
return FALSE;
|
||||
@@ -622,28 +622,28 @@ bool8 UpdateItemInfoWindowSlideOut(void)
|
||||
FillBgTilemapBufferRect(0, 0, 25, 11, 1, 10, 17);
|
||||
|
||||
gPSSData->itemInfoWindowOffset++;
|
||||
var = 25 - gPSSData->itemInfoWindowOffset;
|
||||
for (i = 0; i < var; i++)
|
||||
pos = 25 - gPSSData->itemInfoWindowOffset;
|
||||
for (i = 0; i < pos; i++)
|
||||
{
|
||||
WriteSequenceToBgTilemapBuffer(0, GetBgAttribute(0, BG_ATTR_BASETILE) + 0x14 + gPSSData->itemInfoWindowOffset + i, i, 12, 1, 8, 15, 25);
|
||||
}
|
||||
|
||||
DrawItemInfoWindow(var);
|
||||
DrawItemInfoWindow(pos);
|
||||
|
||||
FillBgTilemapBufferRect(0, 0, var, 11, 1, 10, 0x11);
|
||||
FillBgTilemapBufferRect(0, 0, pos, 11, 1, 10, 0x11);
|
||||
return (gPSSData->itemInfoWindowOffset != 25);
|
||||
}
|
||||
|
||||
static void DrawItemInfoWindow(u32 pos)
|
||||
static void DrawItemInfoWindow(u32 x)
|
||||
{
|
||||
if (pos != 0)
|
||||
if (x != 0)
|
||||
{
|
||||
FillBgTilemapBufferRect(0, 0x1A4, 0, 0xB, pos, 1, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x9A4, 0, 0x14, pos, 1, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x1A4, 0, 0xB, x, 1, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x9A4, 0, 0x14, x, 1, 0xFu);
|
||||
}
|
||||
FillBgTilemapBufferRect(0, 0x1A5, pos, 0xC, 1, 8, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x1A6, pos, 0xB, 1, 1, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x1A7, pos, 0x14, 1, 1, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x1A5, x, 0xC, 1, 8, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x1A6, x, 0xB, 1, 1, 0xFu);
|
||||
FillBgTilemapBufferRect(0, 0x1A7, x, 0x14, 1, 1, 0xFu);
|
||||
ScheduleBgCopyTilemapToVram(0);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user