From cb3c370e33a6db8cac57643c8a7c48bbfa251918 Mon Sep 17 00:00:00 2001 From: VelocitOni Date: Wed, 1 Oct 2025 22:44:56 -0400 Subject: [PATCH 1/6] Bubble wall bounce tumble (does nothing yet) --- src/k_kart.c | 12 ++++++++++++ src/k_kart.h | 1 + 2 files changed, 13 insertions(+) diff --git a/src/k_kart.c b/src/k_kart.c index ed11a8884..f695dafa3 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -14370,6 +14370,18 @@ boolean K_FastFallBounce(player_t *player) return false; } +void K_DappleEmployment(player_t *player) +{ + const boolean JustWallBonked = ((player->mo->eflags & MFE_JUSTBOUNCEDWALL) != 0); // some shit about signed... + const boolean NoMoreBubbleWallHump = ((player->ignoreAirtimeLeniency > 0) && JustWallBonked); + + // No more vertical wall humping + if (NoMoreBubbleWallHump == true) + K_StumblePlayer(player); + + CONS_Printf("ignoreAirtimeLeniency: %d JustWallBonked: %d\n", (player->ignoreAirtimeLeniency), JustWallBonked); +} + static void K_AirFailsafe(player_t *player) { const fixed_t maxSpeed = 6*player->mo->scale; diff --git a/src/k_kart.h b/src/k_kart.h index 056516c1b..9fbf43c29 100644 --- a/src/k_kart.h +++ b/src/k_kart.h @@ -295,6 +295,7 @@ boolean K_PlayerEBrake(const player_t *player); boolean K_PlayerGuard(const player_t *player); SINT8 K_Sliptiding(const player_t *player); boolean K_FastFallBounce(player_t *player); +void K_DappleEmployment(player_t *player); fixed_t K_PlayerBaseFriction(const player_t *player, fixed_t original); void K_AdjustPlayerFriction(player_t *player); void K_MoveKartPlayer(player_t *player, boolean onground); From 5c9730bec8dfe1ae303a537b05db5150aadc2a7f Mon Sep 17 00:00:00 2001 From: VelocitOni Date: Thu, 2 Oct 2025 00:44:52 -0400 Subject: [PATCH 2/6] Make it work Decided to put it in P_BouncePlayerMove, + some flourish --- src/k_kart.c | 19 ++++++++++++++++++- src/p_map.c | 2 ++ 2 files changed, 20 insertions(+), 1 deletion(-) diff --git a/src/k_kart.c b/src/k_kart.c index f695dafa3..a4b8ad9bb 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -14372,14 +14372,31 @@ boolean K_FastFallBounce(player_t *player) void K_DappleEmployment(player_t *player) { + if (player->curshield == KSHIELD_BUBBLE) + { const boolean JustWallBonked = ((player->mo->eflags & MFE_JUSTBOUNCEDWALL) != 0); // some shit about signed... const boolean NoMoreBubbleWallHump = ((player->ignoreAirtimeLeniency > 0) && JustWallBonked); // No more vertical wall humping if (NoMoreBubbleWallHump == true) - K_StumblePlayer(player); + { + + K_AddHitLag(player->mo, 8, false); + S_StartSound(player->mo, sfx_kc52); // Bubble wallbonk noise + + if (player->mo->hitlag > 0) + { + player->mo->spriteyscale *= 3/2; + player->mo->spritexscale *= 2/3; + } + + K_StumblePlayer(player); + S_StopSoundByID(player->mo, sfx_s3k9b); // Avoid stumble crunch noise + + } CONS_Printf("ignoreAirtimeLeniency: %d JustWallBonked: %d\n", (player->ignoreAirtimeLeniency), JustWallBonked); + } } static void K_AirFailsafe(player_t *player) diff --git a/src/p_map.c b/src/p_map.c index c1d0455a0..00336754a 100644 --- a/src/p_map.c +++ b/src/p_map.c @@ -4211,6 +4211,8 @@ static void P_BouncePlayerMove(mobj_t *mo, TryMoveResult_t *result) P_TryMove(mo, mo->x - oldmomx, mo->y - oldmomy, true, NULL); } } + + K_DappleEmployment(mo->player); } // From e64ff44a39444c6e282d5c1ef283f7a77eb6553c Mon Sep 17 00:00:00 2001 From: VelocitOni Date: Thu, 2 Oct 2025 00:56:39 -0400 Subject: [PATCH 3/6] Air failsafe boost prevention AiAi burned to ash --- src/k_kart.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/k_kart.c b/src/k_kart.c index a4b8ad9bb..687bb82fc 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -14391,6 +14391,7 @@ void K_DappleEmployment(player_t *player) } K_StumblePlayer(player); + player->mo->preventfailsafe = TICRATE*3; S_StopSoundByID(player->mo, sfx_s3k9b); // Avoid stumble crunch noise } From ca68ddd35bf5352ed37b4135aec248024b77688e Mon Sep 17 00:00:00 2001 From: Ashnal Date: Sun, 5 Oct 2025 21:59:43 -0400 Subject: [PATCH 4/6] fix incorrect dereference --- src/k_kart.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/k_kart.c b/src/k_kart.c index 687bb82fc..c572a4eea 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -14391,7 +14391,7 @@ void K_DappleEmployment(player_t *player) } K_StumblePlayer(player); - player->mo->preventfailsafe = TICRATE*3; + player->preventfailsafe = TICRATE*3; S_StopSoundByID(player->mo, sfx_s3k9b); // Avoid stumble crunch noise } From f692f5f9e7bb22fea79b66f388e9ef39c0fca2d2 Mon Sep 17 00:00:00 2001 From: Ashnal Date: Sun, 5 Oct 2025 22:04:23 -0400 Subject: [PATCH 5/6] formatting cleanup --- src/k_kart.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/src/k_kart.c b/src/k_kart.c index c572a4eea..5a37a19c7 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -14374,13 +14374,12 @@ void K_DappleEmployment(player_t *player) { if (player->curshield == KSHIELD_BUBBLE) { - const boolean JustWallBonked = ((player->mo->eflags & MFE_JUSTBOUNCEDWALL) != 0); // some shit about signed... - const boolean NoMoreBubbleWallHump = ((player->ignoreAirtimeLeniency > 0) && JustWallBonked); + const boolean JustWallBonked = !!(player->mo->eflags & MFE_JUSTBOUNCEDWALL); // some shit about signed... + const boolean NoMoreBubbleWallHump = (player->ignoreAirtimeLeniency > 0) && JustWallBonked; // No more vertical wall humping - if (NoMoreBubbleWallHump == true) - { - + if (NoMoreBubbleWallHump) + { K_AddHitLag(player->mo, 8, false); S_StartSound(player->mo, sfx_kc52); // Bubble wallbonk noise @@ -14389,14 +14388,12 @@ void K_DappleEmployment(player_t *player) player->mo->spriteyscale *= 3/2; player->mo->spritexscale *= 2/3; } - - K_StumblePlayer(player); - player->preventfailsafe = TICRATE*3; - S_StopSoundByID(player->mo, sfx_s3k9b); // Avoid stumble crunch noise - - } - CONS_Printf("ignoreAirtimeLeniency: %d JustWallBonked: %d\n", (player->ignoreAirtimeLeniency), JustWallBonked); + K_StumblePlayer(player); + player->preventfailsafe = TICRATE*3; + S_StopSoundByID(player->mo, sfx_s3k9b); // Avoid stumble crunch noise + } + CONS_Printf("ignoreAirtimeLeniency: %d JustWallBonked: %d\n", (player->ignoreAirtimeLeniency), JustWallBonked); } } From 9e73292a6731582f83a1ff52c905dd58192ad34e Mon Sep 17 00:00:00 2001 From: Eidolon Date: Mon, 6 Oct 2025 19:15:05 -0500 Subject: [PATCH 6/6] Remove debug print --- src/k_kart.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/k_kart.c b/src/k_kart.c index 5a37a19c7..f35c684c3 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -14393,7 +14393,6 @@ void K_DappleEmployment(player_t *player) player->preventfailsafe = TICRATE*3; S_StopSoundByID(player->mo, sfx_s3k9b); // Avoid stumble crunch noise } - CONS_Printf("ignoreAirtimeLeniency: %d JustWallBonked: %d\n", (player->ignoreAirtimeLeniency), JustWallBonked); } }