Cleanup externs in overworld.c

This commit is contained in:
Marcus Huderle 2019-02-08 11:48:51 -06:00
parent 6add3e1794
commit abebd2b864
18 changed files with 42 additions and 65 deletions

View File

@ -15,5 +15,6 @@ void sub_80B360C(void);
bool32 sub_80B2AF4(u16 *arg0, u16 *arg1);
void sub_80B3AF8(u8 taskId);
void task00_08081A90(u8 taskId);
bool32 sub_80B39D4(u8 linkPlayerIndex);
#endif //GUARD_CABLE_CLUB_H

View File

@ -32,5 +32,6 @@ void SetCameraPanningCallback(void (*a)(void));
void SetCameraPanning(s16 a, s16 b);
void InstallCameraPanAheadCallback(void);
void UpdateCameraPanning(void);
void FieldUpdateBgTilemapScroll(void);
#endif //GUARD_FIELD_CAMERA_H

View File

@ -37,5 +37,7 @@ u8 sub_8068F18(void);
bool8 dive_warp(struct MapPosition *position, u16 b);
int SetCableClubWarp(void);
u8 TrySetDiveWarp(void);
const u8 *GetInteractedLinkPlayerScript(struct MapPosition *position, u8 metatileBehavior, u8 direction);
u8 *GetCoordEventScriptAtMapPosition(struct MapPosition *position);
#endif // GUARD_FIELDCONTROLAVATAR_H

View File

@ -13,6 +13,7 @@ extern bool8 (*gFieldCallback2)(void);
u32 FieldEffectStart(u8);
bool8 FieldEffectActiveListContains(u8 id);
void FieldEffectActiveListClear(void);
void sub_80B69DC(void);
u8 AddNewGameBirchObject(s16, s16, u8);
void FieldEffectStop(struct Sprite *sprite, u8 id);

View File

@ -17,5 +17,6 @@ void HideFieldMessageBox(void);
bool8 IsFieldMessageBoxHidden(void);
u8 GetFieldMessageBoxMode(void);
void sub_8098374(void);
void InitFieldMessageBox(void);
#endif // GUARD_FIELD_MESSAGE_BOX_H

View File

@ -60,5 +60,8 @@ bool8 IsPlayerFacingSurfableFishableWater(void);
bool8 IsPlayerSurfingNorth(void);
void sub_808C228(u8 direction);
u8 sub_808BCD0(void);
void sub_808B578(void);
u8 GetFRLGAvatarGraphicsIdByGender(u8);
u8 GetRSAvatarGraphicsIdByGender(u8);
#endif // GUARD_FIELD_PLAYER_AVATAR_H

View File

@ -40,5 +40,6 @@ void sub_80B0268(void);
void sub_80B0534(void);
void sub_80B058C(void);
void sub_80B05B4(void);
void WriteFlashScanlineEffectBuffer(u8 flashLevel);
#endif // GUARD_FIELD_SCREEN_EFFECT_H

View File

@ -23,5 +23,7 @@ bool8 sub_813B9C0(void);
void SetShoalItemFlag(u16 v0);
void UpdateFrontierManiac(u16 a0);
void UpdateFrontierGambler(u16 a0);
void ResetCyclingRoadChallengeData(void);
bool8 warp0_in_pokecenter(void);
#endif // GUARD_FIELD_SPECIALS_H

View File

@ -233,5 +233,6 @@ void SetSav1WeatherFromCurrMapHeader(void);
void SetWeather(u32 weather);
void DoCurrentWeather(void);
void UpdateWeatherPerDay(u16 increment);
void sub_80AEE84(void);
#endif // GUARD_WEATHER_H

View File

@ -33,6 +33,12 @@ void InitMap(void);
void InitMapFromSavedGame(void);
void InitTrainerHillMap(void);
void InitBattlePyramidMap(bool8 setPlayerPosition);
void copy_map_tileset1_tileset2_to_vram(struct MapLayout const *mapLayout);
void apply_map_tileset1_tileset2_palette(struct MapLayout const *mapLayout);
void apply_map_tileset2_palette(struct MapLayout const *mapLayout);
void copy_map_tileset2_to_vram_2(struct MapLayout const *mapLayout);
extern void copy_map_tileset1_to_vram(const struct MapLayout *);
extern void copy_map_tileset2_to_vram(const struct MapLayout *);
void SpriteCB_PokeballGlow(struct Sprite *);
void SpriteCB_PokecenterMonitor(struct Sprite *);

View File

@ -312,5 +312,7 @@ void sub_800AB18(void);
void sub_8009F18(void);
bool8 sub_800AA60(void);
void sub_800ABF4(u16 a0);
bool32 sub_8009F3C(void);
u32 sub_800B4DC(void);
#endif // GUARD_LINK_H

View File

@ -282,5 +282,6 @@ void sub_800EF7C(void);
bool8 sub_800DE7C(struct UnkLinkRfuStruct_02022B14 *buff1, u8 *buff2, u8 idx);
s32 sub_800E87C(u8 idx);
void sub_8011BA4(void);
void sub_8010198(void);
#endif //GUARD_LINK_RFU_H

View File

@ -11,5 +11,6 @@ enum {
};
s32 GetRematchIdxByTrainerIdx(s32 trainerIdx);
void InitMatchCallCounters(void);
#endif //GUARD_MATCH_CALL_H

View File

@ -22,6 +22,8 @@ void sub_80EB56C(void);
void sub_80EB9E0(void);
void sub_80EBB28(void);
void WarpIntoSecretBase(const struct MapPosition *position, const struct MapEvents *events);
bool8 sub_80E909C(void);
void sub_80EB218(void);
// SetCurrentSecretBaseFromPosition
void sub_80E9608(const struct MapPosition *position, const struct MapEvents *events);

9
include/tileset_anims.h Executable file
View File

@ -0,0 +1,9 @@
#ifndef GUARD_TILESET_ANIMS_H
#define GUARD_TILESET_ANIMS_H
void cur_mapheader_run_tileset_funcs_after_some_cpuset(void);
void sub_80A0A2C(void);
void sub_80A0A38(void);
void TransferTilesetAnimsBuffer(void);
#endif // GUARD_TILESET_ANIMS_H

View File

@ -1956,7 +1956,7 @@ void sub_8139D98(void)
}
}
bool32 warp0_in_pokecenter(void)
bool8 warp0_in_pokecenter(void)
{
static const u16 gUnknown_085B2C2A[] = { 0x0202, 0x0301, 0x0405, 0x0504, 0x0604, 0x0700, 0x0804, 0x090b, 0x0a05, 0x0b05, 0x0c02, 0x0d06, 0x0e03, 0x0f02, 0x100c, 0x100a, 0x1a35, 0x193c, 0xFFFF };

View File

@ -8,6 +8,7 @@
#include "lottery_corner.h"
#include "play_time.h"
#include "mauville_old_man.h"
#include "match_call.h"
#include "lilycove_lady.h"
#include "load_save.h"
#include "pokeblock.h"
@ -47,7 +48,6 @@ extern void NewGameInitPCItems(void);
extern void ClearDecorationInventories(void);
extern void ResetFanClub(void);
extern void copy_strings_to_sav1(void);
extern void InitMatchCallCounters(void);
extern void sub_801AFD8(void);
extern void sub_800E5AC(void);
extern void ResetContestLinkResults(void);

View File

@ -19,6 +19,7 @@
#include "field_tasks.h"
#include "field_weather.h"
#include "fieldmap.h"
#include "fldeff.h"
#include "gpu_regs.h"
#include "heal_location.h"
#include "link.h"
@ -28,6 +29,7 @@
#include "alloc.h"
#include "m4a.h"
#include "map_name_popup.h"
#include "match_call.h"
#include "menu.h"
#include "metatile_behavior.h"
#include "mirage_tower.h"
@ -42,14 +44,15 @@
#include "save.h"
#include "save_location.h"
#include "script.h"
// #include "script_pokemon_80C4.h"
#include "script_pokemon_util_80F87D8.h"
#include "secret_base.h"
#include "sound.h"
#include "start_menu.h"
#include "task.h"
// #include "tileset_anim.h"
#include "tileset_anims.h"
#include "time_events.h"
#include "trainer_hill.h"
#include "trainer_pokemon_sprites.h"
#include "tv.h"
#include "scanline_effect.h"
#include "wild_encounter.h"
@ -85,71 +88,11 @@ extern const u8 gUnknown_082773F5[];
extern const u8 gUnknown_082774EF[];
extern const u8 gUnknown_08277509[];
// vars
extern const struct MapLayout *const gMapLayouts[];
extern const struct MapHeader *const *const gMapGroups[];
extern const s32 gMaxFlashLevel;
extern const int gMaxFlashLevel;
extern const u16 gUnknown_82EC7C4[];
// functions
extern void HealPlayerParty(void);
extern void move_tilemap_camera_to_upper_left_corner(void);
extern void cur_mapheader_run_tileset_funcs_after_some_cpuset(void);
extern void DrawWholeMapView(void);
extern void copy_map_tileset1_tileset2_to_vram(const struct MapLayout *);
extern void apply_map_tileset1_tileset2_palette(const struct MapLayout *);
extern void ResetCyclingRoadChallengeData(void);
extern void ApplyNewEncryptionKeyToWord(u32 *word, u32 newKey);
extern void mapheader_run_script_with_tag_x5(void);
extern void ResetFieldTasksArgs(void);
extern void sub_80A0A2C(void);
extern void apply_map_tileset2_palette(const struct MapLayout *);
extern void copy_map_tileset2_to_vram_2(const struct MapLayout *);
extern void RestartWildEncounterImmunitySteps(void);
extern void ShowMapNamePopup(void);
extern bool32 sub_808651C(void);
extern bool8 sub_80AF6A4(void);
extern bool8 sub_80E909C(void);
extern void c2_change_map(void);
extern void sub_81D5DF8(void);
extern void sub_80EB218(void);
extern void sub_80AF3C8(void);
extern void sub_808B578(void);
extern void sub_80AF314(void);
extern void sub_80AF214(void);
extern void sub_80AF188(void);
extern void RotatingGate_InitPuzzleAndGraphics(void);
extern void sub_80AF168(void);
extern void sub_80AF3C8(void);
extern void ExecuteTruckSequence(void);
extern void sub_80A0A38(void);
extern void WriteFlashScanlineEffectBuffer(u8);
extern void InitMatchCallCounters(void);
extern void sub_80EDB44(void);
extern void InitFieldMessageBox(void);
extern void copy_map_tileset1_to_vram(const struct MapLayout *);
extern void copy_map_tileset2_to_vram(const struct MapLayout *);
extern void FieldUpdateBgTilemapScroll(void);
extern void TransferTilesetAnimsBuffer(void);
extern bool8 warp0_in_pokecenter(void);
extern void ResetAllPicSprites(void);
extern void FieldEffectActiveListClear(void);
extern void SetUpFieldTasks(void);
extern void ShowStartMenu(void);
extern void sub_80AEE84(void);
extern void mapldr_default(void);
extern bool32 sub_800F0B8(void);
extern bool32 sub_8009F3C(void);
extern void sub_8010198(void);
extern u32 sub_800B4DC(void);
extern bool32 sub_80B39D4(u8);
extern const u8* GetInteractedLinkPlayerScript(struct MapPosition *a1, u8, u8);
extern u8 *GetCoordEventScriptAtMapPosition(void*);
extern u8 GetFRLGAvatarGraphicsIdByGender(u8);
extern u8 GetRSAvatarGraphicsIdByGender(u8);
extern void UpdateEventObjectSpriteVisibility(struct Sprite*, u8);
// this file's functions
static void Overworld_ResetStateAfterWhiteOut(void);
static void c2_80567AC(void);
static void CB2_LoadMap2(void);