Paper Mario DX
Paper Mario (N64) modding
 
Loading...
Searching...
No Matches
f8f60_len_1560.c
Go to the documentation of this file.
1#include "common.h"
2#include "game_modes.h"
3
4// args: start, end, duration, EasingType
5API_CALLABLE(MakeLerp) {
6 Bytecode* ptrReadPos = script->ptrReadPos;
7
8 script->varTable[0xC] = evt_get_variable(script, *ptrReadPos++); // start
9 script->varTable[0xD] = evt_get_variable(script, *ptrReadPos++); // end
10 script->varTable[0xF] = evt_get_variable(script, *ptrReadPos++); // duration
11 script->varTable[0xB] = evt_get_variable(script, *ptrReadPos++); // easing type
12 script->varTable[0xE] = 0; // elapsed
13
14 return ApiStatus_DONE2;
15}
16
17API_CALLABLE(UpdateLerp) {
18 script->varTable[0x0] = (s32) update_lerp(
19 script->varTable[0xB],
20 script->varTable[0xC],
21 script->varTable[0xD],
22 script->varTable[0xE],
23 script->varTable[0xF]
24 );
25
26 if (script->varTable[0xE] >= script->varTable[0xF]) {
27 script->varTable[0x1] = 0; // finished
28 } else {
29 script->varTable[0x1] = 1; // lerping
30 }
31 script->varTable[0xE]++;
32
33 return ApiStatus_DONE2;
34}
35
36API_CALLABLE(RandInt) {
37 Bytecode* args = script->ptrReadPos;
38
39 s32 max = evt_get_variable(script, *args++);
40 Bytecode outVar = *args++;
41
42 evt_set_variable(script, outVar, rand_int(max));
43
44 return ApiStatus_DONE2;
45}
46
47API_CALLABLE(GetAngleBetweenNPCs) {
48 Bytecode* args = script->ptrReadPos;
49
50 s32 aID = evt_get_variable(script, *args++);
51 s32 bID = evt_get_variable(script, *args++);
52 Bytecode outVar = *args++;
53
54 Npc* a = resolve_npc(script, aID);
55 Npc* b = resolve_npc(script, bID);
56 evt_set_variable(script, outVar, atan2(a->pos.x, a->pos.z, b->pos.x, b->pos.z));
57
58 return ApiStatus_DONE2;
59}
60
61API_CALLABLE(GetAngleToNPC) {
62 PlayerStatus* playerStatus = &gPlayerStatus;
63 Bytecode* args = script->ptrReadPos;
64
65 s32 npcID = evt_get_variable(script, *args++);
66 Bytecode outVar = *args++;
67
68 Npc* npc = resolve_npc(script, npcID);
69 evt_set_variable(script, outVar, atan2(playerStatus->pos.x, playerStatus->pos.z, npc->pos.x, npc->pos.z));
70
71 return ApiStatus_DONE2;
72}
73
74API_CALLABLE(GetAngleToPlayer) {
75 PlayerStatus* playerStatus = &gPlayerStatus;
76 Bytecode* args = script->ptrReadPos;
77
78 s32 npcID = evt_get_variable(script, *args++);
79 Bytecode outVar = *args++;
80
81 Npc* npc = resolve_npc(script, npcID);
82 evt_set_variable(script, outVar, atan2(npc->pos.x, npc->pos.z, playerStatus->pos.x, playerStatus->pos.z));
83
84 return ApiStatus_DONE2;
85}
86
87API_CALLABLE(AwaitPlayerApproach) {
88 Bytecode* args = script->ptrReadPos;
89 PlayerStatus* playerStatus = &gPlayerStatus;
90
91 s32* targetX = &script->functionTemp[0];
92 s32* targetZ = &script->functionTemp[1];
93 s32* distanceRequired = &script->functionTemp[2];
94
95 f32 distance;
96
97 if (isInitialCall) {
98 *targetX = evt_get_variable(script, *args++);
99 *targetZ = evt_get_variable(script, *args++);
100 *distanceRequired = evt_get_variable(script, *args++);
101 }
102
103 distance = dist2D(
104 playerStatus->pos.x, playerStatus->pos.z,
105 *targetX, *targetZ
106 );
107
108 if (distance < *distanceRequired) {
109 return ApiStatus_DONE2;
110 } else {
111 return ApiStatus_BLOCK;
112 }
113}
114
115API_CALLABLE(IsPlayerWithin) {
116 Bytecode* args = script->ptrReadPos;
117 PlayerStatus* playerStatus = &gPlayerStatus;
118
119 s32* targetX = &script->functionTemp[0];
120 s32* targetZ = &script->functionTemp[1];
121 s32* distanceRequired = &script->functionTemp[2];
122
123 f32 distance;
124 Bytecode outVar = LVar0;
125
126 if (isInitialCall) {
127 *targetX = evt_get_variable(script, *args++);
128 *targetZ = evt_get_variable(script, *args++);
129 *distanceRequired = evt_get_variable(script, *args++);
130 outVar = *args++;
131 }
132
133 distance = dist2D(
134 playerStatus->pos.x, playerStatus->pos.z,
135 *targetX, *targetZ
136 );
137
138 evt_set_variable(script, outVar, 0);
139 if (distance < *distanceRequired) {
140 evt_set_variable(script, outVar, 1);
141 }
142
143 return ApiStatus_DONE2;
144}
145
146API_CALLABLE(AwaitPlayerLeave) {
147 Bytecode* ptrReadPos = script->ptrReadPos;
148 PlayerStatus* playerStatus = &gPlayerStatus;
149
150 s32* targetX = &script->functionTemp[0];
151 s32* targetZ = &script->functionTemp[1];
152 s32* distanceRequired = &script->functionTemp[2];
153
154 f32 distance;
155
156 if (isInitialCall) {
157 *targetX = evt_get_variable(script, *ptrReadPos++);
158 *targetZ = evt_get_variable(script, *ptrReadPos++);
159 *distanceRequired = evt_get_variable(script, *ptrReadPos++);
160 }
161
162 distance = dist2D(
163 playerStatus->pos.x, playerStatus->pos.z,
164 *targetX, *targetZ
165 );
166
167 if (distance > *distanceRequired) {
168 return ApiStatus_DONE2;
169 } else {
170 return ApiStatus_BLOCK;
171 }
172}
173
174API_CALLABLE(AddVectorPolar) {
175 Bytecode* args = script->ptrReadPos;
176
177 Bytecode xVar = *args++;
178 f32 x = evt_get_float_variable(script, xVar);
179
180 Bytecode yVar = *args++;
181 f32 y = evt_get_float_variable(script, yVar);
182
183 f32 r = evt_get_float_variable(script, *args++);
184
185 add_vec2D_polar(&x, &y, r, evt_get_float_variable(script, *args++));
186
187 evt_set_float_variable(script, xVar, x);
188 evt_set_float_variable(script, yVar, y);
189
190 return ApiStatus_DONE2;
191}
192
193API_CALLABLE(func_802D4BDC) {
194 s32* ready = &script->functionTemp[0];
195 s32* progress = &script->functionTemp[1];
196 s32 t1v;
197
198 if (isInitialCall) {
199 *ready = 0;
200 *progress = 0;
201 }
202
203 // always zero?
204 if (*ready == 0) {
205 t1v = *progress;
206 if (t1v == 255) {
207 return ApiStatus_DONE2;
208 }
209
210 t1v += 10;
211 *progress = t1v;
212 if (t1v > 255) {
213 *progress = 255;
214 }
215
217 }
218
219 return ApiStatus_BLOCK;
220}
221
222API_CALLABLE(func_802D4C4C) {
223 s32* ready = &script->functionTemp[0];
224 s32* progress = &script->functionTemp[1];
225 s32 t1v;
226
227 if (isInitialCall) {
228 *ready = 0;
229 *progress = 255;
230 }
231
232 // always zero?
233 if (*ready == 0) {
234 t1v = *progress;
235 if (t1v == 0) {
237 return ApiStatus_DONE2;
238 }
239 t1v -= 10;
240 *progress = t1v;
241 if (t1v < 0) {
242 *progress = 0;
243 }
245 }
246
247 return ApiStatus_BLOCK;
248}
249
250API_CALLABLE(func_802D4CC4) {
251 Bytecode* args = script->ptrReadPos;
252 s32 value = evt_get_variable(script, *args++);
253
254 if (value < 0) {
256 } else {
258 }
259
260 return ApiStatus_DONE2;
261}
262
263API_CALLABLE(func_802D4D14) {
264 Bytecode* args = script->ptrReadPos;
265 s32 value = evt_get_float_variable(script, *args++);
266
270
271 return ApiStatus_DONE2;
272}
273
274API_CALLABLE(func_802D4D88) {
276 return ApiStatus_DONE2;
277}
278
279void load_path_data(s32 num, f32* normalizedLengths, Vec3f* pathPositions, Vec3f* outVectors) {
280 f32* lenBuf = heap_malloc(num * sizeof(f32));
281 Vec3f* vecBuf = heap_malloc(num * sizeof(Vec3f));
282 s32 i;
283
284 // compute the distance of each vector along the path and map to the range [0,1]
285 normalizedLengths[0] = 0.0f;
286 for (i = 1; i < num; i++) {
287 f32 dx = pathPositions[i].x - pathPositions[i-1].x;
288 f32 dy = pathPositions[i].y - pathPositions[i-1].y;
289 f32 dz = pathPositions[i].z - pathPositions[i-1].z;
290 f32 length = sqrtf(SQ(dx) + SQ(dy) + SQ(dz));
291 normalizedLengths[i] = normalizedLengths[i-1] + length;
292 }
293 for (i = 1; i < num; i++) {
294 normalizedLengths[i] /= normalizedLengths[num-1];
295 }
296
297 // end points
298 outVectors[0].x = 0.0f;
299 outVectors[0].y = 0.0f;
300 outVectors[0].z = 0.0f;
301 outVectors[num-1].x = 0.0f;
302 outVectors[num-1].y = 0.0f;
303 outVectors[num-1].z = 0.0f;
304
305 for (i = 0; i < num - 1; i++) {
306 lenBuf[i] = normalizedLengths[i+1] - normalizedLengths[i];
307 vecBuf[i+1].x = (pathPositions[i+1].x - pathPositions[i].x) / lenBuf[i];
308 vecBuf[i+1].y = (pathPositions[i+1].y - pathPositions[i].y) / lenBuf[i];
309 vecBuf[i+1].z = (pathPositions[i+1].z - pathPositions[i].z) / lenBuf[i];
310 }
311
312 // n = 1
313 outVectors[1].x = vecBuf[2].x - vecBuf[1].x;
314 outVectors[1].y = vecBuf[2].y - vecBuf[1].y;
315 outVectors[1].z = vecBuf[2].z - vecBuf[1].z;
316 vecBuf[1].x = 2.0f * (normalizedLengths[2] - normalizedLengths[0]);
317 vecBuf[1].y = 2.0f * (normalizedLengths[2] - normalizedLengths[0]);
318 vecBuf[1].z = 2.0f * (normalizedLengths[2] - normalizedLengths[0]);
319
320 // 1 < n < N - 2
321 for (i = 1; i < num - 2; i++) {
322 f32 sx = lenBuf[i] / vecBuf[i].x;
323 f32 sy = lenBuf[i] / vecBuf[i].y;
324 f32 sz = lenBuf[i] / vecBuf[i].z;
325 outVectors[i+1].x = (vecBuf[i+2].x - vecBuf[i+1].x) - outVectors[i].x * sx;
326 outVectors[i+1].y = (vecBuf[i+2].y - vecBuf[i+1].y) - outVectors[i].y * sy;
327 outVectors[i+1].z = (vecBuf[i+2].z - vecBuf[i+1].z) - outVectors[i].z * sz;
328 vecBuf[i+1].x = 2.0f * (normalizedLengths[i+2] - normalizedLengths[i]) - lenBuf[i] * sx;
329 vecBuf[i+1].y = 2.0f * (normalizedLengths[i+2] - normalizedLengths[i]) - lenBuf[i] * sy;
330 vecBuf[i+1].z = 2.0f * (normalizedLengths[i+2] - normalizedLengths[i]) - lenBuf[i] * sz;
331 }
332
333 // n = N - 2
334 outVectors[num-2].x -= (lenBuf[num-2] * outVectors[num-1].x);
335 outVectors[num-2].y -= (lenBuf[num-2] * outVectors[num-1].y);
336 outVectors[num-2].z -= (lenBuf[num-2] * outVectors[num-1].z);
337
338 for (i = num - 2; i > 0; i--) {
339 outVectors[i].x = (outVectors[i].x - (lenBuf[i] * outVectors[i+1].x)) / vecBuf[i].x;
340 outVectors[i].y = (outVectors[i].y - (lenBuf[i] * outVectors[i+1].y)) / vecBuf[i].y;
341 outVectors[i].z = (outVectors[i].z - (lenBuf[i] * outVectors[i+1].z)) / vecBuf[i].z;
342 }
343
344 heap_free(lenBuf);
345 heap_free(vecBuf);
346}
347
348void get_path_position(f32 alpha, Vec3f* outPos, s32 numVectors, f32* normalizedLengths, Vec3f* pathPoints, Vec3f* vectors) {
349 s32 limit = numVectors - 1;
350 f32 curLength;
351 f32 curProgress;
352 f32 ax, ay, az, bx, by, bz, dx, dy, dz;
353 s32 i;
354
355 for (i = 0; i < limit;) {
356 s32 temp_v1 = (i + limit) / 2;
357
358 if (normalizedLengths[temp_v1] < alpha) {
359 i = temp_v1 + 1;
360 } else {
361 limit = temp_v1;
362 }
363 }
364
365 if (i > 0) {
366 i--;
367 }
368
369 curLength = normalizedLengths[i+1] - normalizedLengths[i];
370 curProgress = alpha - normalizedLengths[i];
371
372 dx = (pathPoints[i+1].x - pathPoints[i].x) / curLength;
373 ax = (((vectors[i+1].x - vectors[i].x) * curProgress / curLength) + (3.0f * vectors[i].x)) * curProgress;
374 bx = dx - (((2.0f * vectors[i].x) + vectors[i+1].x) * curLength);
375 outPos->x = ((ax + bx) * curProgress) + pathPoints[i].x;
376
377 dy = (pathPoints[i+1].y - pathPoints[i].y) / curLength;
378 ay = (((vectors[i+1].y - vectors[i].y) * curProgress / curLength) + (3.0f * vectors[i].y)) * curProgress;
379 by = dy - (((2.0f * vectors[i].y) + vectors[i+1].y) * curLength);
380 outPos->y = ((ay + by) * curProgress) + pathPoints[i].y;
381
382 dz = (pathPoints[i+1].z - pathPoints[i].z) / curLength;
383 az = (((vectors[i+1].z - vectors[i].z) * curProgress / curLength) + (3.0f * vectors[i].z)) * curProgress;
384 bz = dz - (((2.0f * vectors[i].z) + vectors[i+1].z) * curLength);
385 outPos->z = ((az + bz) * curProgress) + pathPoints[i].z;
386}
387
388API_CALLABLE(LoadPath) {
389 Bytecode* args = script->ptrReadPos;
390 s32 time = evt_get_variable(script, *args++);
391 Vec3f* vectorList = (Vec3f*) evt_get_variable(script, *args++);
392 s32 numVectors = evt_get_variable(script, *args++);
393 s32 easingType = evt_get_variable(script, *args++);
394 Path* path = heap_malloc(sizeof(*path));
395
396 script->varTablePtr[15] = path;
397 path->numVectors = numVectors;
398 path->lengths = heap_malloc(numVectors * sizeof(f32));
399 path->staticVectorList = vectorList;
400 path->vectors = heap_malloc(numVectors * sizeof(Vec3f));
401 load_path_data(path->numVectors, path->lengths, path->staticVectorList, path->vectors);
402
403 path->timeElapsed = 0;
404 path->timeLeft = time - 1;
405 path->easingType = easingType;
406
407 return ApiStatus_DONE2;
408}
409
410API_CALLABLE(GetNextPathPos) {
411 Path* path = script->varTablePtr[0xF];
412 Vec3f pos;
413 f32 alpha;
414 f32 diff;
415
416 switch (path->easingType) {
417 case EASING_LINEAR:
418 alpha = 1.0f / path->timeLeft * path->timeElapsed;
419 break;
421 alpha = 1.0f / SQ(path->timeLeft) * SQ(path->timeElapsed);
422 break;
424 diff = path->timeLeft - path->timeElapsed;
425 alpha = 1.0f - (SQ(diff) / SQ(path->timeLeft));
426 break;
428 alpha = (1.0f - cos_rad((PI / path->timeLeft) * path->timeElapsed)) * 0.5f;
429 break;
430 default:
431 alpha = 0.0f;
432 break;
433 }
434
435 get_path_position(alpha, &pos, path->numVectors, path->lengths, path->staticVectorList, path->vectors);
436 script->varTable[1] = FLOAT_TO_FIXED(pos.x);
437 script->varTable[2] = FLOAT_TO_FIXED(pos.y);
438 script->varTable[3] = FLOAT_TO_FIXED(pos.z);
439
440 if (path->timeElapsed < path->timeLeft) {
441 path->timeElapsed = path->timeElapsed + 1;
442 script->varTable[0] = 1;
443 } else {
444 heap_free(path->lengths);
445 heap_free(path->vectors);
446 heap_free(script->varTablePtr[15]);
447 script->varTable[0] = 0;
448 }
449
450 return ApiStatus_DONE2;
451}
452
453API_CALLABLE(GetDist2D) {
454 Bytecode* args = script->ptrReadPos;
455 Bytecode outVar = *args++;
456 f32 ax = evt_get_float_variable(script, *args++);
457 f32 ay = evt_get_float_variable(script, *args++);
458 f32 bx = evt_get_float_variable(script, *args++);
459 f32 by = evt_get_float_variable(script, *args++);
460
461 evt_set_float_variable(script, outVar, dist2D(ax, ay, bx, by));
462
463 return ApiStatus_DONE2;
464}
465
466//TODO code split? math_api from ???
467
468API_CALLABLE(SetTimeFreezeMode) {
469 Bytecode* args = script->ptrReadPos;
470
471 set_time_freeze_mode(evt_get_variable(script, *args++));
472 return ApiStatus_DONE2;
473}
474
475API_CALLABLE(ModifyGlobalOverrideFlags) {
476 Bytecode* args = script->ptrReadPos;
477 s32 setMode = evt_get_variable(script, *args++);
478 s32 flags = evt_get_variable(script, *args++);
479
480 if (setMode) {
482 } else {
483 gOverrideFlags &= ~flags;
484 }
485
486 return ApiStatus_DONE2;
487}
488
489API_CALLABLE(SetValueByRef) {
490 Bytecode* args = script->ptrReadPos;
491
492 s32 dest = evt_get_variable(script, *args++); /* Reference */
493 s32 src = evt_get_variable(script, *args++);
494 evt_set_variable(script, dest, src);
495
496 return ApiStatus_DONE2;
497}
498
499API_CALLABLE(GetValueByRef) {
500 Bytecode* args = script->ptrReadPos;
501 s32 src = evt_get_variable(script, *args++); /* Reference */
502 Bytecode dest = *args++;
503
504 evt_set_variable(script, dest, evt_get_variable(script, src));
505
506 return ApiStatus_DONE2;
507}
508
509API_CALLABLE(EnableWorldStatusBar) {
510 Bytecode* args = script->ptrReadPos;
511 b32 shouldEnable = evt_get_variable(script, *args++);
512
513 if (shouldEnable) {
515 } else {
517 }
518
519 return ApiStatus_DONE2;
520}
521
522API_CALLABLE(ShowWorldStatusBar) {
523 Bytecode* args = script->ptrReadPos;
524 b32 shouldShow = evt_get_variable(script, *args++);
525
526 if (shouldShow) {
529 } else {
531 }
532
533 return ApiStatus_DONE2;
534}
535
536API_CALLABLE(SetGameMode) {
537 Bytecode* args = script->ptrReadPos;
538 s16 mode = evt_get_variable(script, *args++);
539
540 set_game_mode(mode);
541
542 return ApiStatus_DONE2;
543}
544
545API_CALLABLE(ClampAngleInt) {
546 Bytecode* args = script->ptrReadPos;
547 s32 angle = evt_get_variable(script, *args);
548
549 evt_set_variable(script, *args++, clamp_angle(angle));
550
551 return ApiStatus_DONE2;
552}
553
554API_CALLABLE(ClampAngleFloat) {
555 Bytecode* args = script->ptrReadPos;
556 f32 angle = evt_get_float_variable(script, *args);
557
558 evt_set_float_variable(script, *args++, clamp_angle(angle));
559
560 return ApiStatus_DONE2;
561}
562
563#if VERSION_PAL
564API_CALLABLE(GetLanguage) {
565 Bytecode* args = script->ptrReadPos;
566
567 evt_set_variable(script, *args++, gCurrentLanguage);
568 return ApiStatus_DONE2;
569}
570#endif
Vec3f * vectors
s32 numVectors
s32 timeElapsed
s32 b32
s32 easingType
Vec3f * staticVectorList
f32 * lengths
s8 flags
Definition demo_api.c:15
Vec3s pos
Definition demo_api.c:17
#define sqrtf
#define rand_int
#define clamp_angle
#define atan2
@ OVERLAY_NONE
Definition enums.h:2387
@ OVERLAY_BLUR
Definition enums.h:2400
@ OVERLAY_START_BATTLE
Definition enums.h:2398
@ SCREEN_LAYER_FRONT
Definition enums.h:2382
@ EASING_QUADRATIC_IN
Definition enums.h:511
@ EASING_COS_IN_OUT
Definition enums.h:520
@ EASING_QUADRATIC_OUT
Definition enums.h:514
@ EASING_LINEAR
Definition enums.h:510
#define ApiStatus_DONE2
Definition evt.h:118
s32 Bytecode
Definition evt.h:7
#define ApiStatus_BLOCK
Definition evt.h:116
void get_path_position(f32 alpha, Vec3f *outPos, s32 numVectors, f32 *normalizedLengths, Vec3f *pathPoints, Vec3f *vectors)
void load_path_data(s32 num, f32 *normalizedLengths, Vec3f *pathPositions, Vec3f *outVectors)
void set_screen_overlay_params_back(u8, f32)
s32 evt_get_variable(Evt *script, Bytecode var)
Definition evt.c:1690
f32 update_lerp(s32 easing, f32 start, f32 end, s32 elapsed, s32 duration)
Definition 43F0.c:735
void status_bar_ignore_changes(void)
Definition inventory.c:1497
void decrement_status_bar_disabled(void)
Definition inventory.c:1646
f32 evt_set_float_variable(Evt *script, Bytecode var, f32 value)
Definition evt.c:1977
s32 evt_set_variable(Evt *script, Bytecode var, s32 value)
Definition evt.c:1847
void set_screen_overlay_params_front(u8, f32)
f32 cos_rad(f32 x)
Definition 43F0.c:717
void close_status_bar(void)
Definition inventory.c:1440
f32 dist2D(f32 ax, f32 ay, f32 bx, f32 by)
Definition 43F0.c:670
s32 heap_free(void *ptr)
Definition heap.c:42
void set_screen_overlay_center(s32, s32, s32, s32)
Npc * resolve_npc(Evt *script, s32 npcIdOrPtr)
Definition npc_api.c:8
f32 evt_get_float_variable(Evt *script, Bytecode var)
Definition evt.c:1930
void set_time_freeze_mode(s32)
Time freeze modes: 0: none 1: NPCs move, can't be interacted with 2: NPCs don't move,...
Definition main_loop.c:358
void add_vec2D_polar(f32 *x, f32 *y, f32 r, f32 theta)
Definition 43F0.c:685
void * heap_malloc(s32 size)
Definition heap.c:34
void status_bar_respond_to_changes(void)
Definition inventory.c:1508
void increment_status_bar_disabled(void)
Definition inventory.c:1654
void set_game_mode(s32 modeID)
Definition game_modes.c:127
ApiStatus EnableWorldStatusBar(Evt *script, b32 isInitialCall)
ApiStatus SetTimeFreezeMode(Evt *script, b32 isInitialCall)
ApiStatus ModifyGlobalOverrideFlags(Evt *script, b32 isInitialCall)
ApiStatus AddVectorPolar(Evt *script, b32 isInitialCall)
ApiStatus GetAngleToPlayer(Evt *script, b32 isInitialCall)
ApiStatus ClampAngleInt(Evt *script, b32 isInitialCall)
ApiStatus AwaitPlayerLeave(Evt *script, b32 isInitialCall)
ApiStatus GetDist2D(Evt *script, b32 isInitialCall)
ApiStatus GetAngleToNPC(Evt *script, b32 isInitialCall)
ApiStatus UpdateLerp(Evt *script, b32 isInitialCall)
ApiStatus AwaitPlayerApproach(Evt *script, b32 isInitialCall)
ApiStatus func_802D4D14(Evt *script, b32 isInitialCall)
ApiStatus ShowWorldStatusBar(Evt *script, b32 isInitialCall)
ApiStatus func_802D4CC4(Evt *script, b32 isInitialCall)
ApiStatus func_802D4BDC(Evt *script, b32 isInitialCall)
ApiStatus ClampAngleFloat(Evt *script, b32 isInitialCall)
ApiStatus SetValueByRef(Evt *script, b32 isInitialCall)
ApiStatus GetAngleBetweenNPCs(Evt *script, b32 isInitialCall)
ApiStatus IsPlayerWithin(Evt *script, b32 isInitialCall)
ApiStatus SetGameMode(Evt *script, b32 isInitialCall)
ApiStatus RandInt(Evt *script, b32 isInitialCall)
ApiStatus LoadPath(Evt *script, b32 isInitialCall)
ApiStatus func_802D4D88(Evt *script, b32 isInitialCall)
ApiStatus MakeLerp(Evt *script, b32 isInitialCall)
ApiStatus GetValueByRef(Evt *script, b32 isInitialCall)
ApiStatus GetNextPathPos(Evt *script, b32 isInitialCall)
ApiStatus func_802D4C4C(Evt *script, b32 isInitialCall)
#define FLOAT_TO_FIXED(x)
Progammatically converts f32 --> Float.
Definition macros.h:57
#define PI
Definition macros.h:126
#define SQ(x)
Definition macros.h:166
#define LVar0
Definition macros.h:148
Vec3f pos
s32 gOverrideFlags
Definition main_loop.c:11
#define gCurrentLanguage
Definition variables.h:115
PlayerStatus gPlayerStatus
Definition 77480.c:39