Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
rubberduckycooly
GitHub Repository: rubberduckycooly/Sonic-Mania-Decompilation
Path: blob/master/SonicMania/Objects/HCZ/Buggernaut.h
338 views
1
#ifndef OBJ_BUGGERNAUT_H
2
#define OBJ_BUGGERNAUT_H
3
4
#include "Game.h"
5
6
// Object Class
7
struct ObjectBuggernaut {
8
RSDK_OBJECT
9
Hitbox hitboxBadnik;
10
Hitbox hitboxParentRange;
11
uint16 aniFrames;
12
};
13
14
// Entity Class
15
struct EntityBuggernaut {
16
RSDK_ENTITY
17
StateMachine(state);
18
bool32 passThrough;
19
int32 timer;
20
int32 buzzCount;
21
Vector2 startPos;
22
EntityBuggernaut *parent;
23
Animator bodyAnimator;
24
Animator wingAnimator;
25
};
26
27
// Object Struct
28
extern ObjectBuggernaut *Buggernaut;
29
30
// Standard Entity Events
31
void Buggernaut_Update(void);
32
void Buggernaut_LateUpdate(void);
33
void Buggernaut_StaticUpdate(void);
34
void Buggernaut_Draw(void);
35
void Buggernaut_Create(void *data);
36
void Buggernaut_StageLoad(void);
37
#if GAME_INCLUDE_EDITOR
38
void Buggernaut_EditorDraw(void);
39
void Buggernaut_EditorLoad(void);
40
#endif
41
void Buggernaut_Serialize(void);
42
43
// Extra Entity Functions
44
void Buggernaut_DebugSpawn(void);
45
void Buggernaut_DebugDraw(void);
46
47
void Buggernaut_CheckPlayerCollisions(void);
48
void Buggernaut_CheckOffScreen(void);
49
bool32 Buggernaut_HandleTileCollisionsX(void);
50
bool32 Buggernaut_HandleTileCollisionsY(void);
51
52
void Buggernaut_State_Init(void);
53
void Buggernaut_State_Idle(void);
54
void Buggernaut_State_FlyTowardTarget(void);
55
void Buggernaut_State_FlyAway(void);
56
57
void Buggernaut_State_Child(void);
58
59
#endif //! OBJ_BUGGERNAUT_H
60
61