mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Bubble bounce converts height into speed, bubble set boosts
This commit is contained in:
parent
c194ccb81a
commit
b005cf017e
1 changed files with 18 additions and 3 deletions
21
src/k_kart.c
21
src/k_kart.c
|
|
@ -10593,8 +10593,11 @@ boolean K_FastFallBounce(player_t *player)
|
|||
else
|
||||
{
|
||||
// Lose speed on bad bounce.
|
||||
player->mo->momx /= 2;
|
||||
player->mo->momy /= 2;
|
||||
if (player->curshield != KSHIELD_BUBBLE)
|
||||
{
|
||||
player->mo->momx /= 2;
|
||||
player->mo->momy /= 2;
|
||||
}
|
||||
|
||||
if (bounce < minBounce)
|
||||
{
|
||||
|
|
@ -10605,7 +10608,16 @@ boolean K_FastFallBounce(player_t *player)
|
|||
if (player->mo->eflags & MFE_UNDERWATER)
|
||||
bounce = (117 * bounce) / 200;
|
||||
|
||||
S_StartSound(player->mo, sfx_ffbonc);
|
||||
if (player->curshield == KSHIELD_BUBBLE)
|
||||
{
|
||||
S_StartSound(player->mo, sfx_s3k44);
|
||||
P_InstaThrust(player->mo, player->mo->angle, abs(player->fastfall));
|
||||
}
|
||||
else
|
||||
{
|
||||
S_StartSound(player->mo, sfx_ffbonc);
|
||||
}
|
||||
|
||||
player->mo->momz = bounce * P_MobjFlip(player->mo);
|
||||
|
||||
player->fastfall = 0;
|
||||
|
|
@ -11473,6 +11485,9 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
|||
if (player->bubbleblowup > bubbletime*2)
|
||||
{
|
||||
K_ThrowKartItem(player, (player->throwdir > 0), MT_BUBBLESHIELDTRAP, -1, 0, 0);
|
||||
P_InstaThrust(player->mo, player->mo->angle, player->speed + (80 * mapobjectscale));
|
||||
player->sliptideZipBoost += TICRATE; // Just for keeping speed briefly vs. tripwire etc.
|
||||
// If this doesn't turn out to be reliable, I'll change it to directly set leniency or something.
|
||||
K_PlayAttackTaunt(player->mo);
|
||||
player->bubbleblowup = 0;
|
||||
player->bubblecool = 0;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue