mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2025-01-14 07:33:44 +01:00
Fix build
This commit is contained in:
parent
6bb1d58a11
commit
bb5da949f2
@ -38,7 +38,7 @@ CPPFLAGS := -I ../../tools/agbcc/include -I ../../tools/agbcc -iquote include -n
|
|||||||
ROM := payload.gba
|
ROM := payload.gba
|
||||||
OBJ_DIR := build
|
OBJ_DIR := build
|
||||||
CC1 := ../../tools/agbcc/bin/agbcc$(EXE)
|
CC1 := ../../tools/agbcc/bin/agbcc$(EXE)
|
||||||
override CC1FLAGS += -mthumb-interwork -Wimplicit -Wparentheses -Werror -O2 -fhex-asm -nostdlib
|
override CC1FLAGS += -mthumb-interwork -Wimplicit -Wparentheses -Werror -O2 -fhex-asm
|
||||||
|
|
||||||
|
|
||||||
ELF = $(ROM:.gba=.elf)
|
ELF = $(ROM:.gba=.elf)
|
||||||
|
@ -296,7 +296,7 @@ u8 HandleWriteSectorNBytes(u8 sectorNum, u8 *data, u16 size)
|
|||||||
|
|
||||||
u8 TryWriteSector(u8 sectorNum, u8 *data)
|
u8 TryWriteSector(u8 sectorNum, u8 *data)
|
||||||
{
|
{
|
||||||
if (ProgramFlashSectorAndVerify(sectorNum, data) != 0) // is damaged?
|
if (ProgramFlashSectorAndVerify(sectorNum, data)) // is damaged?
|
||||||
{
|
{
|
||||||
SetSectorDamagedStatus(SECTOR_DAMAGED, sectorNum); // set damaged sector bits.
|
SetSectorDamagedStatus(SECTOR_DAMAGED, sectorNum); // set damaged sector bits.
|
||||||
return SAVE_STATUS_ERROR;
|
return SAVE_STATUS_ERROR;
|
||||||
|
@ -2686,8 +2686,7 @@ static void sub_80398BC(struct Sprite *sprite) // unused?
|
|||||||
|
|
||||||
static void sub_80398D0(struct Sprite *sprite)
|
static void sub_80398D0(struct Sprite *sprite)
|
||||||
{
|
{
|
||||||
sprite->data[4]--;
|
if (--sprite->data[4] == 0)
|
||||||
if (sprite->data[4] == 0)
|
|
||||||
{
|
{
|
||||||
sprite->data[4] = 8;
|
sprite->data[4] = 8;
|
||||||
sprite->invisible ^= 1;
|
sprite->invisible ^= 1;
|
||||||
@ -3418,17 +3417,13 @@ static void BattleIntroDrawTrainersOrMonsSprites(void)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gBattleTypeFlags & BATTLE_TYPE_MULTI)
|
if ((gBattleTypeFlags & BATTLE_TYPE_MULTI) && (GetBattlerPosition(gActiveBattler) == B_POSITION_PLAYER_RIGHT || GetBattlerPosition(gActiveBattler) == B_POSITION_OPPONENT_RIGHT))
|
||||||
{
|
{
|
||||||
if (GetBattlerPosition(gActiveBattler) == B_POSITION_PLAYER_RIGHT
|
BtlController_EmitDrawTrainerPic(0);
|
||||||
|| GetBattlerPosition(gActiveBattler) == B_POSITION_OPPONENT_RIGHT)
|
MarkBattlerForControllerExec(gActiveBattler);
|
||||||
{
|
|
||||||
BtlController_EmitDrawTrainerPic(0);
|
|
||||||
MarkBattlerForControllerExec(gActiveBattler);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (gBattleTypeFlags & BATTLE_TYPE_TWO_OPPONENTS && GetBattlerPosition(gActiveBattler) == B_POSITION_OPPONENT_RIGHT)
|
if ((gBattleTypeFlags & BATTLE_TYPE_TWO_OPPONENTS) && (GetBattlerPosition(gActiveBattler) == B_POSITION_OPPONENT_RIGHT))
|
||||||
{
|
{
|
||||||
BtlController_EmitDrawTrainerPic(0);
|
BtlController_EmitDrawTrainerPic(0);
|
||||||
MarkBattlerForControllerExec(gActiveBattler);
|
MarkBattlerForControllerExec(gActiveBattler);
|
||||||
@ -3961,11 +3956,7 @@ u8 IsRunningFromBattleImpossible(void)
|
|||||||
|
|
||||||
gPotentialItemEffectBattler = gActiveBattler;
|
gPotentialItemEffectBattler = gActiveBattler;
|
||||||
|
|
||||||
if (holdEffect == HOLD_EFFECT_CAN_ALWAYS_RUN)
|
if ((holdEffect == HOLD_EFFECT_CAN_ALWAYS_RUN) || (gBattleTypeFlags & BATTLE_TYPE_LINK) || (gBattleMons[gActiveBattler].ability == ABILITY_RUN_AWAY))
|
||||||
return 0;
|
|
||||||
if (gBattleTypeFlags & BATTLE_TYPE_LINK)
|
|
||||||
return 0;
|
|
||||||
if (gBattleMons[gActiveBattler].ability == ABILITY_RUN_AWAY)
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
||||||
side = GetBattlerSide(gActiveBattler);
|
side = GetBattlerSide(gActiveBattler);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user