mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
WIP
This commit is contained in:
parent
8615ed9db9
commit
c05a9db159
2 changed files with 19 additions and 1 deletions
18
src/k_kart.c
18
src/k_kart.c
|
|
@ -11814,6 +11814,18 @@ static void K_KartSpindash(player_t *player)
|
|||
player->spindash = 0;
|
||||
P_ResetPitchRoll(player->mo);
|
||||
|
||||
// 2.2 - alternate fastfall
|
||||
if (!G_CompatLevel(0x000A))
|
||||
{
|
||||
if (K_PressingEBrake(player) && player->curshield != KSHIELD_BUBBLE && player->trickpanel == TRICKSTATE_NONE)
|
||||
{
|
||||
mobj_t *fuckingthing = P_SpawnGhostMobj(player->mo);
|
||||
fuckingthing->extravalue1 = 69;
|
||||
fuckingthing->renderflags &= ~RF_TRANSMASK;
|
||||
fuckingthing->tics = 3;
|
||||
}
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
else if (player->fastfall != 0)
|
||||
|
|
@ -11955,7 +11967,7 @@ boolean K_FastFallBounce(player_t *player)
|
|||
// 2.2 - More lenient fastfall
|
||||
if (!G_CompatLevel(0x000A))
|
||||
{
|
||||
if (player->curshield != KSHIELD_BUBBLE)
|
||||
if (player->curshield != KSHIELD_BUBBLE && K_PressingEBrake(player))
|
||||
{
|
||||
// Nudge the player in their facing angle, and provide a little starting momentum if they need it.
|
||||
// The bounce is already a strong tradeoff, so this allows it to be used for saves and get you back into flow.
|
||||
|
|
@ -11963,6 +11975,10 @@ boolean K_FastFallBounce(player_t *player)
|
|||
fixed_t minspeed = K_GetKartSpeed(player, false, false)/2;
|
||||
fixed_t returnspeed = max(FixedHypot(player->mo->momx, player->mo->momy), minspeed);
|
||||
|
||||
S_StartSound(player->mo, sfx_gshac);
|
||||
S_StartSound(player->mo, sfx_gshdc);
|
||||
K_AddHitLag(player->mo, 4, false);
|
||||
|
||||
// Initial momentum set uses real speed to avoid some weird twitchy behavior at low XY speed
|
||||
P_InstaThrust(player->mo, momangle, FixedHypot(player->mo->momx, player->mo->momy)/2);
|
||||
P_Thrust(player->mo, player->mo->angle, returnspeed/2);
|
||||
|
|
|
|||
|
|
@ -1089,6 +1089,8 @@ mobj_t *P_SpawnGhostMobj(mobj_t *mobj)
|
|||
ghost->sprite2 = mobj->sprite2;
|
||||
ghost->frame = mobj->frame;
|
||||
ghost->tics = -1;
|
||||
// Trying to control transparency on ghost mobjs? Turn around.
|
||||
// Look for the MT_GHOST thinker in p_mobj.c.
|
||||
ghost->renderflags = (mobj->renderflags & ~RF_TRANSMASK)|RF_TRANS50;
|
||||
ghost->fuse = ghost->info->damage;
|
||||
ghost->skin = mobj->skin;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue