Paper Mario DX
Paper Mario (N64) modding
 
Loading...
Searching...
No Matches
UnkFunc12.inc.c
Go to the documentation of this file.
1#include "common.h"
2#include "npc.h"
3
4API_CALLABLE(N(UnkFunc12)) {
5 PlayerStatus* playerStatus = &gPlayerStatus;
6 f32 posX, posY, posZ, hitDepth;
7
8 if (script->varTable[5] == 0) {
9 playerStatus->pos.x = script->varTable[0];
10 } else {
11 playerStatus->pos.z = script->varTable[0];
12 }
13
14 posX = playerStatus->pos.x;
15 posY = playerStatus->pos.y + 10.0f;
16 posZ = playerStatus->pos.z;
17 hitDepth = 40.0f;
18
19 npc_raycast_down_sides(0, &posX, &posY, &posZ, &hitDepth);
20
21 playerStatus->pos.x = posX;
22 playerStatus->pos.y = posY;
23 playerStatus->pos.z = posZ;
24
25 return ApiStatus_DONE2;
26}
#define npc_raycast_down_sides
#define ApiStatus_DONE2
Definition evt.h:118
PlayerStatus gPlayerStatus
Definition 77480.c:39