mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2025-10-30 08:01:01 +00:00
Synchronize burning player smoke + misc version improvements
This commit is contained in:
parent
b7cf6cdf5c
commit
229880cfda
4 changed files with 23 additions and 12 deletions
|
|
@ -53,7 +53,7 @@ void bhv_bbh_tilting_trap_platform_loop(void) {
|
||||||
|
|
||||||
if (o->oAction == BBH_TILTING_TRAP_PLATFORM_ACT_MARIO_ON) {
|
if (o->oAction == BBH_TILTING_TRAP_PLATFORM_ACT_MARIO_ON) {
|
||||||
#else
|
#else
|
||||||
if (gMarioObject->platform == o) {
|
if (cur_obj_is_any_player_on_platform()) {
|
||||||
#endif
|
#endif
|
||||||
o->oAngleVelPitch = (s32)(distanceToPlayer * coss(angleToPlayer));
|
o->oAngleVelPitch = (s32)(distanceToPlayer * coss(angleToPlayer));
|
||||||
o->oFaceAnglePitch += o->oAngleVelPitch;
|
o->oFaceAnglePitch += o->oAngleVelPitch;
|
||||||
|
|
|
||||||
|
|
@ -93,17 +93,17 @@ void dorrie_act_lower_head(void) {
|
||||||
if (cur_obj_init_anim_check_frame(2, 35)) {
|
if (cur_obj_init_anim_check_frame(2, 35)) {
|
||||||
cur_obj_reverse_animation();
|
cur_obj_reverse_animation();
|
||||||
|
|
||||||
#ifdef VERSION_JP
|
/*#ifdef VERSION_JP
|
||||||
if (o->oTimer > 150) {
|
if (o->oTimer > 150) {
|
||||||
dorrie_begin_head_raise(FALSE);
|
dorrie_begin_head_raise(FALSE);
|
||||||
} else if (gMarioObject->platform == o) {
|
} else if (cur_obj_is_any_player_on_platform()) {
|
||||||
if (o->oDorrieForwardDistToMario > 830.0f && set_mario_npc_dialog(&gMarioStates[0], 2, dorrie_act_lower_head_continue_dialog) == 1) {
|
if (o->oDorrieForwardDistToMario > 830.0f && set_mario_npc_dialog(&gMarioStates[0], 2, dorrie_act_lower_head_continue_dialog) == 1) {
|
||||||
dorrie_begin_head_raise(TRUE);
|
dorrie_begin_head_raise(TRUE);
|
||||||
} else if (o->oDorrieForwardDistToMario > 320.0f) {
|
} else if (o->oDorrieForwardDistToMario > 320.0f) {
|
||||||
o->oTimer = 0;
|
o->oTimer = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#else
|
#else*/
|
||||||
if (cur_obj_is_any_player_on_platform()) {
|
if (cur_obj_is_any_player_on_platform()) {
|
||||||
if (gMarioStates[0].marioObj->platform == o
|
if (gMarioStates[0].marioObj->platform == o
|
||||||
&& o->oDorrieOffsetY == -17.0f && distanceToLocalPlayer > 780.0f
|
&& o->oDorrieOffsetY == -17.0f && distanceToLocalPlayer > 780.0f
|
||||||
|
|
@ -116,7 +116,7 @@ void dorrie_act_lower_head(void) {
|
||||||
} else if (o->oTimer > 150) {
|
} else if (o->oTimer > 150) {
|
||||||
dorrie_begin_head_raise(FALSE);
|
dorrie_begin_head_raise(FALSE);
|
||||||
}
|
}
|
||||||
#endif
|
//#endif
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
o->oDorrieNeckAngle += 0x115;
|
o->oDorrieNeckAngle += 0x115;
|
||||||
|
|
|
||||||
|
|
@ -112,6 +112,7 @@ void exclamation_box_act_3(void) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void exclamation_box_spawn_contents(struct Struct802C0DF0 *a0, u8 a1) {
|
void exclamation_box_spawn_contents(struct Struct802C0DF0 *a0, u8 a1) {
|
||||||
|
struct Object* player = nearest_player_to_object(o);
|
||||||
struct Object *sp1C = NULL;
|
struct Object *sp1C = NULL;
|
||||||
|
|
||||||
if (o->oExclamationBoxForce) {
|
if (o->oExclamationBoxForce) {
|
||||||
|
|
@ -123,7 +124,7 @@ void exclamation_box_spawn_contents(struct Struct802C0DF0 *a0, u8 a1) {
|
||||||
sp1C = spawn_object(o, a0->model, a0->behavior);
|
sp1C = spawn_object(o, a0->model, a0->behavior);
|
||||||
sp1C->oVelY = 20.0f;
|
sp1C->oVelY = 20.0f;
|
||||||
sp1C->oForwardVel = 3.0f;
|
sp1C->oForwardVel = 3.0f;
|
||||||
sp1C->oMoveAngleYaw = gMarioObject->oMoveAngleYaw;
|
sp1C->oMoveAngleYaw = player->oMoveAngleYaw;
|
||||||
o->oBehParams |= a0->unk2 << 24;
|
o->oBehParams |= a0->unk2 << 24;
|
||||||
if (a0->model == 122)
|
if (a0->model == 122)
|
||||||
o->oFlags |= 0x4000;
|
o->oFlags |= 0x4000;
|
||||||
|
|
|
||||||
|
|
@ -16,10 +16,15 @@ void bhv_black_smoke_bowser_loop(void) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void bhv_black_smoke_mario_loop(void) {
|
void bhv_black_smoke_mario_loop(void) {
|
||||||
|
if (o->parentObj == NULL) {
|
||||||
|
obj_mark_for_deletion(o);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (o->oTimer == 0) {
|
if (o->oTimer == 0) {
|
||||||
cur_obj_set_pos_relative(gMarioObject, 0, 0, -30.0f);
|
cur_obj_set_pos_relative(o->parentObj, 0, 0, -30.0f);
|
||||||
o->oForwardVel = random_float() * 2 + 0.5;
|
o->oForwardVel = random_float() * 2 + 0.5;
|
||||||
o->oMoveAngleYaw = (gMarioObject->oMoveAngleYaw + 0x7000) + random_float() * 8192.0f;
|
o->oMoveAngleYaw = (o->parentObj->oMoveAngleYaw + 0x7000) + random_float() * 8192.0f;
|
||||||
o->oVelY = 8;
|
o->oVelY = 8;
|
||||||
}
|
}
|
||||||
o->oMoveAngleYaw += o->oAngleVelYaw;
|
o->oMoveAngleYaw += o->oAngleVelYaw;
|
||||||
|
|
@ -27,15 +32,20 @@ void bhv_black_smoke_mario_loop(void) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void bhv_flame_mario_loop(void) {
|
void bhv_flame_mario_loop(void) {
|
||||||
|
if (o->parentObj == NULL || o->parentObj->behavior != bhvMario) {
|
||||||
|
obj_mark_for_deletion(o);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
cur_obj_scale(2.0f);
|
cur_obj_scale(2.0f);
|
||||||
if (o->oTimer != 0)
|
if (o->oTimer != 0)
|
||||||
if (o->oTimer & 1)
|
if (o->oTimer & 1)
|
||||||
spawn_object(o, MODEL_BURN_SMOKE, bhvBlackSmokeMario);
|
spawn_object(o->parentObj, MODEL_BURN_SMOKE, bhvBlackSmokeMario);
|
||||||
gMarioObject->prevObj = o; // weird?
|
o->parentObj->prevObj = o; // weird?
|
||||||
obj_set_parent_relative_pos(o, 40, -120, 0);
|
obj_set_parent_relative_pos(o, 40, -120, 0);
|
||||||
if (!(gMarioObject->oMarioParticleFlags & 0x800)) {
|
if (!(o->parentObj->oMarioParticleFlags & 0x800)) {
|
||||||
o->parentObj->oActiveParticleFlags &= ~0x800;
|
o->parentObj->oActiveParticleFlags &= ~0x800;
|
||||||
obj_mark_for_deletion(o);
|
obj_mark_for_deletion(o);
|
||||||
gMarioObject->prevObj = NULL;
|
o->parentObj->prevObj = NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue