Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
rubberduckycooly
GitHub Repository: rubberduckycooly/Sonic-Mania-Decompilation
Path: blob/master/SonicMania/Objects/Menu/UICharButton.h
338 views
1
#ifndef OBJ_UICHARBUTTON_H
2
#define OBJ_UICHARBUTTON_H
3
4
#include "Game.h"
5
6
typedef enum {
7
UICHARBUTTON_SONIC,
8
UICHARBUTTON_TAILS,
9
UICHARBUTTON_KNUX,
10
#if MANIA_USE_PLUS
11
UICHARBUTTON_MIGHTY,
12
UICHARBUTTON_RAY,
13
#endif
14
} UICharButtonCharacterIDs;
15
16
// Object Class
17
struct ObjectUICharButton {
18
RSDK_OBJECT
19
uint16 aniFrames;
20
};
21
22
// Entity Class
23
struct EntityUICharButton {
24
MANIA_UI_ITEM_BASE
25
uint8 characterID;
26
int32 triBounceVelocity;
27
int32 triBounceOffset;
28
int32 playerBounceVelocity;
29
int32 playerBounceOffset;
30
int32 unused;
31
Animator unusedAnimator;
32
Animator playerAnimator;
33
Animator shadowAnimator;
34
Animator nameAnimator;
35
};
36
37
// Object Struct
38
extern ObjectUICharButton *UICharButton;
39
40
// Standard Entity Events
41
void UICharButton_Update(void);
42
void UICharButton_LateUpdate(void);
43
void UICharButton_StaticUpdate(void);
44
void UICharButton_Draw(void);
45
void UICharButton_Create(void *data);
46
void UICharButton_StageLoad(void);
47
#if GAME_INCLUDE_EDITOR
48
void UICharButton_EditorDraw(void);
49
void UICharButton_EditorLoad(void);
50
#endif
51
void UICharButton_Serialize(void);
52
53
// Extra Entity Functions
54
void UICharButton_DrawOutlines(void);
55
void UICharButton_DrawBG(void);
56
void UICharButton_DrawPlayers(void);
57
58
void UICharButton_SelectedCB(void);
59
bool32 UICharButton_CheckButtonEnterCB(void);
60
bool32 UICharButton_CheckSelectedCB(void);
61
void UICharButton_ButtonEnterCB(void);
62
void UICharButton_ButtonLeaveCB(void);
63
64
void UICharButton_State_HandleButtonLeave(void);
65
void UICharButton_State_HandleButtonEnter(void);
66
void UICharButton_State_Selected(void);
67
68
#endif //! OBJ_UICHARBUTTON_H
69
70