Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
rubberduckycooly
GitHub Repository: rubberduckycooly/Sonic-Mania-Decompilation
Path: blob/master/SonicMania/Objects/HCZ/HandLauncher.h
338 views
1
#ifndef OBJ_HANDLAUNCHER_H
2
#define OBJ_HANDLAUNCHER_H
3
4
#include "Game.h"
5
6
// Object Class
7
struct ObjectHandLauncher {
8
RSDK_OBJECT
9
uint16 aniFrames;
10
Hitbox hitboxRange;
11
Hitbox hitboxGrab;
12
Hitbox hitboxUnused;
13
bool32 dunkeyMode;
14
uint16 sfxDunkey;
15
};
16
17
// Entity Class
18
struct EntityHandLauncher {
19
RSDK_ENTITY
20
StateMachine(state);
21
int32 speed;
22
uint8 activePlayers;
23
Vector2 startPos;
24
Vector2 playerPos;
25
Vector2 hiddenPos;
26
int32 timer;
27
int32 grabDelay;
28
Animator baseAnimator;
29
Animator handAnimator;
30
};
31
32
// Object Struct
33
extern ObjectHandLauncher *HandLauncher;
34
35
// Standard Entity Events
36
void HandLauncher_Update(void);
37
void HandLauncher_LateUpdate(void);
38
void HandLauncher_StaticUpdate(void);
39
void HandLauncher_Draw(void);
40
void HandLauncher_Create(void *data);
41
void HandLauncher_StageLoad(void);
42
#if GAME_INCLUDE_EDITOR
43
void HandLauncher_EditorDraw(void);
44
void HandLauncher_EditorLoad(void);
45
#endif
46
void HandLauncher_Serialize(void);
47
48
// Extra Entity Functions
49
void HandLauncher_CheckPlayerCollisions(void);
50
bool32 HandLauncher_CheckPlayerInRange(void);
51
void HandLauncher_ReleasePlayers(void);
52
void HandLauncher_HandleGrabbedPlayers(void);
53
54
void HandLauncher_State_Init(void);
55
void HandLauncher_State_AwaitPlayer(void);
56
void HandLauncher_State_TryGrabPlayer(void);
57
void HandLauncher_State_GrabbedPlayer(void);
58
59
#endif //! OBJ_HANDLAUNCHER_H
60
61