mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2024-11-28 23:13:02 +00:00
fix the palette editor hat in hand outside menus (#81)
This commit is contained in:
parent
dc02aa9881
commit
838604a761
2 changed files with 5 additions and 4 deletions
|
@ -10874,7 +10874,7 @@ void cutscene_palette_editor(struct Camera *c) {
|
|||
if (!pressed && m->action != ACT_TAKING_OFF_CAP && m->action != ACT_PUTTING_ON_CAP) {
|
||||
if (m->flags & MARIO_CAP_ON_HEAD) {
|
||||
if (m->action == ACT_IDLE) {
|
||||
set_mario_action(m, ACT_TAKING_OFF_CAP, 0);
|
||||
set_mario_action(m, ACT_TAKING_OFF_CAP, 1); // Add palette editor action arg
|
||||
} else {
|
||||
cutscene_take_cap_off(m);
|
||||
gCamera->paletteEditorCap = true;
|
||||
|
|
|
@ -1882,20 +1882,21 @@ s32 act_putting_on_cap(struct MarioState *m) {
|
|||
}
|
||||
|
||||
// coop custom action
|
||||
// actionArg == 1: the action was inited from CUTSCENE_PALETTE_EDITOR
|
||||
s32 act_taking_off_cap(struct MarioState *m) {
|
||||
s16 animFrame = set_character_animation(m, CHAR_ANIM_TAKE_CAP_OFF_THEN_ON);
|
||||
switch (animFrame) {
|
||||
case 0:
|
||||
if (gCamera->cutscene != CUTSCENE_PALETTE_EDITOR) {
|
||||
if (m->actionArg != 1) {
|
||||
enable_time_stop_if_alone();
|
||||
}
|
||||
break;
|
||||
case 12:
|
||||
cutscene_take_cap_off(m);
|
||||
if (gCamera->cutscene == CUTSCENE_PALETTE_EDITOR) { gCamera->paletteEditorCap = true; }
|
||||
if (m->actionArg == 1) { gCamera->paletteEditorCap = true; }
|
||||
break;
|
||||
default:
|
||||
if (animFrame >= 30) {
|
||||
if (animFrame >= 30 || gCamera->cutscene != CUTSCENE_PALETTE_EDITOR) {
|
||||
set_mario_action(m, ACT_IDLE, 0);
|
||||
disable_time_stop();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue