25 f32* centerX, f32* centerY, f32* centerZ,
26 f32* sizeX, f32* sizeY, f32* sizeZ)
28 D_E0084E34(modelID, centerX, centerY, centerZ, sizeX, sizeY, sizeZ);
45 f32 centerX, centerY, centerZ;
46 f32 sizeX, sizeY, sizeZ;
47 s32 xParts, yParts, zParts;
53 xParts = (sizeX * 0.0625f) + 1.0f;
54 yParts = (sizeY * 0.0625f) + 1.0f;
55 zParts = (sizeZ * 0.0625f) + 1.0f;
57 f20 = (s32)sizeX % 16;
58 f30 = (s32)sizeY % 16;
59 f40 = (s32)sizeZ % 16;
66 bp.
effectID = EFFECT_BOMBETTE_BREAKING;
72 numParts = (xParts * yParts * zParts) + 1;
78 data->
unk_04 = -sizeY * 0.5;
85 data->
unk_3C = 2.0f * arg3;
89 data->
unk_40 = sizeY * 0.05;
95 for (iX = 0; iX < xParts; iX++) {
96 centerX = f20 - (sizeX * 0.5) + (iX * 16.0f);
97 for (iY = 0; iY < yParts; iY++) {
98 centerY = f30 - (sizeY * 0.5) + (iY * 16.0f);
99 for (iZ = 0; iZ < zParts; iZ++) {
100 centerZ = f30 - (sizeZ * 0.5) + (iZ * 16.0f);
108 data->
unk_20.
x = 2.0 * (centerX / (sizeX * 0.5));
120 data->
unk_20.
z = 2.0 * (centerZ / (sizeZ * 0.5));
130 data->
unk_20.
y = centerY * 0.2;
131 data->
unk_2C.
x = centerZ * 0.2 + (centerX < centerZ ? (centerZ < 0 ? -1.0 : (centerZ > 0 ? 1.0 : 0.0)) : 0.0);
132 data->
unk_2C.
y = centerY * 0.2;
133 data->
unk_2C.
z = centerX * 0.2 + (centerZ < centerX ? (centerX < 0 ? -1.0 : (centerX > 0 ? 1.0 : 0.0)) : 0.0);
167 for (i = 1; i < effect->
numParts; i++, data++) {
209 u16 type = data->
type;
212 f32 unk_38 = data->
unk_38;
213 f32 unk_40 = data->
unk_40;
214 s32 mainAlpha = data->
alpha;
228 for (i = 1; i < ((
EffectInstance*)effect)->numParts; i++, data++) {
229 guPositionF(sp20, timeLeft + (130 * i), timeLeft - (40 * i), timeLeft + (80 * i), unk_40,
233 G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
242 for (i = 1; i < ((
EffectInstance*)effect)->numParts; i++, data++) {
243 gDPSetPrimColor(
gMainGfxPos++, 0, 0, 255, 255, 255, (data->
alpha * mainAlpha) / 255);
248 G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
void bombette_breaking_update(EffectInstance *effect)
void bombette_breaking_render(EffectInstance *effect)
s32 bombette_breaking_get_model_list_index_from_tree_index(s32 listIndex)
Model * bombette_breaking_get_model_from_list_index(s32 listIndex)
void bombette_breaking_appendGfx(void *effect)
EffectInstance * bombette_breaking_main(s32 type, s32 modelID, s32 treeIndex, f32 arg3, s32 arg4, s32 time)
void(* D_E0084E34)(u16, f32 *, f32 *, f32 *, f32 *, f32 *, f32 *)
Model *(* D_E0084E38)(s32)
void bombette_breaking_get_model_center_and_size(s32 modelID, f32 *centerX, f32 *centerY, f32 *centerZ, f32 *sizeX, f32 *sizeY, f32 *sizeZ)
void bombette_breaking_init(EffectInstance *effect)
#define general_heap_malloc
#define queue_render_task
#define mdl_draw_hidden_panel_surface
#define create_effect_instance
struct BombetteBreakingFXData * bombetteBreaking
#define ASSERT(condition)
@ RENDER_TASK_FLAG_REFLECT_FLOOR
@ RENDER_MODE_PASS_THROUGH
s32 get_model_list_index_from_tree_index(s32 treeIndex)
struct Model * get_model_from_list_index(s32 listIndex)
void get_model_center_and_size(u16 modelID, f32 *centerX, f32 *centerY, f32 *centerZ, f32 *sizeX, f32 *sizeY, f32 *sizeZ)
#define VIRTUAL_TO_PHYSICAL(addr)
void(* renderUI)(EffectInstance *effectInst)
void(* init)(EffectInstance *effectInst)
void(* update)(EffectInstance *effectInst)
void(* renderWorld)(EffectInstance *effectInst)
void(* appendGfx)(void *)
DisplayContext * gDisplayContext