Function and Enum Naming
Enum Changes: BSGROUP_4_LOOK = 0x4 MISC_FLAG_17_FPV = 0x17 Moved nc_first_person_state to global enums.h Function names: func_8028EE84() -> player_getWaterState() func_8028B2E8() -> player_isStable() func_80294F78() -> should_look_first_person_camera() func_80294F78() -> can_view_first_person() func_8028B424() -> player_isFallTumbling() func_8029C780() -> bs_getTypeOfJump() func_8028DB14() -> hitbox_getHitboxForActor()
This commit is contained in:
@@ -130,7 +130,7 @@ s32 func_802C11C8(f32 arg0[3]) {
|
||||
|
||||
sp2C = func_802C0EC0();
|
||||
func_802C0FF4(sp4C);
|
||||
if (func_8028EE84() == BSWATERGROUP_2_UNDERWATER) {
|
||||
if (player_getWaterState() == BSWATERGROUP_2_UNDERWATER) {
|
||||
func_802BD82C(20.0f, 200.0f);
|
||||
} else {
|
||||
func_802BD82C(80.0f, 200.0f);
|
||||
@@ -226,7 +226,7 @@ void func_802C16CC(s32 arg0) {
|
||||
s32 sp34;
|
||||
s16 *sp30;
|
||||
|
||||
if ((func_8028ECAC() != 4) && !__is_flying_in_FP()){
|
||||
if ((func_8028ECAC() != BSGROUP_4_LOOK) && !__is_flying_in_FP()){
|
||||
sp38 = func_80334524(arg0);
|
||||
if(sp38 != D_8037DBE0.unk28 && D_8037DBE0.unk28 != -1){
|
||||
player_getPosition(sp54);
|
||||
|
@@ -531,7 +531,7 @@ void func_802BD3CC(f32 arg0[3]) {
|
||||
|
||||
player_getPosition(arg0);
|
||||
sp2C = func_8028E82C();
|
||||
if ((func_8028F2FC() != 0) && (func_8028EE84() != BSWATERGROUP_2_UNDERWATER) && (player_getTransformation() == TRANSFORM_1_BANJO)) {
|
||||
if ((func_8028F2FC() != 0) && (player_getWaterState() != BSWATERGROUP_2_UNDERWATER) && (player_getTransformation() == TRANSFORM_1_BANJO)) {
|
||||
temp_f0 = func_8028EF88();
|
||||
temp_f2 = temp_f0 - 500.0f;
|
||||
sp2C = ml_map_f(arg0[1], temp_f0 - 80.0f, temp_f2, temp_f0, temp_f2);
|
||||
@@ -991,11 +991,11 @@ void func_802BE894(f32 position[3], f32 rotation[3]){
|
||||
|
||||
void ncDynamicCamera_enterFirstPerson(void){
|
||||
dynamicCameraInFirstPerson = TRUE;
|
||||
ncFirstPersonCamera_setState(1);
|
||||
ncFirstPersonCamera_setState(FIRSTPERSON_STATE_1_ENTER);
|
||||
ncFirstPersonCamera_setZoomedOutPosition(cameraPosition);
|
||||
ncFirstPersonCamera_setZoomedOutRotation(cameraRotation);
|
||||
}
|
||||
|
||||
void ncDynamicCamera_exitFirstPerson(void){
|
||||
ncFirstPersonCamera_setState(3);
|
||||
ncFirstPersonCamera_setState(FIRSTPERSON_STATE_3_EXIT);
|
||||
}
|
||||
|
@@ -6,14 +6,6 @@
|
||||
extern void func_802BD780(f32[3], f32[3], f32, f32, f32, f32);
|
||||
extern f32 func_80257CF8(f32, f32, f32, f32, f32);
|
||||
|
||||
|
||||
enum nc_first_person_state{
|
||||
FIRSTPERSON_STATE_1_ENTER = 1,
|
||||
FIRSTPERSON_STATE_2_IDLE,
|
||||
FIRSTPERSON_STATE_3_EXIT,
|
||||
FIRSTPERSON_STATE_4_DONE,
|
||||
};
|
||||
|
||||
void ncFirstPersonCamera_setState(enum nc_first_person_state state);
|
||||
|
||||
/* .bss */
|
||||
@@ -42,7 +34,7 @@ void __ncFirstPersonCamera_getPositionAndRotation_entering(f32 arg0[3], f32 arg1
|
||||
D_8037DC60.rotation[i] = mlNormalizeAngle(D_8037DC60.zoomed_out_rotation[i] + func_80257CF8(D_8037DC60.transistion_timer, 0.5f, 0.0f, 0.0f, mlDiffDegF(D_8037DC60.zoomed_in_rotation[i], D_8037DC60.zoomed_out_rotation[i])));
|
||||
}
|
||||
if (D_8037DC60.transistion_timer == 0.0f) {
|
||||
ncFirstPersonCamera_setState(2);
|
||||
ncFirstPersonCamera_setState(FIRSTPERSON_STATE_2_IDLE);
|
||||
}
|
||||
if (__ncFirstPersonCamera_fullyZoomedIn() && func_8028F150()) {
|
||||
func_8028FCC8(0);
|
||||
@@ -61,7 +53,7 @@ void __ncFirstPersonCamera_getPositionAndRotation_exiting(f32 arg0[3], f32 arg1[
|
||||
D_8037DC60.rotation[i] = mlNormalizeAngle(D_8037DC60.zoomed_in_rotation[i] + func_80257CF8(D_8037DC60.transistion_timer, 1.0f, 0.5f, 0.0f, mlDiffDegF(arg1[i], D_8037DC60.zoomed_in_rotation[i])));
|
||||
}
|
||||
if (D_8037DC60.transistion_timer == 0.0f) {
|
||||
ncFirstPersonCamera_setState(4);
|
||||
ncFirstPersonCamera_setState(FIRSTPERSON_STATE_4_DONE);
|
||||
}
|
||||
if (!__ncFirstPersonCamera_fullyZoomedIn() && !func_8028F150()) {
|
||||
func_8028FCC8(1);
|
||||
|
Reference in New Issue
Block a user