From 82b35a0036e6326b9a8f57aa8314f96a93aa40d6 Mon Sep 17 00:00:00 2001 From: Reonu Date: Mon, 21 Jun 2021 17:35:28 +0100 Subject: [PATCH] added jump kick fix --- include/config.h | 2 ++ src/game/mario.c | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/include/config.h b/include/config.h index eaf066e3..d39c14e5 100644 --- a/include/config.h +++ b/include/config.h @@ -67,6 +67,8 @@ #define INSTANT_WARP_OFFSET_FIX // Allows Mario to ledgegrab sloped floors #define NO_FALSE_LEDGEGRABS +// Allows Mario to jump kick on steep surfaces that are set to be non slippery, instead of being forced to dive +#define JUMP_KICK_FIX // Uncomment this if you want global star IDs (useful for creating an open world hack ala MVC) //#define GLOBAL_STAR_IDS // Uncomment this if you want to skip the title screen (Super Mario 64 logo) diff --git a/src/game/mario.c b/src/game/mario.c index 30706134..597ddc8d 100644 --- a/src/game/mario.c +++ b/src/game/mario.c @@ -639,6 +639,11 @@ s32 mario_floor_is_steep(struct MarioState *m) { f32 normY; s32 result = FALSE; +#ifdef JUMP_KICK_FIX + if (m->floor->type == SURFACE_NOT_SLIPPERY) + return FALSE; +#endif + // Interestingly, this function does not check for the // slide terrain type. This means that steep behavior persists for // non-slippery and slippery surfaces.