summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDiegoisawesome <Diegoisawesome@users.noreply.github.com>2018-12-02 14:05:35 -0600
committerGitHub <noreply@github.com>2018-12-02 14:05:35 -0600
commit2912ec0e37360ede1bae882f0ea2457ec336f16f (patch)
tree7a2b5d14e654e6f8171548692dc5f241de8cb748 /include
parentc123b8d6f1787abce2d1e3920d40192811b5fa39 (diff)
parent9828e0e97b8403a7614f4bec127af9233ae923cb (diff)
Merge pull request #420 from DizzyEggg/bored
Get rid of static functions in includ and add req macro arguments
Diffstat (limited to 'include')
-rw-r--r--include/event_object_movement.h25
-rw-r--r--include/overworld.h7
-rw-r--r--include/string_util.h1
3 files changed, 2 insertions, 31 deletions
diff --git a/include/event_object_movement.h b/include/event_object_movement.h
index 6515791c3..cc45f1531 100644
--- a/include/event_object_movement.h
+++ b/include/event_object_movement.h
@@ -19,7 +19,8 @@ enum SpinnerRunnerFollowPatterns
RUNFOLLOW_SOUTH_EAST_WEST
};
-struct UnkStruct_085094AC {
+struct UnkStruct_085094AC
+{
const union AnimCmd *const *anims;
u8 animPos[4];
};
@@ -45,28 +46,6 @@ struct UnkStruct_085094AC {
#define GROUND_EFFECT_FLAG_HOT_SPRINGS (1 << 18)
#define GROUND_EFFECT_FLAG_SEAWEED (1 << 19)
-#define movement_type_def(setup, table) \
-static u8 setup##_callback(struct EventObject *, struct Sprite *);\
-void setup(struct Sprite *sprite)\
-{\
- UpdateEventObjectCurrentMovement(&gEventObjects[sprite->data[0]], sprite, setup##_callback);\
-}\
-static u8 setup##_callback(struct EventObject *eventObject, struct Sprite *sprite)\
-{\
- return table[sprite->data[1]](eventObject, sprite);\
-}
-
-#define movement_type_empty_callback(setup) \
-static u8 setup##_callback(struct EventObject *, struct Sprite *);\
-void setup(struct Sprite *sprite)\
-{\
- UpdateEventObjectCurrentMovement(&gEventObjects[sprite->data[0]], sprite, setup##_callback);\
-}\
-static u8 setup##_callback(struct EventObject *eventObject, struct Sprite *sprite)\
-{\
- return 0;\
-}
-
struct PairedPalettes
{
u16 tag;
diff --git a/include/overworld.h b/include/overworld.h
index 6f7801905..60d9d5133 100644
--- a/include/overworld.h
+++ b/include/overworld.h
@@ -47,13 +47,8 @@ void Overworld_SetEventObjTemplateMovementType(u8 localId, u8 movementType);
const struct MapLayout *GetMapLayout(void);
void ApplyCurrentWarp(void);
void set_warp2_warp3_to_neg_1(void);
-static void SetWarpData(struct WarpData *warp, s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
-static bool32 IsDummyWarp(struct WarpData *warp);
struct MapHeader const *const Overworld_GetMapHeaderByGroupAndId(u16 mapGroup, u16 mapNum);
struct MapHeader const *const GetDestinationWarpMapHeader(void);
-static void LoadCurrentMapData(void);
-static void LoadSaveblockMapHeader(void);
-static void SetPlayerCoordsFromWarp(void);
void WarpIntoMap(void);
void Overworld_SetWarpDestination(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
void warp1_set_2(s8 mapGroup, s8 mapNum, s8 warpId);
@@ -67,7 +62,6 @@ void sub_8084D5C(s16 a1, s16 a2);
void sub_8084DD4(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
void sub_8084E14(void);
void SetFixedDiveWarp(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
-static void SetFixedDiveWarpAsDestination(void);
void SetFixedHoleWarp(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
void SetFixedHoleWarpAsDestination(s16 x, s16 y);
void warp1_set_to_sav1w(void);
@@ -75,7 +69,6 @@ void sub_8084F2C(s8 mapGroup, s8 mapNum, s8 warpId, s8 x, s8 y);
void sub_8084F6C(u8 a1);
void sub_8084FAC(int unused);
const struct MapConnection *GetMapConnection(u8 dir);
-static bool8 SetDiveWarp(u8 dir, u16 x, u16 y);
bool8 SetDiveWarpEmerge(u16 x, u16 y);
bool8 SetDiveWarpDive(u16 x, u16 y);
void mliX_load_map(u8 mapGroup, u8 mapNum);
diff --git a/include/string_util.h b/include/string_util.h
index 67149bca0..d7a005ec5 100644
--- a/include/string_util.h
+++ b/include/string_util.h
@@ -39,7 +39,6 @@ u8 *WriteColorChangeControlCode(u8 *dest, u32 colorType, u8 color);
bool32 IsStringJapanese(u8 *str);
bool32 sub_800924C(u8 *str, s32 n);
u8 GetExtCtrlCodeLength(u8 code);
-static const u8 *SkipExtCtrlCode(const u8 *s);
s32 StringCompareWithoutExtCtrlCodes(const u8 *str1, const u8 *str2);
void ConvertInternationalString(u8 *s, u8 language);
void StripExtCtrlCodes(u8 *str);