mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2026-04-26 03:51:46 +00:00
Restore proper squish death (#1127)
Some checks are pending
Build coop / build-linux (push) Waiting to run
Build coop / build-steamos (push) Waiting to run
Build coop / build-windows-opengl (push) Waiting to run
Build coop / build-windows-directx (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
Some checks are pending
Build coop / build-linux (push) Waiting to run
Build coop / build-steamos (push) Waiting to run
Build coop / build-windows-opengl (push) Waiting to run
Build coop / build-windows-directx (push) Waiting to run
Build coop / build-macos-arm (push) Waiting to run
Build coop / build-macos-intel (push) Waiting to run
This commit is contained in:
parent
a9f0b5c99c
commit
d0b4c6027d
1 changed files with 11 additions and 5 deletions
|
|
@ -1825,11 +1825,17 @@ s32 act_squished(struct MarioState *m) {
|
|||
if (m->actionTimer >= 15) {
|
||||
// 1 unit of health
|
||||
if (m->health < 0x0100) {
|
||||
//level_trigger_warp(m, WARP_OP_DEATH);
|
||||
// woosh, he's gone!
|
||||
//set_mario_action(m, ACT_DISAPPEARED, 0);
|
||||
drop_and_set_mario_action(m, ACT_DEATH_ON_BACK, 0);
|
||||
m->squishTimer = 0;
|
||||
bool allowDeath = true;
|
||||
smlua_call_event_hooks(HOOK_ON_DEATH, m, &allowDeath);
|
||||
if (!allowDeath) { return FALSE; }
|
||||
|
||||
if (mario_can_bubble(m)) {
|
||||
mario_set_bubbled(m);
|
||||
} else {
|
||||
level_trigger_warp(m, WARP_OP_DEATH);
|
||||
// woosh, he's gone!
|
||||
set_mario_action(m, ACT_DISAPPEARED, 0);
|
||||
}
|
||||
} else if (m->hurtCounter == 0) {
|
||||
// un-squish animation
|
||||
m->squishTimer = 30;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue