Go to the source code of this file.
◆ snaking_static_update()
Definition at line 73 of file snaking_static.c.
73 {
75 f32 tempOffsetY;
76 f32 tempOffsetX;
77 f32 tempPosX;
78 f32 tempPosY;
79 s32 lifeTime;
80 s32 timeLeft;
81 s32 i;
82
84 effect->
flags &= ~FX_INSTANCE_FLAG_DISMISS;
86 }
87
90 }
91
95
96 if (timeLeft < 0) {
98 return;
99 }
100 if (timeLeft < 16) {
101 data->
unk_24 = timeLeft * 16;
102 }
103 if (lifeTime < 16) {
104 data->
unk_24 = (lifeTime * 16) + 15;
105 }
106
107 data++;
108 for (i = 1; i < effect->
numParts; i += 3, data += 3) {
115 }
117 tempPosX = data->
pos.
x;
118 tempPosY = data->
pos.
y;
121 data[2] = data[1];
122 data[1] = data[0];
123 data->
pos.
x = tempPosX + tempOffsetX;
124 data->
pos.
y = tempPosY + tempOffsetY;
125 data->
unk_3C =
atan2(0.0f, 0.0f, tempOffsetX, tempOffsetY);
126 if (tempOffsetX != 0.0f || tempOffsetY != 0.0f) {
127 data->
unk_34 =
sqrtf((tempOffsetX * tempOffsetX) + (tempOffsetY * tempOffsetY));
128 } else {
130 }
131 }
133 if (data->
unk_24 >= 256) {
135 }
137 }
139 data++;
140 for (i = 1; i < effect->
numParts; i++, data++) {
142 }
143}
struct SnakingStaticFXData * snakingStatic
@ FX_INSTANCE_FLAG_DISMISS
Referenced by snaking_static_main().
◆ snaking_static_init()
◆ snaking_static_render()
Definition at line 145 of file snaking_static.c.
145 {
148
151 renderTask.
dist = 10;
153
156}
#define queue_render_task
@ RENDER_TASK_FLAG_REFLECT_FLOOR
@ RENDER_MODE_CLOUD_NO_ZCMP
void snaking_static_appendGfx(void *effect)
void(* appendGfx)(void *)
Referenced by snaking_static_main().
◆ snaking_static_appendGfx()
void snaking_static_appendGfx |
( |
void * | effect | ) |
|
Definition at line 161 of file snaking_static.c.
161 {
167 s32 unk_24 = data->
unk_24;
171 s32 i;
172
175
180
182 G_MTX_PUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
186
187 data++;
188 for (i = 1; i < ((
EffectInstance*)effect)->numParts; i++, data++) {
189 gDPSetPrimColor(
gMainGfxPos++, 0, 0, primR, primG, primB, (data->
unk_24 * unk_24) / 255);
196
198 G_MTX_PUSH | G_MTX_MUL | G_MTX_MODELVIEW);
200 gDPSetTileSize(
gMainGfxPos++, 1, (lifeTime * 12), 0, ((lifeTime * 3) + 0x1F) * 4, 0x007C);
201
204 }
207}
#define VIRTUAL_TO_PHYSICAL(addr)
DisplayContext * gDisplayContext
Referenced by snaking_static_render().
◆ snaking_static_main()
EffectInstance * snaking_static_main |
( |
s32 | type, |
|
|
f32 | posX, |
|
|
f32 | posY, |
|
|
f32 | posZ, |
|
|
f32 | scale, |
|
|
s32 | timeLeft ) |
Definition at line 12 of file snaking_static.c.
12 {
16 s32 numParts = 22;
17 s32 i;
18
24 effectBp.
effectID = EFFECT_SNAKING_STATIC;
25
28
31
34
35 if (timeLeft <= 0) {
37 } else {
39 }
40
46
50
54
55 data++;
56 for(i = 1; i < numParts; i++, data++) {
58 data->
unk_3C = (i - 1) * 360 / (numParts - 1);
64 }
65
66 return effect;
67
68}
#define general_heap_malloc
#define create_effect_instance
#define ASSERT(condition)
void snaking_static_render(EffectInstance *effect)
void snaking_static_update(EffectInstance *)
void snaking_static_init(EffectInstance *effect)
void(* renderUI)(EffectInstance *effectInst)
void(* init)(EffectInstance *effectInst)
void(* update)(EffectInstance *effectInst)
void(* renderWorld)(EffectInstance *effectInst)
Referenced by lightning_main().
◆ func_E00AE544()
void func_E00AE544 |
( |
void | | ) |
|
◆ D_09001000_3B3D90
◆ D_090010F8_3B3E88