diff options
Diffstat (limited to 'include/Actor')
| -rw-r--r-- | include/Actor/Actor.hpp | 23 | ||||
| -rw-r--r-- | include/Actor/ActorManager.hpp | 6 | ||||
| -rw-r--r-- | include/Actor/ActorRef.hpp | 7 | ||||
| -rw-r--r-- | include/Actor/ActorRupee.hpp | 4 | ||||
| -rw-r--r-- | include/Actor/ActorType.hpp | 169 |
5 files changed, 102 insertions, 107 deletions
diff --git a/include/Actor/Actor.hpp b/include/Actor/Actor.hpp index 29d4da2a..8f9378d2 100644 --- a/include/Actor/Actor.hpp +++ b/include/Actor/Actor.hpp @@ -49,10 +49,10 @@ struct Actor_UnkStruct_0a4 { Actor_UnkStruct_0a4(q20 x, q20 y, q20 z, s32 unk_10); }; -class KillPickupsFilter: FilterActorReturn, public FilterActorBase { +class KillPickupsFilter : FilterActorReturn, public FilterActorBase { public: /* 00 (base) */ - /* 04 */ + /* 04 */ /* 0 */ virtual bool Filter(Actor *actor) override; /* 4 */ @@ -60,11 +60,11 @@ public: typedef u32 PlayerCollide; enum PlayerCollide_ { - PlayerCollide_Player = 0x1, - PlayerCollide_Sword = 0x2, - PlayerCollide_Shield = 0x4, + PlayerCollide_Player = 0x1, + PlayerCollide_Sword = 0x2, + PlayerCollide_Shield = 0x4, PlayerCollide_Gongoron = 0x8, - PlayerCollide_Hammer = 0x10, + PlayerCollide_Hammer = 0x10, }; struct Knockback { @@ -73,11 +73,10 @@ struct Knockback { /* 10 */ unk32 mUnk_10; /* 14 */ Actor *actor; - inline Knockback(): + inline Knockback() : mUnk_00(0), mUnk_10(0xb), - actor(NULL) - {} + actor(NULL) {} }; class Actor : public SysObject { @@ -172,7 +171,7 @@ public: /* 44 */ virtual bool CollidesWith(Actor *other); /* 48 */ virtual bool vfunc_48(Knockback *param1); /* 4c */ virtual bool vfunc_4c(unk32 *param1); - /* 50 */ virtual Vec3p* GetPos(); + /* 50 */ virtual Vec3p *GetPos(); /* 54 */ virtual void vfunc_54(); /* 58 */ virtual bool SetUnk_11b(); /* 5c */ virtual bool SetVelocity(Vec3p *vel); @@ -198,7 +197,7 @@ public: /* ac */ virtual void vfunc_ac(); /* b0 */ virtual void vfunc_b0(); /* b4 */ - + Actor(); bool func_01fffd04(s32 param1); @@ -241,7 +240,7 @@ public: void IncreaseActiveFrames(); bool func_ov00_020c2c0c(); bool func_ov00_020c2c70(); - EquipBoomerang* GetEquipBoomerang(); + EquipBoomerang *GetEquipBoomerang(); bool func_ov00_020c2d54(); bool func_ov00_020c2de4(); bool func_ov00_020c2e7c(); diff --git a/include/Actor/ActorManager.hpp b/include/Actor/ActorManager.hpp index 9222bc6d..8ad14b2d 100644 --- a/include/Actor/ActorManager.hpp +++ b/include/Actor/ActorManager.hpp @@ -80,14 +80,14 @@ public: void DeleteActor(u32 index, bool param2); static void func_ov00_020c3484(ActorRef *ref, Actor *actor, unk32 param3); void Actor_vfunc_10(u32 param1); - Actor* FindActorById(u32 id); - Actor* GetActor(ActorRef *ref); + Actor *FindActorById(u32 id); + Actor *GetActor(ActorRef *ref); s32 FilterActors(FilterActorBase *filter, ActorList *filteredActors); static void FindActorByType(ActorRef *ref, ActorManager *manager, ActorTypeId type); static void FindNearestActorOfType(ActorRef *ref, ActorManager *manager, ActorTypeId type, Vec3p *pos); bool func_ov00_020c398c(u32 index); void func_ov00_020c399c(u32 index, Cylinder *cylinder); - Actor* func_ov00_020c39ac(u32 index, const ActorTypeId *actorTypes, bool param3); + Actor *func_ov00_020c39ac(u32 index, const ActorTypeId *actorTypes, bool param3); s32 func_ov00_020c3b2c(s32 *param1); s32 func_ov00_020c3bb0(unk32 param1, s32 *param2); void func_ov00_020c3ce8(unk32 param1, unk32 param2); diff --git a/include/Actor/ActorRef.hpp b/include/Actor/ActorRef.hpp index be82f8a8..eeace571 100644 --- a/include/Actor/ActorRef.hpp +++ b/include/Actor/ActorRef.hpp @@ -9,13 +9,12 @@ struct ActorRef { /* 8 */ inline ActorRef() {} - inline ActorRef(s32 id, s32 index): + inline ActorRef(s32 id, s32 index) : id(id), - index(index) - {} + index(index) {} inline void Reset() { - id = -1; + id = -1; index = -1; } }; diff --git a/include/Actor/ActorRupee.hpp b/include/Actor/ActorRupee.hpp index 4ec671b8..c0618394 100644 --- a/include/Actor/ActorRupee.hpp +++ b/include/Actor/ActorRupee.hpp @@ -1,8 +1,8 @@ #pragma once #include "global.h" -#include "types.h" #include "lib/math.h" +#include "types.h" #include "Actor/Actor.hpp" #include "Actor/ActorType.hpp" @@ -40,7 +40,7 @@ public: /* 64 */ virtual void vfunc_64() override; /* b4 */ - static ActorRupee* Create(); + static ActorRupee *Create(); ActorRupee(); void Move(); ItemId GetRupeeCutsceneItemId(); diff --git a/include/Actor/ActorType.hpp b/include/Actor/ActorType.hpp index 06fd3b59..76fb560d 100644 --- a/include/Actor/ActorType.hpp +++ b/include/Actor/ActorType.hpp @@ -39,98 +39,95 @@ #define __ACTOR_TYPE_7 '7' #define __ACTOR_TYPE_8 '8' #define __ACTOR_TYPE_9 '9' -#define __CONCAT(a,b) a ## b +#define __CONCAT(a, b) a##b #define __EVAL(x) x -#define __ACTOR_TYPE_ID(a,b,c,d) ( \ - (__EVAL(__CONCAT(__ACTOR_TYPE_,a)) << 24) \ - | (__EVAL(__CONCAT(__ACTOR_TYPE_,b)) << 16) \ - | (__EVAL(__CONCAT(__ACTOR_TYPE_,c)) << 8) \ - | (__EVAL(__CONCAT(__ACTOR_TYPE_,d))) \ -) +#define __ACTOR_TYPE_ID(a, b, c, d) \ + ((__EVAL(__CONCAT(__ACTOR_TYPE_, a)) << 24) | (__EVAL(__CONCAT(__ACTOR_TYPE_, b)) << 16) | \ + (__EVAL(__CONCAT(__ACTOR_TYPE_, c)) << 8) | (__EVAL(__CONCAT(__ACTOR_TYPE_, d)))) typedef u32 ActorTypeId; enum ActorTypeId_ { - ActorTypeId_Null = __ACTOR_TYPE_ID(N,U,L,L), - - ActorTypeId_Navi = __ACTOR_TYPE_ID(N,A,V,I), - ActorTypeId_ForceNavi = __ACTOR_TYPE_ID(F,C,N,V), - ActorTypeId_WisdomNavi = __ACTOR_TYPE_ID(W,S,N,V), - - ActorTypeId_TreasureMap = __ACTOR_TYPE_ID(T,M,A,P), - ActorTypeId_DigSpot = __ACTOR_TYPE_ID(D,G,T,G), - - ActorTypeId_ShopItemBombchus = __ACTOR_TYPE_ID(I,T,B,T), - ActorTypeId_ShopItemBombs = __ACTOR_TYPE_ID(I,T,B,M), - ActorTypeId_ShopItemTreasure = __ACTOR_TYPE_ID(I,T,T,R), - ActorTypeId_ShopItemHeartContainer = __ACTOR_TYPE_ID(I,T,H,U), - ActorTypeId_ShopItemQuiver = __ACTOR_TYPE_ID(I,T,A,P), - ActorTypeId_ShopItemBombBag = __ACTOR_TYPE_ID(I,T,B,B), - ActorTypeId_ShopItemRedPotion = __ACTOR_TYPE_ID(I,T,P,B), - ActorTypeId_ShopItemCourageGem = __ACTOR_TYPE_ID(I,T,S,R), - ActorTypeId_ShopItemShield = __ACTOR_TYPE_ID(I,T,S,L), - ActorTypeId_ShopItemSoldOut = __ACTOR_TYPE_ID(I,T,S,O), - - ActorTypeId_Heart = __ACTOR_TYPE_ID(H,A,R,T), - ActorTypeId_Rupee = __ACTOR_TYPE_ID(R,U,P,Y), - - ActorTypeId_Bomb = __ACTOR_TYPE_ID(B,O,M,B), - ActorTypeId_Arrow = __ACTOR_TYPE_ID(A,R,R,W), - - ActorTypeId_PlayerDummy = __ACTOR_TYPE_ID(P,L,D,M), - ActorTypeId_PushBlock = __ACTOR_TYPE_ID(P,S,B,L), - ActorTypeId_WindBlock = __ACTOR_TYPE_ID(W,B,L,K), - ActorTypeId_StorageDrum = __ACTOR_TYPE_ID(D,R,U,M), - - ActorTypeId_SmallKey = __ACTOR_TYPE_ID(N,K,E,Y), - - ActorTypeId_Sandworm = __ACTOR_TYPE_ID(M,L,D,W), - ActorTypeId_Tektite = __ACTOR_TYPE_ID(T,E,K,T), - ActorTypeId_PolsVoice = __ACTOR_TYPE_ID(P,L,S,V), - ActorTypeId_Yook = __ACTOR_TYPE_ID(Y,E,T,I), - ActorTypeId_Armos = __ACTOR_TYPE_ID(A,M,O,S), - ActorTypeId_Stalfos = __ACTOR_TYPE_ID(S,T,L,F), - ActorTypeId_StalfosWarrior = __ACTOR_TYPE_ID(S,T,L,W), - ActorTypeId_ChuChu = __ACTOR_TYPE_ID(C,H,U,C), - ActorTypeId_Gel = __ACTOR_TYPE_ID(G,E,L,L), - ActorTypeId_Bee = __ACTOR_TYPE_ID(B,E,E,0), - ActorTypeId_BeeHive = __ACTOR_TYPE_ID(B,E,E,H), - ActorTypeId_Cucco = __ACTOR_TYPE_ID(K,O,K,O), - ActorTypeId_Rope = __ACTOR_TYPE_ID(S,N,A,K), - ActorTypeId_Octorok = __ACTOR_TYPE_ID(O,C,T,A), - ActorTypeId_Keese = __ACTOR_TYPE_ID(K,E,T,H), - ActorTypeId_Rat = __ACTOR_TYPE_ID(R,A,T,0), - ActorTypeId_Beamos = __ACTOR_TYPE_ID(B,M,O,S), - ActorTypeId_LikeLike = __ACTOR_TYPE_ID(L,K,L,K), - ActorTypeId_Crow = __ACTOR_TYPE_ID(C,R,O,W), - - ActorTypeId_Linebeck = __ACTOR_TYPE_ID(L,N,B,K), - ActorTypeId_Mailbox = __ACTOR_TYPE_ID(P,O,S,T), - ActorTypeId_Postman = __ACTOR_TYPE_ID(P,S,T,M), - - ActorTypeId_BIGR = __ACTOR_TYPE_ID(B,I,G,R), - ActorTypeId_BKEY = __ACTOR_TYPE_ID(B,K,E,Y), - ActorTypeId_BLST = __ACTOR_TYPE_ID(B,L,S,T), - ActorTypeId_BMRN = __ACTOR_TYPE_ID(B,M,R,N), - ActorTypeId_BMTY = __ACTOR_TYPE_ID(B,M,T,Y), - ActorTypeId_BTRF = __ACTOR_TYPE_ID(B,T,R,F), - ActorTypeId_CBLS = __ACTOR_TYPE_ID(C,B,L,S), - ActorTypeId_FLAL = __ACTOR_TYPE_ID(F,L,A,L), - ActorTypeId_FLBM = __ACTOR_TYPE_ID(F,L,B,M), - ActorTypeId_FLBT = __ACTOR_TYPE_ID(F,L,B,T), - ActorTypeId_FLTB = __ACTOR_TYPE_ID(F,L,T,B), - ActorTypeId_FLTM = __ACTOR_TYPE_ID(F,L,T,M), - ActorTypeId_FORC = __ACTOR_TYPE_ID(F,O,R,C), - ActorTypeId_ROPE = __ACTOR_TYPE_ID(R,O,P,E), - ActorTypeId_SBEM = __ACTOR_TYPE_ID(S,B,E,M), - ActorTypeId_STNE = __ACTOR_TYPE_ID(S,T,N,E), - ActorTypeId_TARU = __ACTOR_TYPE_ID(T,A,R,U), - ActorTypeId_TSBH = __ACTOR_TYPE_ID(T,S,B,H), - ActorTypeId_TSUB = __ACTOR_TYPE_ID(T,S,U,B), - ActorTypeId_VLR0 = __ACTOR_TYPE_ID(V,L,R,0), + ActorTypeId_Null = __ACTOR_TYPE_ID(N, U, L, L), + + ActorTypeId_Navi = __ACTOR_TYPE_ID(N, A, V, I), + ActorTypeId_ForceNavi = __ACTOR_TYPE_ID(F, C, N, V), + ActorTypeId_WisdomNavi = __ACTOR_TYPE_ID(W, S, N, V), + + ActorTypeId_TreasureMap = __ACTOR_TYPE_ID(T, M, A, P), + ActorTypeId_DigSpot = __ACTOR_TYPE_ID(D, G, T, G), + + ActorTypeId_ShopItemBombchus = __ACTOR_TYPE_ID(I, T, B, T), + ActorTypeId_ShopItemBombs = __ACTOR_TYPE_ID(I, T, B, M), + ActorTypeId_ShopItemTreasure = __ACTOR_TYPE_ID(I, T, T, R), + ActorTypeId_ShopItemHeartContainer = __ACTOR_TYPE_ID(I, T, H, U), + ActorTypeId_ShopItemQuiver = __ACTOR_TYPE_ID(I, T, A, P), + ActorTypeId_ShopItemBombBag = __ACTOR_TYPE_ID(I, T, B, B), + ActorTypeId_ShopItemRedPotion = __ACTOR_TYPE_ID(I, T, P, B), + ActorTypeId_ShopItemCourageGem = __ACTOR_TYPE_ID(I, T, S, R), + ActorTypeId_ShopItemShield = __ACTOR_TYPE_ID(I, T, S, L), + ActorTypeId_ShopItemSoldOut = __ACTOR_TYPE_ID(I, T, S, O), + + ActorTypeId_Heart = __ACTOR_TYPE_ID(H, A, R, T), + ActorTypeId_Rupee = __ACTOR_TYPE_ID(R, U, P, Y), + + ActorTypeId_Bomb = __ACTOR_TYPE_ID(B, O, M, B), + ActorTypeId_Arrow = __ACTOR_TYPE_ID(A, R, R, W), + + ActorTypeId_PlayerDummy = __ACTOR_TYPE_ID(P, L, D, M), + ActorTypeId_PushBlock = __ACTOR_TYPE_ID(P, S, B, L), + ActorTypeId_WindBlock = __ACTOR_TYPE_ID(W, B, L, K), + ActorTypeId_StorageDrum = __ACTOR_TYPE_ID(D, R, U, M), + + ActorTypeId_SmallKey = __ACTOR_TYPE_ID(N, K, E, Y), + + ActorTypeId_Sandworm = __ACTOR_TYPE_ID(M, L, D, W), + ActorTypeId_Tektite = __ACTOR_TYPE_ID(T, E, K, T), + ActorTypeId_PolsVoice = __ACTOR_TYPE_ID(P, L, S, V), + ActorTypeId_Yook = __ACTOR_TYPE_ID(Y, E, T, I), + ActorTypeId_Armos = __ACTOR_TYPE_ID(A, M, O, S), + ActorTypeId_Stalfos = __ACTOR_TYPE_ID(S, T, L, F), + ActorTypeId_StalfosWarrior = __ACTOR_TYPE_ID(S, T, L, W), + ActorTypeId_ChuChu = __ACTOR_TYPE_ID(C, H, U, C), + ActorTypeId_Gel = __ACTOR_TYPE_ID(G, E, L, L), + ActorTypeId_Bee = __ACTOR_TYPE_ID(B, E, E, 0), + ActorTypeId_BeeHive = __ACTOR_TYPE_ID(B, E, E, H), + ActorTypeId_Cucco = __ACTOR_TYPE_ID(K, O, K, O), + ActorTypeId_Rope = __ACTOR_TYPE_ID(S, N, A, K), + ActorTypeId_Octorok = __ACTOR_TYPE_ID(O, C, T, A), + ActorTypeId_Keese = __ACTOR_TYPE_ID(K, E, T, H), + ActorTypeId_Rat = __ACTOR_TYPE_ID(R, A, T, 0), + ActorTypeId_Beamos = __ACTOR_TYPE_ID(B, M, O, S), + ActorTypeId_LikeLike = __ACTOR_TYPE_ID(L, K, L, K), + ActorTypeId_Crow = __ACTOR_TYPE_ID(C, R, O, W), + + ActorTypeId_Linebeck = __ACTOR_TYPE_ID(L, N, B, K), + ActorTypeId_Mailbox = __ACTOR_TYPE_ID(P, O, S, T), + ActorTypeId_Postman = __ACTOR_TYPE_ID(P, S, T, M), + + ActorTypeId_BIGR = __ACTOR_TYPE_ID(B, I, G, R), + ActorTypeId_BKEY = __ACTOR_TYPE_ID(B, K, E, Y), + ActorTypeId_BLST = __ACTOR_TYPE_ID(B, L, S, T), + ActorTypeId_BMRN = __ACTOR_TYPE_ID(B, M, R, N), + ActorTypeId_BMTY = __ACTOR_TYPE_ID(B, M, T, Y), + ActorTypeId_BTRF = __ACTOR_TYPE_ID(B, T, R, F), + ActorTypeId_CBLS = __ACTOR_TYPE_ID(C, B, L, S), + ActorTypeId_FLAL = __ACTOR_TYPE_ID(F, L, A, L), + ActorTypeId_FLBM = __ACTOR_TYPE_ID(F, L, B, M), + ActorTypeId_FLBT = __ACTOR_TYPE_ID(F, L, B, T), + ActorTypeId_FLTB = __ACTOR_TYPE_ID(F, L, T, B), + ActorTypeId_FLTM = __ACTOR_TYPE_ID(F, L, T, M), + ActorTypeId_FORC = __ACTOR_TYPE_ID(F, O, R, C), + ActorTypeId_ROPE = __ACTOR_TYPE_ID(R, O, P, E), + ActorTypeId_SBEM = __ACTOR_TYPE_ID(S, B, E, M), + ActorTypeId_STNE = __ACTOR_TYPE_ID(S, T, N, E), + ActorTypeId_TARU = __ACTOR_TYPE_ID(T, A, R, U), + ActorTypeId_TSBH = __ACTOR_TYPE_ID(T, S, B, H), + ActorTypeId_TSUB = __ACTOR_TYPE_ID(T, S, U, B), + ActorTypeId_VLR0 = __ACTOR_TYPE_ID(V, L, R, 0), }; class Actor; -typedef Actor* (*ActorCreateFunc)(); +typedef Actor *(*ActorCreateFunc)(); struct ActorType { /* 00 */ ActorTypeId id; @@ -146,7 +143,7 @@ struct ActorType { unk32 func_0203e7c8(); void Register(); void Unregister(); - static ActorType* Find(ActorTypeId id); + static ActorType *Find(ActorTypeId id); }; struct ActorTypeList { |
