fae0beef创建于 7月26日历史提交
// BanjoDecomp: core2/playerposition.c
#include <ultra64.h>
#include "functions.h"
#include "variables.h"

/* .bss */
f32 player_position[3];
f32 D_8037C5B0[3]; //player_ideal position?
f32 D_8037C5C0[3]; //player_position_offset

/* .code */
void playerPosition_init(void){
    ml_vec3f_clear(D_8037C5C0);
    ml_vec3f_clear(player_position);
    ml_vec3f_clear(D_8037C5B0);
}

void playerPosition_func_8029842C(void){
    ml_vec3f_copy(D_8037C5B0, player_position);
    ml_vec3f_clear(D_8037C5C0);
}

void playerPosition_func_80298464(f32 arg0[3]){
    ml_vec3f_copy(player_position, arg0);
    ml_vec3f_copy(D_8037C5B0, arg0);
}

void playerPosition_set(f32 arg0[3]){
    ml_vec3f_copy(player_position, arg0);
}

void playerPosition_setY(f32 arg0){
    player_position[1] = arg0;
}

void playerPosition_get(f32 arg0[3]){
    ml_vec3f_copy(arg0, player_position);
}

f32 playerPosition_getY(void){
    return player_position[1];
}

void playerPosition_func_80298504(f32 arg0[3]){
    ml_vec3f_copy(arg0, D_8037C5B0);
}

void playerPosition_addY(f32 arg0){
    player_position[1] += arg0;
}

void playerPosition_getOffset(f32 arg0[3]){
    ml_vec3f_copy(arg0, D_8037C5C0);
}

void playerPosition_setOffset(f32 arg0[3]){
    ml_vec3f_copy(D_8037C5C0, arg0);
}

void playerPosition_applyOffset(void){
    player_position[0] += D_8037C5C0[0];
    player_position[1] += D_8037C5C0[1];
    player_position[2] += D_8037C5C0[2];
    ml_vec3f_clear(D_8037C5C0);

}