Update z_player.c

This commit is contained in:
MegaMech 2022-03-27 17:19:16 -07:00 committed by GitHub
commit a612f73953
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -487,6 +487,9 @@ static s16 D_80853610 = 0;
static s32 D_80853614 = 0;
static s32 D_80853618 = 0;
static s32 sNoClip = false;
static s32 sLastNoClip = false;
static u16 D_8085361C[] = {
NA_SE_VO_LI_SWEAT,
NA_SE_VO_LI_SNEEZE,
@ -13129,10 +13132,18 @@ void func_8084FBF4(Player* this, GlobalContext* globalCtx) {
s32 func_8084FCAC(Player* this, GlobalContext* globalCtx) {
sControlInput = &globalCtx->state.input[0];
if (CVar_GetS32("gDebugEnabled", 0) && ((CHECK_BTN_ALL(sControlInput->cur.button, BTN_A | BTN_L | BTN_R) &&
s32 clip = CVar_GetS32("SV_NOCLIP", 1);
if (clip != sLastNoClip) {
sLastNoClip = clip;
sNoClip = true;
}
if ((CVar_GetS32("gDebugEnabled", 0) && (sNoClip))) || ((CHECK_BTN_ALL(sControlInput->cur.button, BTN_A | BTN_L | BTN_R) &&
CHECK_BTN_ALL(sControlInput->press.button, BTN_B)) ||
(CHECK_BTN_ALL(sControlInput->cur.button, BTN_L) && CHECK_BTN_ALL(sControlInput->press.button, BTN_DRIGHT)))) {
sNoClip = false;
D_808535D0 ^= 1;
if (D_808535D0) {
@ -14806,4 +14817,4 @@ void func_80853148(GlobalContext* globalCtx, Actor* actor) {
this->naviActor->flags |= ACTOR_FLAG_8;
func_80835EA4(globalCtx, 0xB);
}
}
}