SSBM Decomp
Loading...
Searching...
No Matches
types.h
Go to the documentation of this file.
1#ifndef MELEE_IF_TYPES_H
2#define MELEE_IF_TYPES_H
3
4#include <placeholder.h>
5#include <platform.h>
6
7#include "if/forward.h" // IWYU pragma: export
8#include "sc/forward.h"
9#include <baselib/forward.h>
10
11#include <dolphin/gx.h>
12
22
27
30 /* +04 */ HSD_GObj* next;
31 /* +08 */ u8 player_slot;
32 /* +09 */ u8 unk9;
33 /* +0A */ s16 damage_percent;
34 /* +0C */ s16 old_damage;
38 /* +14 */ float translation_x[HUD_PLACE_MAX];
39 /* +24 */ float translation_y[HUD_PLACE_MAX];
40 /* +34 */ float velocity_x[HUD_PLACE_MAX];
41 /* +44 */ float velocity_y[HUD_PLACE_MAX];
43};
44
45struct HudIndex {
47 /* +258 */ HSD_Joint* unk258;
48 /* +25C */ void* jobj_desc_parent;
50 /* +264 */ void* janim_selection_textures;
51 /* +268 */ void* unk268;
52 /* +26C */ void* unk26C;
53 /* +270 */ void* unk270;
54 /* +274 */ void* unk274;
55 // 8 elements of size 0x28, what is this?
56};
57
62
64 u8 x0 : 1;
65 u8 x1 : 1;
66 u8 x2 : 1;
67 u8 x3 : 1;
68 u8 x4 : 1;
69 u8 x5 : 1;
70 u8 x6 : 1;
71 u8 x7 : 1;
72};
73
74typedef void (*IfStatusCb)(s32);
75
77 /* +00 */ HSD_GObj* x0;
78 /* +04 */ u32 x4;
79 /* +08 */ void (*x8)(HSD_GObj*);
80 /* +0C */ u32 xC;
81 /* +10 */ u8 x10;
82 /* +11 */ u8 x11;
83 /* +12 */ struct Element_803F9628_x12 x12;
84 /* +13 */ u8 x13;
86 /* +18 */ IfStatusCb x18;
87 /* +1C */ IfStatusCb x1C;
88 /* +20 */ u32 x20;
89 /* +24 */ u32 x24;
90};
91
93 u8 unk80 : 1;
94 u8 unk40 : 1;
95 u8 unk20 : 1;
96 u8 unk10 : 1;
97 u8 unk8 : 1;
98 u8 unk4 : 1;
99 u8 unk2 : 1;
100 u8 unk1 : 1;
101};
102
108
109typedef struct ifMagnifyPlayer {
110 HSD_GObj* gobj; // ifMagnify_802fc750 accesses 0x804A1DF4 + slot * 0x10
111 // for a GObj
112 HSD_JObj* jobj; // ifMagnify_802fc3c0 / ifMagnify_802fb8c0 access
113 // 0x804A1DF8 for a JObj
115 idesc; // ifMagnify_802FBBDC access 0x804A1DFC for an ImageDesc
116 struct {
119 u8 unk : 6;
122
123struct ifMagnify {
124 DynamicModelDesc* model_desc; // ifMagnify_802fc3c0 accesses 0x804A1DE0
125 int x4;
126 int x8;
127 int xC;
128 int x10;
130 u8 image_descs[5 * 0x18];
131 u8 pad[0xF0 - 0xEC];
132};
133
134#define DEVTEXT_FLAG_HIDETEXT (0x80)
135#define DEVTEXT_FLAG_HIDEBACKGROUND (0x40)
136#define DEVTEXT_FLAG_NOWRAP (0x20)
137#define DEVTEXT_FLAG_SHOWCURSOR (0x10)
138
139struct DevText {
140 /* +0 */ s16 x;
141 /* +2 */ s16 y;
142 /* +4 */ u8 w;
143 /* +5 */ u8 h;
144 /* +6 */ u8 cursor_x;
145 /* +7 */ u8 cursor_y;
146 /* +8 */ f32 scale_x;
147 /* +C */ f32 scale_y;
148 /* +10 */ GXColor bg_color;
149 /* +14 */ GXColor text_colors[4];
150 /* +24 */ s8 id;
151 /* +25 */ u8 line_width;
152 /* +26 */ u8 flags;
153 /* +27 */ u8 unk : 6;
154 /* +27 */ u8 current_color : 2;
155 /* +28 */ char* buf;
156 /* +2C */ struct DevText* prev;
157 /* +30 */ struct DevText* next;
158};
159
161 /* +0x00 */ u32 x00;
162 /* +0x04 */ HSD_GObj* unk4;
163 /* +0x08 */ u32 x08;
164 /* +0x0C */ u32 x0C;
165 /* +0x10 */ HSD_JObj* jobjs[16];
166 /* +0x50 */ HSD_Archive* archive;
167 /* +0x54 */ short x54;
168 /* +0x56 */ short x56;
169 /* +0x58 */ short x58;
170 /* +0x5A */ char pad_5A[2];
171 /* +0x5C */ s8 x5C;
172 /* +0x5D */ s8 x5D;
173 /* +0x5E */ s8 x5E;
174};
175
177 void* x0;
179};
180
182 int x0;
183 int (*x4)(int);
184 char* x8;
185 char** xC;
186 void* x10;
187 float x14;
188 float x18;
189 float x1C;
190};
192
204STATIC_ASSERT(sizeof(struct un_80304138_objalloc_t) == 0x20);
205
206#endif
signed char s8
Definition hsd_3B2B.h:3
signed long s32
Definition hsd_3B2B.h:1
unsigned char u8
Definition hsd_3B2B.h:2
void(* IfStatusCb)(s32)
Definition types.h:74
@ HUD_PLACE_MAX
Definition forward.h:24
#define STATIC_ASSERT(cond)
Definition platform.h:110
Definition types.h:139
u8 current_color
Definition types.h:154
u8 w
Definition types.h:142
char * buf
Definition types.h:155
u8 flags
Definition types.h:152
s16 y
Definition types.h:141
s16 x
Definition types.h:140
u8 unk
Definition types.h:153
s8 id
Definition types.h:150
GXColor bg_color
Definition types.h:148
u8 line_width
Definition types.h:151
u8 cursor_x
Definition types.h:144
GXColor text_colors[4]
Definition types.h:149
f32 scale_y
Definition types.h:147
struct DevText * prev
Definition types.h:156
f32 scale_x
Definition types.h:146
u8 cursor_y
Definition types.h:145
struct DevText * next
Definition types.h:157
u8 h
Definition types.h:143
Model with multiple animations.
Definition types.h:18
Definition types.h:58
s32 unk1C
Definition types.h:60
s32 padding[6]
Definition types.h:59
Definition types.h:63
u8 x2
Definition types.h:66
u8 x0
Definition types.h:64
u8 x6
Definition types.h:70
u8 x1
Definition types.h:65
u8 x5
Definition types.h:69
u8 x4
Definition types.h:68
u8 x7
Definition types.h:71
u8 x3
Definition types.h:67
Definition types.h:76
u8 x10
Definition types.h:81
IfStatusCb x18
Definition types.h:86
DynamicModelDesc * x14
Definition types.h:85
struct Element_803F9628_x12 x12
Definition types.h:83
IfStatusCb x1C
Definition types.h:87
HSD_GObj * x0
Definition types.h:77
u32 x4
Definition types.h:78
u32 xC
Definition types.h:80
u32 x20
Definition types.h:88
u8 x11
Definition types.h:82
void(* x8)(HSD_GObj *)
Definition types.h:79
u8 x13
Definition types.h:84
u32 x24
Definition types.h:89
Definition aobj.h:58
Definition archive.h:34
Definition gobjproc.h:8
was using this to try and fix some matches, unsuccessfully
Definition gobj.h:26
Definition tobj.h:205
Definition jobj.h:107
Definition jobj.h:130
Definition types.h:45
void * unk26C
Definition types.h:52
IfDamageState players[6]
Definition types.h:46
HSD_AnimJoint * janim_selection_joints
Definition types.h:49
void * unk268
Definition types.h:51
void * unk270
Definition types.h:53
HSD_Joint * unk258
Definition types.h:47
void * jobj_desc_parent
Definition types.h:48
void * unk274
Definition types.h:54
void * janim_selection_textures
Definition types.h:50
Definition types.h:13
u8 force_digit_shake
Definition types.h:16
u8 unk1
Definition types.h:20
u8 explode_animation
Definition types.h:14
u8 unk10
Definition types.h:17
u8 hide_all_digits
Definition types.h:18
u8 animation_status_id
Definition types.h:19
u8 randomize_velocity
Definition types.h:15
Definition types.h:28
s16 old_damage
Definition types.h:34
float translation_y[HUD_PLACE_MAX]
Definition types.h:39
IfDamageFlags flags
Definition types.h:37
u8 unk9
Definition types.h:32
s16 damage_percent
Definition types.h:33
u8 frames_of_shake_remaining
Definition types.h:36
u8 damage_from_last_attack
Definition types.h:35
float velocity_y[HUD_PLACE_MAX]
Definition types.h:41
HSD_JObj * jobjs[HUD_PLACE_MAX]
Definition types.h:42
float velocity_x[HUD_PLACE_MAX]
Definition types.h:40
HSD_GObj * next
Definition types.h:30
u8 player_slot
Definition types.h:31
HSD_GObj * HUD_parent_entity
Definition types.h:29
float translation_x[HUD_PLACE_MAX]
Definition types.h:38
Definition types.h:92
u8 unk8
Definition types.h:97
u8 unk1
Definition types.h:100
u8 unk4
Definition types.h:98
u8 unk80
Definition types.h:93
u8 unk20
Definition types.h:95
u8 unk10
Definition types.h:96
u8 unk2
Definition types.h:99
u8 unk40
Definition types.h:94
Definition types.h:103
Placeholder_8016AE50_flags flags
Definition types.h:106
u8 unk1
Definition types.h:105
u8 unk0
Definition types.h:104
Definition types.h:23
s32 padding[0x24]
Definition types.h:24
HSD_JObj * unk28
Definition types.h:25
Definition types.h:109
HSD_ImageDesc * idesc
Definition types.h:115
HSD_GObj * gobj
Definition types.h:110
u8 ignore_offscreen
Definition types.h:118
HSD_JObj * jobj
Definition types.h:112
struct ifMagnifyPlayer::@306020216374134120377357200007333304076246373311 state
u8 unk
Definition types.h:119
u8 is_offscreen
Definition types.h:117
Definition types.h:123
int xC
Definition types.h:127
u8 pad[0xF0 - 0xEC]
Definition types.h:131
DynamicModelDesc * model_desc
Definition types.h:124
int x8
Definition types.h:126
u8 image_descs[5 *0x18]
Definition types.h:130
int x10
Definition types.h:128
int x4
Definition types.h:125
ifMagnifyPlayer player[6]
Definition types.h:129
Definition types.h:176
void * x0
Definition types.h:177
s32 x4
Definition types.h:178
Definition types.h:181
int x0
Definition types.h:182
int(* x4)(int)
Definition types.h:183
char * x8
Definition types.h:184
float x1C
Definition types.h:189
float x18
Definition types.h:188
float x14
Definition types.h:187
char ** xC
Definition types.h:185
void * x10
Definition types.h:186
Definition types.h:193
HSD_GObj * x10
Definition types.h:199
struct un_80304138_objalloc_t * prev
Definition types.h:201
unsigned char x1
Definition types.h:195
HSD_GObjProc * x14
Definition types.h:200
unsigned char x0
Definition types.h:194
struct un_80304138_objalloc_t * next
Definition types.h:202
DevText * x4
Definition types.h:196
int(* xC)(int)
Definition types.h:198
struct un_80304138_objalloc_t_x8 * x8
Definition types.h:197
Definition types.h:160
HSD_JObj * jobjs[16]
Definition types.h:165
u32 x00
Definition types.h:161
HSD_Archive * archive
Definition types.h:166
u32 x0C
Definition types.h:164
s8 x5E
Definition types.h:173
char pad_5A[2]
Definition types.h:170
s8 x5C
Definition types.h:171
s8 x5D
Definition types.h:172
HSD_GObj * unk4
Definition types.h:162
short x54
Definition types.h:167
short x56
Definition types.h:168
short x58
Definition types.h:169
u32 x08
Definition types.h:163