diff --git a/src/k_collide.c b/src/k_collide.c index b6c1b6da0..9bbf3955d 100644 --- a/src/k_collide.c +++ b/src/k_collide.c @@ -548,7 +548,7 @@ static void K_BubbleShieldCollideDrain(player_t *player, mobj_t *bubble, INT16 d // Apply a cooldown if the Bubble Shield took damage without shattering. if ((player->bubblehealth > 0) && (dmg > 0)) - player->bubbleblowup = 0; + player->bubbleblowup /= 2; } static boolean K_BubbleReflectingTrapItem(const mobj_t *t) diff --git a/src/k_kart.c b/src/k_kart.c index bed9d3960..e9266797e 100644 --- a/src/k_kart.c +++ b/src/k_kart.c @@ -485,7 +485,8 @@ static fixed_t K_PlayerWeight(mobj_t *mobj, mobj_t *against) if (against && !P_MobjWasRemoved(against) && against->player && ((!P_PlayerInPain(against->player) && P_PlayerInPain(mobj->player)) // You're hurt - || (K_GetShieldFromPlayer(against->player) == KSHIELD_BUBBLE && K_GetShieldFromPlayer(mobj->player) != KSHIELD_BUBBLE))) // They have a Bubble Shield + || (K_GetShieldFromPlayer(against->player) == KSHIELD_BUBBLE // They have a Bubble Shield + && K_GetShieldFromPlayer(mobj->player) != KSHIELD_BUBBLE))) // and you don't { weight = 0; // This player does not cause any bump action } @@ -497,7 +498,7 @@ static fixed_t K_PlayerWeight(mobj_t *mobj, mobj_t *against) weight = (mobj->player->kartweight) * FRACUNIT; - if (K_GetShieldFromPlayer(mobj->player) == KSHIELD_BUBBLE) + if (K_GetShieldFromPlayer(mobj->player) == KSHIELD_BUBBLE && mobj->player->bubblecool == 0) { weight = max(BUBBLEMINWEIGHT, weight); weight = FixedMul(weight, FRACUNIT/16); @@ -766,7 +767,7 @@ boolean K_KartBouncing(mobj_t *mobj1, mobj_t *mobj2, boolean bounce, boolean sol p1shield = K_GetShieldFromPlayer(mobj1->player); // Moved here so it only fires once on bump. - if (p1shield == KSHIELD_BUBBLE) + if (p1shield == KSHIELD_BUBBLE && mobj1->player->bubblecool == 0) { // Each bump does chip damage to the shield. K_RemoveBubbleHealth(mobj1->player, BUBBLEBUMPCHIP); @@ -802,7 +803,7 @@ boolean K_KartBouncing(mobj_t *mobj1, mobj_t *mobj2, boolean bounce, boolean sol p2shield = K_GetShieldFromPlayer(mobj2->player); // Moved here so it only fires once on bump. - if (p2shield == KSHIELD_BUBBLE) + if (p2shield == KSHIELD_BUBBLE && mobj2->player->bubblecool == 0) { // Each bump does chip damage to the shield. K_RemoveBubbleHealth(mobj2->player, BUBBLEBUMPCHIP); @@ -10767,7 +10768,8 @@ void K_MoveKartPlayer(player_t *player, boolean onground) if (!HOLDING_ITEM && NO_HYUDORO) { - if ((buttons & BT_ATTACK) && (player->itemflags & IF_HOLDREADY)) + if ((buttons & BT_ATTACK && player->itemflags & IF_HOLDREADY) + || (player->bubbleblowup > 0 && player->bubblecool <= bubbletime/2)) // auto { if (player->bubblecool == 0) S_StartSound(player->mo, sfx_s3k75); @@ -10777,6 +10779,8 @@ void K_MoveKartPlayer(player_t *player, boolean onground) player->bubbleblowup += 3; player->bubblehealth--; } + else if (player->bubblecool >= bubbletime) + player->bubbleblowup++; // overcharge bonus if (++player->bubblecool >= bubbletime + TICRATE/2) { diff --git a/src/k_kart.h b/src/k_kart.h index a6d89e115..ffd764659 100644 --- a/src/k_kart.h +++ b/src/k_kart.h @@ -75,7 +75,7 @@ extern vector3_t clusterpoint, clusterdtf; #define BUBBLEBUMPCHIP ((MAXBUBBLEHEALTH + 1) / 2) // Damage done to an inflated Bubble Shield (rounded up) -#define BUBBLEITMDAMAGE ((MAXBUBBLEHEALTH + 5) / 6) +#define BUBBLEITMDAMAGE ((MAXBUBBLEHEALTH + 8) / 9) // Bump weight for a Bubble Shield #define BUBBLEMINWEIGHT (5 * FRACUNIT) diff --git a/src/p_mobj.c b/src/p_mobj.c index 082da153a..26f1d8ed0 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -9189,17 +9189,17 @@ static boolean P_MobjRegularThink(mobj_t *mobj) mobj->renderflags &= ~RF_GHOSTLYMASK; fixed_t stretch = 0; - if (player->bubblecool > bubbletime) - stretch = (player->bubblecool % 4) * FRACUNIT/5; - else if (player->bubbleblowup > 0 && player->bubblecool < 4) - stretch = player->bubblecool*FRACUNIT/6; - else if (player->bubbleblowup >= 4 && player->bubblecool < 8) - stretch = (8 - player->bubblecool)*FRACUNIT/6; - else if (player->bubblehealth == 0 && player->bubbleblowup == 0) + if (player->bubblecool >= bubbletime) // overcharge + stretch = ((player->bubblecool - bubbletime) % 4) * FRACUNIT/4; + else if (player->bubbleblowup > 0 && player->bubblecool <= 4) // inflate 1 + stretch = player->bubblecool*FRACUNIT/5; + else if (player->bubbleblowup >= 5 && player->bubblecool < 8) // inflate 2 + stretch = (8 - player->bubblecool)*FRACUNIT/5; + else if (player->bubblehealth == 0 && player->bubbleblowup == 0) // decaying stretch = (player->bubblecool - bubbletime)*FRACUNIT/bubbletime; - mobj->spritexscale = FRACUNIT + FTAN(FixedAngle(stretch*40) + ANGLE_90); - mobj->spriteyscale = FRACUNIT - stretch/3 + abs(FSIN(FixedAngle(stretch*80)))/8; + mobj->spritexscale = FRACUNIT + FTAN(FixedAngle(stretch*30) + ANGLE_90); + mobj->spriteyscale = FRACUNIT - stretch/5; mobj->colorized = true; if (player->bubbleblowup > 0 && leveltime & 1) @@ -9214,7 +9214,7 @@ static boolean P_MobjRegularThink(mobj_t *mobj) for (i = 0; i < 2; i++) { angle_t a = mobj->angle + ((i & 1) ? ANGLE_180 : 0); - fixed_t ws = player->mo->scale/2 + scale/5; + fixed_t ws = player->mo->scale/4 + scale/4; mobj_t *wave; wave = P_SpawnMobj(