Fixed exclamation box double item spawning when traffic is bad

This commit is contained in:
MysterD 2020-08-13 18:34:27 -07:00
parent 31904c36bf
commit 90d9e255e4
1 changed files with 11 additions and 8 deletions

View File

@ -71,6 +71,7 @@ void exclamation_box_act_2(void) {
o->oPosY = o->oHomeY;
o->oGraphYOffset = 0.0f;
}
if (o->oExclamationBoxForce || nearest_mario_state_to_object(o) == &gMarioStates[0]) {
if (o->oExclamationBoxForce || o->oExclamationBoxUnkFC == 0x4000 || cur_obj_was_attacked_or_ground_pounded()) {
cur_obj_become_intangible();
o->oExclamationBoxUnkFC = 0x4000;
@ -80,6 +81,7 @@ void exclamation_box_act_2(void) {
o->oAction = 3;
queue_rumble_data(5, 80);
}
}
load_object_collision_model();
}
@ -145,6 +147,7 @@ void exclamation_box_act_4(void) {
}
void exclamation_box_act_5(void) {
o->oExclamationBoxForce = FALSE;
if (o->oTimer > 300)
o->oAction = 2;
}