summaryrefslogtreecommitdiff
path: root/src/object
diff options
context:
space:
mode:
authortheo3 <arisstephenson2@gmail.com>2021-12-20 02:02:33 -0800
committertheo3 <arisstephenson2@gmail.com>2021-12-20 10:31:02 -0800
commit6cff332e57b5cc723d9243c2d4667be7c7ca0273 (patch)
treeabfb5dfbbf116cef3f6776df3e242fe37ee0fc8e /src/object
parent0d5eae8696a70323c0712233913d73ee67823ca4 (diff)
header overhaul
Diffstat (limited to 'src/object')
-rw-r--r--src/object/archway.c2
-rw-r--r--src/object/backgroundCloud.c4
-rw-r--r--src/object/bakerOven.c3
-rw-r--r--src/object/bell.c3
-rw-r--r--src/object/bird.c6
-rw-r--r--src/object/book.c6
-rw-r--r--src/object/button.c7
-rw-r--r--src/object/cloud.c7
-rw-r--r--src/object/fileScreenObjects.c6
-rw-r--r--src/object/fireplace.c7
-rw-r--r--src/object/floatingBlock.c3
-rw-r--r--src/object/frozenFlower.c3
-rw-r--r--src/object/giantLeaf.c5
-rw-r--r--src/object/greatFairy.c33
-rw-r--r--src/object/houseDoorExterior.c1
-rw-r--r--src/object/jarPortal.c7
-rw-r--r--src/object/lightableSwitch.c1
-rw-r--r--src/object/lilypadSmall.c9
-rw-r--r--src/object/lockedDoor.c2
-rw-r--r--src/object/mask.c8
-rw-r--r--src/object/minecart.c5
-rw-r--r--src/object/minishSizedArchway.c2
-rw-r--r--src/object/minishSizedEntrance.c6
-rw-r--r--src/object/object1A.c3
-rw-r--r--src/object/object2A.c1
-rw-r--r--src/object/object49.c5
-rw-r--r--src/object/object86.c6
-rw-r--r--src/object/objectA.c1
-rw-r--r--src/object/objectA2.c4
-rw-r--r--src/object/octorokBossObject.c6
-rw-r--r--src/object/palaceArchway.c5
-rw-r--r--src/object/pot.c1
-rw-r--r--src/object/railtrack.c1
-rw-r--r--src/object/smoke.c4
-rw-r--r--src/object/thoughtBubble.c1
-rw-r--r--src/object/treeThorns.c1
-rw-r--r--src/object/warpPoint.c5
-rw-r--r--src/object/windTribeFlag.c4
38 files changed, 61 insertions, 123 deletions
diff --git a/src/object/archway.c b/src/object/archway.c
index 823fa485..d0ed7559 100644
--- a/src/object/archway.c
+++ b/src/object/archway.c
@@ -1,6 +1,6 @@
#include "global.h"
#include "entity.h"
-#include "game.h"
+#include "overworld.h"
void Archway(Entity* this) {
if (this->action == 0) {
diff --git a/src/object/backgroundCloud.c b/src/object/backgroundCloud.c
index 2ab9051a..edd764d2 100644
--- a/src/object/backgroundCloud.c
+++ b/src/object/backgroundCloud.c
@@ -1,6 +1,4 @@
-#include "global.h"
-#include "entity.h"
-#include "random.h"
+#include "object.h"
#include "functions.h"
extern void (*const gUnk_08121EA4[])(Entity*);
diff --git a/src/object/bakerOven.c b/src/object/bakerOven.c
index b1c3a1db..ffe11cd9 100644
--- a/src/object/bakerOven.c
+++ b/src/object/bakerOven.c
@@ -1,7 +1,4 @@
-#include "global.h"
-#include "entity.h"
#include "object.h"
-#include "functions.h"
extern void sub_0800449C(Entity*, u32);
extern u32 sub_0806FC80(Entity*, Entity*, s32);
diff --git a/src/object/bell.c b/src/object/bell.c
index a3e7ce3c..135584c3 100644
--- a/src/object/bell.c
+++ b/src/object/bell.c
@@ -1,5 +1,4 @@
-#include "global.h"
-#include "entity.h"
+#include "object.h"
extern void (*gUnk_08123384[])(Entity*);
diff --git a/src/object/bird.c b/src/object/bird.c
index 3045fecb..b7774df4 100644
--- a/src/object/bird.c
+++ b/src/object/bird.c
@@ -1,12 +1,6 @@
-#include "global.h"
-#include "audio.h"
-#include "entity.h"
-#include "flags.h"
#include "save.h"
-#include "random.h"
#include "object.h"
#include "functions.h"
-#include "effects.h"
extern void (*const gUnk_08123EC0[])(Entity*);
extern void (*const gUnk_08123EEC[])(Entity*);
diff --git a/src/object/book.c b/src/object/book.c
index 3430e4ef..9a99b928 100644
--- a/src/object/book.c
+++ b/src/object/book.c
@@ -1,11 +1,7 @@
-#include "entity.h"
+#include "object.h"
#include "functions.h"
-#include "player.h"
#include "script.h"
-#include "flags.h"
-#include "room.h"
#include "textbox.h"
-#include "effects.h"
extern void (*const BookActionFuncs[])(Entity*);
extern s8 const gUnk_08123D94[];
diff --git a/src/object/button.c b/src/object/button.c
index 4c026baf..76b48da8 100644
--- a/src/object/button.c
+++ b/src/object/button.c
@@ -1,10 +1,5 @@
-#include "global.h"
-#include "entity.h"
-#include "flags.h"
-#include "room.h"
-#include "audio.h"
+#include "object.h"
#include "functions.h"
-#include "effects.h"
extern void (*const gUnk_0811EE38[])(Entity*);
diff --git a/src/object/cloud.c b/src/object/cloud.c
index d8915514..22494391 100644
--- a/src/object/cloud.c
+++ b/src/object/cloud.c
@@ -1,10 +1,3 @@
-#include "global.h"
-#include "audio.h"
-#include "entity.h"
-#include "room.h"
-#include "player.h"
-#include "flags.h"
-#include "random.h"
#include "object.h"
#include "structures.h"
#include "functions.h"
diff --git a/src/object/fileScreenObjects.c b/src/object/fileScreenObjects.c
index 549e2600..345e8a2b 100644
--- a/src/object/fileScreenObjects.c
+++ b/src/object/fileScreenObjects.c
@@ -1,12 +1,8 @@
-#include "global.h"
-#include "entity.h"
-#include "flags.h"
+#include "object.h"
#include "main.h"
#include "menu.h"
#include "npc.h"
-#include "coord.h"
#include "fileScreen.h"
-#include "utils.h"
#include "structures.h"
#include "functions.h"
diff --git a/src/object/fireplace.c b/src/object/fireplace.c
index fe2dc0d6..1fda4e9f 100644
--- a/src/object/fireplace.c
+++ b/src/object/fireplace.c
@@ -1,9 +1,6 @@
-#include "entity.h"
-#include "functions.h"
-#include "player.h"
+#include "object.h"
#include "script.h"
-#include "flags.h"
-#include "room.h"
+#include "functions.h"
extern void (*gUnk_08123D98[])(Entity*);
diff --git a/src/object/floatingBlock.c b/src/object/floatingBlock.c
index 7e1ad599..c7024c9b 100644
--- a/src/object/floatingBlock.c
+++ b/src/object/floatingBlock.c
@@ -1,5 +1,4 @@
-#include "global.h"
-#include "entity.h"
+#include "object.h"
void FloatingBlock(Entity* this) {
if (this->action == 0) {
diff --git a/src/object/frozenFlower.c b/src/object/frozenFlower.c
index 92118c4e..e576218b 100644
--- a/src/object/frozenFlower.c
+++ b/src/object/frozenFlower.c
@@ -1,5 +1,4 @@
-#include "global.h"
-#include "entity.h"
+#include "object.h"
extern void (*const gUnk_0812119C[])(Entity*);
diff --git a/src/object/giantLeaf.c b/src/object/giantLeaf.c
index a61b267a..a5d25b30 100644
--- a/src/object/giantLeaf.c
+++ b/src/object/giantLeaf.c
@@ -1,7 +1,4 @@
-#include "global.h"
-#include "entity.h"
-#include "room.h"
-#include "functions.h"
+#include "object.h"
void sub_0808D618(Entity* ent);
diff --git a/src/object/greatFairy.c b/src/object/greatFairy.c
index e5575a47..db393026 100644
--- a/src/object/greatFairy.c
+++ b/src/object/greatFairy.c
@@ -1,16 +1,31 @@
-#include "global.h"
-#include "audio.h"
-#include "entity.h"
-#include "room.h"
-#include "screen.h"
-#include "greatFairy.h"
-#include "flags.h"
+#include "object.h"
#include "save.h"
-#include "random.h"
#include "script.h"
-#include "object.h"
#include "structures.h"
#include "functions.h"
+#include "screen.h"
+
+void GreatFairy_InitializeAnimation(Entity*);
+Entity* GreatFairy_CreateForm(Entity*, u32, u32);
+void sub_080873D0();
+extern void (*const GreatFairy_Main[])(Entity*);
+extern void (*const GreatFairy_Behaviors[])(Entity*);
+extern void (*const GreatFairy_WingsBehaviors[])(Entity*);
+extern void (*const GreatFairy_WakeBehaviors[])(Entity*);
+extern void (*const GreatFairy_MiniBehaviors[])(Entity*);
+extern void (*const GreatFairy_MiniAffineBehaviors[])(Entity*);
+extern void (*const GreatFairy_DropletBehaviors[])(Entity*);
+extern void (*const GreatFairy_RippleBehaviors[])(Entity*);
+extern void (*const GreatFairy_BigRippleBehaviors[])(Entity*);
+extern void (*const GreatFairy_EnergyBehaviors[])(Entity*);
+extern void (*const GreatFairy_Form1Behaviors[])(Entity*);
+extern void (*const GreatFairy_Form2Behaviors[])(Entity*);
+extern void (*const gUnk_081207A4[])(Entity*);
+
+extern u32 gUnk_0810C2E4;
+extern const s16 GreatFairy_RippleOffsets[10];
+extern u8 gUnk_0812079C[8];
+extern s8 gUnk_081207AC[];
enum {
BEHAVIORS,
diff --git a/src/object/houseDoorExterior.c b/src/object/houseDoorExterior.c
index b9747788..79b8425c 100644
--- a/src/object/houseDoorExterior.c
+++ b/src/object/houseDoorExterior.c
@@ -6,6 +6,7 @@
#include "audio.h"
#include "object.h"
#include "functions.h"
+#include "npc.h"
typedef struct {
/*0x00*/ u16 unk0;
diff --git a/src/object/jarPortal.c b/src/object/jarPortal.c
index b5eddce6..d84c12b6 100644
--- a/src/object/jarPortal.c
+++ b/src/object/jarPortal.c
@@ -1,9 +1,6 @@
-#include "global.h"
-#include "entity.h"
-#include "flags.h"
-#include "functions.h"
+#include "object.h"
#include "area.h"
-#include "audio.h"
+#include "functions.h"
extern void (*gUnk_08121488[])(Entity*);
diff --git a/src/object/lightableSwitch.c b/src/object/lightableSwitch.c
index 3bcb95a1..54716b5e 100644
--- a/src/object/lightableSwitch.c
+++ b/src/object/lightableSwitch.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "audio.h"
#include "entity.h"
#include "room.h"
#include "flags.h"
diff --git a/src/object/lilypadSmall.c b/src/object/lilypadSmall.c
index ae74c9c8..31c5c3a8 100644
--- a/src/object/lilypadSmall.c
+++ b/src/object/lilypadSmall.c
@@ -1,13 +1,12 @@
-#include "global.h"
-#include "entity.h"
-#include "player.h"
-#include "random.h"
+#include "object.h"
#include "functions.h"
extern void sub_080A2CC0(Entity*, Entity**, u16*);
extern u16 gUnk_08123318[];
+static void sub_08097B24(Entity* this);
+
void LilypadSmall(Entity* this) {
u32 rand;
u16* psVar4;
@@ -48,7 +47,7 @@ u32 sub_08097ADC(Entity* this) {
}
}
-void sub_08097B24(Entity* this) {
+static void sub_08097B24(Entity* this) {
u32 temp;
u32 temp2;
u16* temp3;
diff --git a/src/object/lockedDoor.c b/src/object/lockedDoor.c
index f81f63b7..fccc8b5f 100644
--- a/src/object/lockedDoor.c
+++ b/src/object/lockedDoor.c
@@ -1,10 +1,10 @@
#include "global.h"
#include "entity.h"
#include "flags.h"
-#include "game.h"
#include "audio.h"
#include "functions.h"
#include "effects.h"
+#include "overworld.h"
void sub_08083338(Entity*);
void sub_080834B4(Entity*);
diff --git a/src/object/mask.c b/src/object/mask.c
index 837614bd..854cd5c2 100644
--- a/src/object/mask.c
+++ b/src/object/mask.c
@@ -1,12 +1,6 @@
-#include "global.h"
-#include "entity.h"
-#include "room.h"
-#include "random.h"
+#include "object.h"
#include "structures.h"
-#include "player.h"
-#include "flags.h"
#include "functions.h"
-#include "effects.h"
extern void (*MaskActionFuncs[])(Entity*);
diff --git a/src/object/minecart.c b/src/object/minecart.c
index fe333927..8f5e9360 100644
--- a/src/object/minecart.c
+++ b/src/object/minecart.c
@@ -1,8 +1,5 @@
-#include "global.h"
-#include "audio.h"
-#include "entity.h"
+#include "object.h"
#include "functions.h"
-#include "room.h"
extern u32 sub_08091DDC(Entity*);
extern u32 sub_080002B4(Entity*, u32, u32);
diff --git a/src/object/minishSizedArchway.c b/src/object/minishSizedArchway.c
index 240fdf95..ad001c83 100644
--- a/src/object/minishSizedArchway.c
+++ b/src/object/minishSizedArchway.c
@@ -1,6 +1,6 @@
#include "global.h"
#include "entity.h"
-#include "game.h"
+#include "overworld.h"
void MinishSizedArchway(Entity* this) {
if (this->action == 0) {
diff --git a/src/object/minishSizedEntrance.c b/src/object/minishSizedEntrance.c
index 9338bca5..a92a887c 100644
--- a/src/object/minishSizedEntrance.c
+++ b/src/object/minishSizedEntrance.c
@@ -1,7 +1,5 @@
-#include "global.h"
-#include "entity.h"
-#include "game.h"
-#include "player.h"
+#include "object.h"
+#include "overworld.h"
#include "functions.h"
extern void (*const gUnk_08122254[])(Entity*);
diff --git a/src/object/object1A.c b/src/object/object1A.c
index 7f76d0f7..bdc3fe49 100644
--- a/src/object/object1A.c
+++ b/src/object/object1A.c
@@ -1,6 +1,3 @@
-#include "global.h"
-#include "entity.h"
-#include "random.h"
#include "object.h"
#include "functions.h"
diff --git a/src/object/object2A.c b/src/object/object2A.c
index edc742c0..9e36b439 100644
--- a/src/object/object2A.c
+++ b/src/object/object2A.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "audio.h"
#include "entity.h"
#include "functions.h"
#include "flags.h"
diff --git a/src/object/object49.c b/src/object/object49.c
index 5a02a82c..125c6440 100644
--- a/src/object/object49.c
+++ b/src/object/object49.c
@@ -1,8 +1,3 @@
-#include "global.h"
-#include "audio.h"
-#include "entity.h"
-#include "coord.h"
-#include "random.h"
#include "object.h"
#include "structures.h"
#include "functions.h"
diff --git a/src/object/object86.c b/src/object/object86.c
index 147e623c..b5c9e60b 100644
--- a/src/object/object86.c
+++ b/src/object/object86.c
@@ -1,8 +1,4 @@
-#include "global.h"
-#include "entity.h"
-#include "coord.h"
-#include "player.h"
-#include "flags.h"
+#include "object.h"
#include "functions.h"
void sub_08099ECC(Entity*);
diff --git a/src/object/objectA.c b/src/object/objectA.c
index 9335bdc5..c7d885e7 100644
--- a/src/object/objectA.c
+++ b/src/object/objectA.c
@@ -4,6 +4,7 @@
#include "flags.h"
#include "createObject.h"
#include "functions.h"
+#include "overworld.h"
extern Hitbox gHitbox_2;
diff --git a/src/object/objectA2.c b/src/object/objectA2.c
index 8d751592..c3ad215b 100644
--- a/src/object/objectA2.c
+++ b/src/object/objectA2.c
@@ -1,11 +1,7 @@
-#include "global.h"
#include "object.h"
#include "menu.h"
-#include "random.h"
-#include "audio.h"
#include "structures.h"
#include "functions.h"
-#include "effects.h"
void sub_0809F318(Entity*);
void sub_0809F374(Entity*);
diff --git a/src/object/octorokBossObject.c b/src/object/octorokBossObject.c
index b1df61ee..6e69a7db 100644
--- a/src/object/octorokBossObject.c
+++ b/src/object/octorokBossObject.c
@@ -1,10 +1,6 @@
-#include "global.h"
-#include "entity.h"
-#include "coord.h"
-#include "audio.h"
#include "functions.h"
-#include "random.h"
#include "object.h"
+#include "overworld.h"
extern void sub_0807B9B8(s32, s32, s32);
diff --git a/src/object/palaceArchway.c b/src/object/palaceArchway.c
index cec05cbe..13e6d3bb 100644
--- a/src/object/palaceArchway.c
+++ b/src/object/palaceArchway.c
@@ -1,7 +1,4 @@
-#include "global.h"
-#include "entity.h"
-#include "room.h"
-#include "functions.h"
+#include "object.h"
extern void (*const gUnk_081246EC[])(Entity*);
diff --git a/src/object/pot.c b/src/object/pot.c
index 110c1eb8..dd645021 100644
--- a/src/object/pot.c
+++ b/src/object/pot.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "audio.h"
#include "entity.h"
#include "flags.h"
#include "player.h"
diff --git a/src/object/railtrack.c b/src/object/railtrack.c
index 00fbb4ec..223a5603 100644
--- a/src/object/railtrack.c
+++ b/src/object/railtrack.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "audio.h"
#include "entity.h"
#include "room.h"
#include "flags.h"
diff --git a/src/object/smoke.c b/src/object/smoke.c
index 17ec7ad0..d603ea1c 100644
--- a/src/object/smoke.c
+++ b/src/object/smoke.c
@@ -1,8 +1,4 @@
-#include "global.h"
-#include "entity.h"
-#include "random.h"
#include "object.h"
-#include "functions.h"
extern void (*const gUnk_08121060[])(Entity*);
extern void (*const gUnk_08121070[])(Entity*);
diff --git a/src/object/thoughtBubble.c b/src/object/thoughtBubble.c
index 1789195b..e90cfbd7 100644
--- a/src/object/thoughtBubble.c
+++ b/src/object/thoughtBubble.c
@@ -1,7 +1,6 @@
#include "global.h"
#include "entity.h"
#include "audio.h"
-#include "functions.h"
extern void (*const ThoughtBubble_Behaviors[])(Entity*);
diff --git a/src/object/treeThorns.c b/src/object/treeThorns.c
index 5a52b9a5..8cd2a06f 100644
--- a/src/object/treeThorns.c
+++ b/src/object/treeThorns.c
@@ -3,7 +3,6 @@
#include "coord.h"
#include "room.h"
#include "object.h"
-#include "functions.h"
extern Hitbox gHitbox_1;
diff --git a/src/object/warpPoint.c b/src/object/warpPoint.c
index 58b2722b..b238e897 100644
--- a/src/object/warpPoint.c
+++ b/src/object/warpPoint.c
@@ -2,12 +2,15 @@
#include "object.h"
#include "player.h"
#include "flags.h"
-#include "game.h"
+#include "overworld.h"
#include "audio.h"
#include "functions.h"
extern Hitbox gHitbox_1;
+extern void sub_0807CAC8(u32);
+extern u32 sub_0807CAEC(u32);
+
void WarpPoint(Entity*);
void sub_0808B474(Entity*);
void sub_0808B530(Entity*);
diff --git a/src/object/windTribeFlag.c b/src/object/windTribeFlag.c
index 1fcfea7d..b8943a58 100644
--- a/src/object/windTribeFlag.c
+++ b/src/object/windTribeFlag.c
@@ -1,6 +1,4 @@
-#include "global.h"
-#include "entity.h"
-#include "random.h"
+#include "object.h"
void WindTribeFlag(Entity* this) {
if (this->action == 0) {