diff --git a/README.md b/README.md index 69cd1a14..f5a45825 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,7 @@ This is a fork of the ultrasm64 repo by CrashOveride which includes the followin - Tighter hanging controls (mario will face the direction of the analog stick directly while hanging from a ceiling) * - reonucam3: custom camera by me. This is included as a .patch file in the enhancements folder, you need to apply it if you want this camera. This video shows a rundown of the features: https://youtu.be/TQNkznX9Z3k +- Ability to disable Mario getting suck in snow or sand **Hacker QOL:** - Global, non-level based, star IDs (off by default) * diff --git a/include/config.h b/include/config.h index eaae6a13..31a0bdec 100644 --- a/include/config.h +++ b/include/config.h @@ -82,6 +82,8 @@ #define NO_FALL_DAMAGE // Disables the scream that mario makes when falling off a great height (this is separate from actual fall damage) //#define NO_FALL_DAMAGE_SOUND +// Disables Mario getting stuck in snow and sand when falling +//#define NO_GETTING_BURIED // Number of coins to spawn the "100 coin" star. If you remove the define altogether, then there won't be a 100 coin star at all. #define X_COIN_STAR 100 // Platform displacement 2 also known as momentum patch. Makes Mario keep the momemtum from moving platforms. Doesn't break treadmills anymore! diff --git a/src/game/mario_actions_airborne.c b/src/game/mario_actions_airborne.c index ce6467ef..c037e87a 100644 --- a/src/game/mario_actions_airborne.c +++ b/src/game/mario_actions_airborne.c @@ -123,6 +123,9 @@ s32 should_get_stuck_in_ground(struct MarioState *m) { s32 flags = floor->flags; s32 type = floor->type; +#ifdef NO_GETTING_BURIED + return FALSE; +#else if (floor != NULL && (terrainType == TERRAIN_SNOW || terrainType == TERRAIN_SAND) && type != SURFACE_BURNING && SURFACE_IS_NOT_HARD(type)) { if (!(flags & 0x01) && m->peakHeight - m->pos[1] > 1000.0f && floor->normal.y >= 0.8660254f) { @@ -131,6 +134,7 @@ s32 should_get_stuck_in_ground(struct MarioState *m) { } return FALSE; +#endif } s32 check_fall_damage_or_get_stuck(struct MarioState *m, u32 hardFallAction) {