diff options
author | DizzyEggg <jajkodizzy@wp.pl> | 2017-11-17 19:34:55 +0100 |
---|---|---|
committer | DizzyEggg <jajkodizzy@wp.pl> | 2017-11-17 19:34:55 +0100 |
commit | d0245cf8d23aa65a357977a00b21f58d42dfcf6e (patch) | |
tree | cb5e1c81baaf882f2bb8f323b04a7b41d316be7b /src/safari_zone.c | |
parent | 3e1f3d0e1e2bc5fbe5e630d81b741b653080e77b (diff) | |
parent | a98c6bf210cec0591badb51be1e472c5fb4f1f1a (diff) |
recorded battle merge conflicts fix
Diffstat (limited to 'src/safari_zone.c')
-rw-r--r-- | src/safari_zone.c | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/src/safari_zone.c b/src/safari_zone.c index 77c6bbd61..d3d40af28 100644 --- a/src/safari_zone.c +++ b/src/safari_zone.c @@ -20,10 +20,10 @@ struct PokeblockFeeder extern u8 gBattleOutcome; extern void* gFieldCallback; -extern u8 gUnknown_082A4B8A[]; -extern u8 gUnknown_082A4B6F[]; -extern u8 gUnknown_082A4B4C[]; -extern u8 gUnknown_082A4B9B[]; +extern u8 EventScript_2A4B8A[]; +extern u8 EventScript_2A4B6F[]; +extern u8 EventScript_2A4B4C[]; +extern u8 EventScript_2A4B9B[]; extern const u8* const gPokeblockNames[]; extern void sub_80EE44C(u8, u8); @@ -50,17 +50,17 @@ static void DecrementFeederStepCounters(void); bool32 GetSafariZoneFlag(void) { - return FlagGet(SYS_SAFARI_MODE); + return FlagGet(FLAG_SYS_SAFARI_MODE); } void SetSafariZoneFlag(void) { - FlagSet(SYS_SAFARI_MODE); + FlagSet(FLAG_SYS_SAFARI_MODE); } void ResetSafariZoneFlag(void) { - FlagClear(SYS_SAFARI_MODE); + FlagClear(FLAG_SYS_SAFARI_MODE); } void EnterSafariMode(void) @@ -94,7 +94,7 @@ bool8 SafariZoneTakeStep(void) sSafariZoneStepCounter--; if (sSafariZoneStepCounter == 0) { - ScriptContext1_SetupScript(gUnknown_082A4B8A); + ScriptContext1_SetupScript(EventScript_2A4B8A); return TRUE; } return FALSE; @@ -102,7 +102,7 @@ bool8 SafariZoneTakeStep(void) void SafariZoneRetirePrompt(void) { - ScriptContext1_SetupScript(gUnknown_082A4B6F); + ScriptContext1_SetupScript(EventScript_2A4B6F); } void sub_80FC190(void) @@ -116,14 +116,14 @@ void sub_80FC190(void) } else if (gBattleOutcome == BATTLE_SAFARI_OUT_OF_BALLS) { - ScriptContext2_RunNewScript(gUnknown_082A4B4C); + ScriptContext2_RunNewScript(EventScript_2A4B4C); warp_in(); gFieldCallback = sub_80AF6F0; SetMainCallback2(c2_load_new_map); } else if (gBattleOutcome == BATTLE_CAUGHT) { - ScriptContext1_SetupScript(gUnknown_082A4B9B); + ScriptContext1_SetupScript(EventScript_2A4B9B); ScriptContext1_Stop(); SetMainCallback2(c2_exit_to_overworld_1_continue_scripts_restart_music); } @@ -152,13 +152,13 @@ void GetPokeblockFeederInFront(void) && sPokeblockFeeders[i].x == x && sPokeblockFeeders[i].y == y) { - gScriptResult = i; + gSpecialVar_Result = i; StringCopy(gStringVar1, gPokeblockNames[sPokeblockFeeders[i].pokeblock.color]); return; } } - gScriptResult = -1; + gSpecialVar_Result = -1; } void GetPokeblockFeederWithinRange(void) @@ -181,13 +181,13 @@ void GetPokeblockFeederWithinRange(void) y *= -1; if ((x + y) <= 5) { - gScriptResult = i; + gSpecialVar_Result = i; return; } } } - gScriptResult = -1; + gSpecialVar_Result = -1; } // unused @@ -195,20 +195,20 @@ struct Pokeblock *SafariZoneGetPokeblockInFront(void) { GetPokeblockFeederInFront(); - if (gScriptResult == 0xFFFF) + if (gSpecialVar_Result == 0xFFFF) return NULL; else - return &sPokeblockFeeders[gScriptResult].pokeblock; + return &sPokeblockFeeders[gSpecialVar_Result].pokeblock; } struct Pokeblock *SafariZoneGetActivePokeblock(void) { GetPokeblockFeederWithinRange(); - if (gScriptResult == 0xFFFF) + if (gSpecialVar_Result == 0xFFFF) return NULL; else - return &sPokeblockFeeders[gScriptResult].pokeblock; + return &sPokeblockFeeders[gSpecialVar_Result].pokeblock; } void SafariZoneActivatePokeblockFeeder(u8 pkblId) @@ -255,13 +255,13 @@ bool8 GetInFrontFeederPokeblockAndSteps(void) { GetPokeblockFeederInFront(); - if (gScriptResult == 0xFFFF) + if (gSpecialVar_Result == 0xFFFF) { return FALSE; } ConvertIntToDecimalStringN(gStringVar2, - sPokeblockFeeders[gScriptResult].stepCounter, + sPokeblockFeeders[gSpecialVar_Result].stepCounter, STR_CONV_MODE_LEADING_ZEROS, 3); return TRUE; |