Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
rubberduckycooly
GitHub Repository: rubberduckycooly/Sonic-Mania-Decompilation
Path: blob/master/SonicMania/Objects/BSS/BSS_Collectable.h
338 views
1
#ifndef OBJ_BSS_COLLECTABLE_H
2
#define OBJ_BSS_COLLECTABLE_H
3
4
#include "Game.h"
5
6
typedef enum {
7
BSS_NONE = 0,
8
BSS_SPHERE_BLUE = 1,
9
BSS_SPHERE_RED = 2,
10
BSS_SPHERE_BUMPER = 3,
11
BSS_SPHERE_YELLOW = 4,
12
BSS_SPHERE_GREEN = 5,
13
BSS_SPHERE_PINK = 6,
14
BSS_RING = 7,
15
BSS_SPAWN_UP = 8,
16
BSS_SPAWN_RIGHT = 9,
17
BSS_SPAWN_DOWN = 10,
18
BSS_SPAWN_LEFT = 11,
19
BSS_UNUSED_1 = 12,
20
BSS_UNUSED_2 = 13,
21
BSS_UNUSED_3 = 14,
22
BSS_RING_SPARKLE = 15,
23
BSS_EMERALD_CHAOS = 16,
24
BSS_EMERALD_SUPER = 17,
25
BSS_MEDAL_SILVER = 18,
26
BSS_MEDAL_GOLD = 19,
27
BSS_UNUSED_4 = 20,
28
BSS_UNUSED_5 = 21,
29
BSS_UNUSED_6 = 22,
30
BSS_UNUSED_7 = 23,
31
32
BSS_SPHERE_GREEN_STOOD = 0x80 | 1,
33
BSS_BLUE_STOOD = 0x80 | 2,
34
BSS_SPHERE_PINK_STOOD = 0x80 | 6,
35
} BSSCollectableTypes;
36
37
// Object Class
38
struct ObjectBSS_Collectable {
39
RSDK_OBJECT
40
Animator sphereAnimator[24];
41
uint8 initializedTables;
42
TABLE(int32 ringScaleTableX[32],
43
{ 2, 4, 4, 4, 6, 6, 6, 7, 7, 8, 8, 9, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 22, 24, 26, 28, 30, 32, 32, 32 });
44
TABLE(int32 ringScaleTableY[32],
45
{ 2, 4, 4, 4, 6, 6, 6, 7, 7, 8, 8, 9, 9, 10, 11, 12, 13, 14, 15, 16, 16, 17, 17, 18, 18, 19, 19, 20, 21, 22, 23, 24 });
46
TABLE(int32 medalScaleTable[32],
47
{ 4, 4, 5, 5, 6, 6, 7, 7, 8, 10, 12, 14, 16, 18, 20, 22, 24, 25, 26, 27, 28, 29, 30, 31, 32, 32, 32, 32, 32, 32, 32, 32 });
48
int32 screenYValues[32];
49
int32 medalScreenYVals[32];
50
uint16 aniFrames;
51
uint16 ringFrames;
52
};
53
54
// Entity Class
55
struct EntityBSS_Collectable {
56
RSDK_ENTITY
57
int32 type;
58
Animator animator;
59
};
60
61
// Object Struct
62
extern ObjectBSS_Collectable *BSS_Collectable;
63
64
// Standard Entity Events
65
void BSS_Collectable_Update(void);
66
void BSS_Collectable_LateUpdate(void);
67
void BSS_Collectable_StaticUpdate(void);
68
void BSS_Collectable_Draw(void);
69
void BSS_Collectable_Create(void *data);
70
void BSS_Collectable_StageLoad(void);
71
#if GAME_INCLUDE_EDITOR
72
void BSS_Collectable_EditorDraw(void);
73
void BSS_Collectable_EditorLoad(void);
74
#endif
75
void BSS_Collectable_Serialize(void);
76
77
// Extra Entity Functions
78
79
#endif //! OBJ_BSS_COLLECTABLE_H
80
81