mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Merge branch 'rc3-fast-balance' into 'master'
RC3 fast balance Closes ring-racers#128, ring-racers#136, ring-racers#141, ring-racers#140, and ring-racers#137 See merge request kart-krew-dev/ring-racers-internal!2870
This commit is contained in:
commit
5c3d180a58
9 changed files with 47 additions and 32 deletions
|
|
@ -2454,7 +2454,7 @@ void G_PlayerReborn(INT32 player, boolean betweenmaps)
|
|||
}
|
||||
else
|
||||
{
|
||||
rings = 20; // POSITION is fucking serious now
|
||||
rings = 10; // Never mind, people love serious POSITION
|
||||
}
|
||||
|
||||
saveroundconditions = false;
|
||||
|
|
|
|||
15
src/k_kart.c
15
src/k_kart.c
|
|
@ -10726,6 +10726,8 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
|||
S_StartSound(pmo, sfx_gshad);
|
||||
}
|
||||
|
||||
player->rings = -20;
|
||||
|
||||
player->baildrop--;
|
||||
if (player->baildrop == 0)
|
||||
player->ringboost /= 3;
|
||||
|
|
@ -10747,9 +10749,10 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
|||
UINT32 bailboost = FixedInt(FixedMul(totalrings*FRACUNIT, BAIL_BOOST));
|
||||
UINT32 baildrop = FixedInt(FixedMul((totalrings)*FRACUNIT, BAIL_DROP));
|
||||
|
||||
// CONS_Printf("R=%d SR=%d PR=%d DR=%d TR=%d\n", player->rings, player->superring, player->pickuprings, debtrings, totalrings);
|
||||
|
||||
player->rings = -20;
|
||||
player->superring = 0;
|
||||
player->pickuprings = 0;
|
||||
player->ringboxaward = 0;
|
||||
player->ringboxdelay = 0;
|
||||
player->superringdisplay = 0;
|
||||
|
|
@ -10760,6 +10763,7 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
|||
// Below: The stun the player gets from bailing is reduced as a pity if you did it out of Burst. Longer charge, shorter stun.
|
||||
player->stunned = BAILSTUN - player->bailcharge*5/4; // note: bailcharge goes up by 2 every tic, not 1, so this is actually - charge duration *2
|
||||
player->bailcharge = 0;
|
||||
player->defenseLockout = 2*PUNISHWINDOW;
|
||||
|
||||
player->ringboost += bailboost * (3+K_GetKartRingPower(player, true));
|
||||
player->baildrop += baildrop * BAIL_DROPFREQUENCY + 1;
|
||||
|
|
@ -11647,6 +11651,13 @@ void K_KartResetPlayerColor(player_t *player)
|
|||
}
|
||||
}
|
||||
|
||||
if (player->baildrop && (leveltime%4 == 0))
|
||||
{
|
||||
player->mo->colorized = true;
|
||||
player->mo->color = SKINCOLOR_BLACK;
|
||||
goto finalise;
|
||||
}
|
||||
|
||||
if (player->eggmanTransferDelay)
|
||||
{
|
||||
player->mo->colorized = true;
|
||||
|
|
@ -14841,7 +14852,7 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
|||
S_StartSound(player->mo, sfx_s3k7b);
|
||||
player->bailcharge = 0;
|
||||
}
|
||||
else if ((player->itemtype && player->itemamount) || player->rings > 0 || player->superring > 0 || player->pickuprings > 0 || player->itemRoulette.active)
|
||||
else if ((player->itemtype && player->itemamount) || (player->rings + player->superring + player->pickuprings > 0) || player->itemRoulette.active)
|
||||
{
|
||||
// Set up bail charge, provided we have something to bail with (any rings or item resource).
|
||||
// boolean grounded = P_IsObjectOnGround(player->mo);
|
||||
|
|
|
|||
|
|
@ -42,12 +42,12 @@ Make sure this matches the actual number of states
|
|||
#define INSTAWHIP_HOLD_DELAY (TICRATE*2)
|
||||
// MUST be longer or equal to INSTAWHIP_CHARGETIME.
|
||||
#define INSTAWHIP_TETHERBLOCK (TICRATE*4)
|
||||
#define PUNISHWINDOW (7*TICRATE/10)
|
||||
#define PUNISHWINDOW (10*TICRATE/10)
|
||||
|
||||
#define BAIL_MAXCHARGE (84) // tics to bail when in painstate nad in air, on ground is half, if you touch this, also update Obj_BailChargeThink synced animation logic
|
||||
#define BAIL_DROP (FRACUNIT) // How many rings it has to drop before stun starts
|
||||
#define BAIL_BOOST (6*FRACUNIT/5) // How fast bail itself is
|
||||
#define BAIL_CREDIT_DEBTRINGS (true)
|
||||
#define BAIL_CREDIT_DEBTRINGS (true)
|
||||
#define BAIL_DROPFREQUENCY (2) // How quickly the rings spill out
|
||||
#define BAILSTUN (TICRATE*6) // The fixed length of stun after baildrop is over
|
||||
|
||||
|
|
|
|||
|
|
@ -91,7 +91,7 @@ static UINT32 K_DynamicItemOddsRace[NUMKARTRESULTS-1][2] =
|
|||
{1, 3}, // landmine
|
||||
{25, 3}, // ballhog
|
||||
{58, 6}, // selfpropelledbomb
|
||||
{55, 7}, // grow
|
||||
{60, 7}, // grow
|
||||
{70, 8}, // shrink
|
||||
{1, 1}, // lightningshield
|
||||
{25, 4}, // bubbleshield
|
||||
|
|
@ -1426,7 +1426,7 @@ void K_FillItemRouletteData(player_t *player, itemroulette_t *const roulette, bo
|
|||
// 5: Skim any items that are much weaker than the reel's average out of the roulette
|
||||
// 6: Cram it all in
|
||||
|
||||
fixed_t largegamescaler = roulette->playing * 10 + 100; // Spread out item odds in large games for a less insane experience.
|
||||
fixed_t largegamescaler = roulette->playing * 14 + 100; // Spread out item odds in large games for a less insane experience.
|
||||
UINT32 targetpower = 100 * roulette->dist / largegamescaler; // fill roulette with items around this value!
|
||||
|
||||
UINT32 powers[NUMKARTRESULTS]; // how strong is each item? think of this as a "target distance" for this item to spawn at
|
||||
|
|
@ -1540,7 +1540,7 @@ void K_FillItemRouletteData(player_t *player, itemroulette_t *const roulette, bo
|
|||
// A lot of items suck if no players are nearby to interact with them.
|
||||
// Should we bias towards items that get us back to the action?
|
||||
// This will set the "loneliness" percentage to be used later.
|
||||
UINT32 lonelinessThreshold = 3*DISTVAR; // How far away can we be before items are considered useless?
|
||||
UINT32 lonelinessThreshold = 4*DISTVAR; // How far away can we be before items are considered useless?
|
||||
UINT32 toFront = lonelinessThreshold; // Distance to the player trying to kill us.
|
||||
UINT32 toBack = lonelinessThreshold; // Distance to the player we are trying to kill.
|
||||
fixed_t loneliness = 0;
|
||||
|
|
@ -1662,7 +1662,7 @@ void K_FillItemRouletteData(player_t *player, itemroulette_t *const roulette, bo
|
|||
// Conversely, if we're lonely, try not to reselect an item that wouldn't be useful to us
|
||||
// without any players to use it on.
|
||||
if (!K_IsItemSpeed(bestitem))
|
||||
deltapenalty = Easing_Linear(loneliness, deltapenalty, 5*deltapenalty);
|
||||
deltapenalty = Easing_Linear(loneliness, deltapenalty, 3*deltapenalty);
|
||||
|
||||
// Draw complex odds debugger. This one breaks down all the calcs in order.
|
||||
if (cv_kartdebugdistribution.value > 1)
|
||||
|
|
|
|||
|
|
@ -218,12 +218,7 @@ boolean Obj_OrbinautJawzCollide(mobj_t *t1, mobj_t *t2)
|
|||
if ((t1->type == MT_ORBINAUT_SHIELD || t1->type == MT_JAWZ_SHIELD)
|
||||
&& !t2->player->invincibilitytimer && !K_IsBigger(t2, t1)) // UGH. Stumble ignores invinc. Fix this damage type someday.
|
||||
{
|
||||
// Same hack as Instawhip!
|
||||
// If you do this a third time, please make it a part of the damage system.
|
||||
// ^ remove all of P_DamageMobj and start over
|
||||
P_PlayRinglossSound(t2);
|
||||
P_PlayerRingBurst(t2->player, 5);
|
||||
P_DamageMobj(t2, t1, t1->target, 1, DMG_WOMBO | DMG_WHUMBLE);
|
||||
P_DamageMobj(t2, t1, t1->target, 1, DMG_WOMBO | DMG_STUMBLE);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
|
|
@ -3515,9 +3515,9 @@ void A_AttractChase(mobj_t *actor)
|
|||
// 2. ALL conditions that deleted flingrings off you didn't decrement pickuprings, desyncing your ring count
|
||||
boolean stale = (!actor->target || P_MobjWasRemoved(actor->target) || !actor->target->player);
|
||||
|
||||
boolean blocked = (actor->target->player->baildrop || actor->target->player->bailcharge);
|
||||
boolean blocked = (actor->target->player->baildrop);
|
||||
if (G_CompatLevel(0x0010))
|
||||
blocked |= (actor->target->player->defenseLockout > PUNISHWINDOW);
|
||||
blocked |= !!(actor->target->player->bailcharge || actor->target->player->defenseLockout > PUNISHWINDOW);
|
||||
|
||||
if (stale || blocked)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -3159,7 +3159,7 @@ boolean P_DamageMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, INT32 da
|
|||
return false;
|
||||
}
|
||||
|
||||
if (invincible && type != DMG_STUMBLE && type != DMG_WHUMBLE)
|
||||
if (invincible && type != DMG_WHUMBLE)
|
||||
{
|
||||
const INT32 oldHitlag = target->hitlag;
|
||||
const INT32 oldHitlagInflictor = inflictor ? inflictor->hitlag : 0;
|
||||
|
|
@ -3214,7 +3214,6 @@ boolean P_DamageMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, INT32 da
|
|||
K_DoInstashield(player);
|
||||
return false;
|
||||
}
|
||||
|
||||
{
|
||||
// Check if we should allow wombo combos (hard hits by default, inverted by the presence of DMG_WOMBO).
|
||||
boolean allowcombo = ((hardhit || (type == DMG_STUMBLE || type == DMG_WHUMBLE)) == !(damagetype & DMG_WOMBO));
|
||||
|
|
@ -3289,6 +3288,14 @@ boolean P_DamageMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, INT32 da
|
|||
if (type == DMG_STING || type == DMG_STUMBLE)
|
||||
{
|
||||
damage = 0;
|
||||
|
||||
if (source && source != player->mo && source->player)
|
||||
{
|
||||
if (!P_PlayerInPain(player) && (player->defenseLockout || player->instaWhipCharge))
|
||||
{
|
||||
K_SpawnAmps(source->player, 20, target);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -3461,6 +3468,7 @@ boolean P_DamageMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, INT32 da
|
|||
&& inflictor->type != MT_BANANA) // Are there other designed trap items that can be deployed and dropped? If you add one, list it here!
|
||||
{
|
||||
type = DMG_STUMBLE;
|
||||
downgraded = true;
|
||||
player->ringburst += 5; // IT'S THE DAMAGE STUMBLE HACK AGAIN AAAAAAAAHHHHHHHHHHH
|
||||
K_PopPlayerShield(player);
|
||||
}
|
||||
|
|
@ -3499,7 +3507,7 @@ boolean P_DamageMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, INT32 da
|
|||
case DMG_STUMBLE:
|
||||
case DMG_WHUMBLE:
|
||||
K_StumblePlayer(player);
|
||||
ringburst = 0;
|
||||
ringburst = 5;
|
||||
break;
|
||||
case DMG_TUMBLE:
|
||||
K_TumblePlayer(player, inflictor, source, softenTumble);
|
||||
|
|
@ -3526,22 +3534,18 @@ boolean P_DamageMobj(mobj_t *target, mobj_t *inflictor, mobj_t *source, INT32 da
|
|||
ringburst = 0;
|
||||
}
|
||||
|
||||
player->ringburst += ringburst;
|
||||
|
||||
K_PopPlayerShield(player);
|
||||
|
||||
if ((type != DMG_STUMBLE && type != DMG_WHUMBLE) || (type == DMG_STUMBLE && downgraded))
|
||||
{
|
||||
if (type != DMG_STING)
|
||||
player->flashing = K_GetKartFlashing(player);
|
||||
|
||||
player->ringburst += ringburst;
|
||||
|
||||
K_PopPlayerShield(player);
|
||||
player->instashield = 15;
|
||||
}
|
||||
|
||||
K_PlayPainSound(target, source);
|
||||
}
|
||||
else if (inflictor && inflictor->type == MT_INSTAWHIP)
|
||||
{
|
||||
K_PopPlayerShield(player);
|
||||
}
|
||||
K_PlayPainSound(target, source);
|
||||
|
||||
if (gametyperules & GTR_BUMPERS)
|
||||
player->spheres = min(player->spheres + 10, 40);
|
||||
|
|
|
|||
|
|
@ -8399,7 +8399,7 @@ static boolean P_MobjRegularThink(mobj_t *mobj)
|
|||
|
||||
P_MoveOrigin(mobj, mobj->target->x + FixedMul(34 * mapobjectscale, FINECOSINE((mobj->angle + mobj->movedir) >> ANGLETOFINESHIFT)),
|
||||
mobj->target->y + FixedMul(34 * mapobjectscale, FINESINE((mobj->angle + mobj->movedir) >> ANGLETOFINESHIFT)),
|
||||
mobj->z + (32 * mapobjectscale));
|
||||
mobj->target->z + (32 * mapobjectscale));
|
||||
|
||||
K_MatchGenericExtraFlags(mobj, mobj->target);
|
||||
|
||||
|
|
|
|||
|
|
@ -2075,7 +2075,7 @@ static void K_HandleLapIncrement(player_t *player)
|
|||
K_SpawnDriftBoostExplosion(player, 4);
|
||||
K_SpawnDriftElectricSparks(player, SKINCOLOR_SILVER, false);
|
||||
if (!G_TimeAttackStart())
|
||||
K_SpawnAmps(player, (K_InRaceDuel()) ? 20 : 35, player->mo);
|
||||
K_SpawnAmps(player, (K_InRaceDuel()) ? 20 : 20, player->mo);
|
||||
|
||||
if (g_teamplay)
|
||||
{
|
||||
|
|
@ -5422,7 +5422,12 @@ static void P_EvaluateDamageType(player_t *player, sector_t *sector, boolean isT
|
|||
break;
|
||||
case SD_STUMBLE:
|
||||
if (isTouching)
|
||||
{
|
||||
player->pflags2 |= PF2_ALWAYSDAMAGED;
|
||||
P_DamageMobj(player->mo, NULL, NULL, 1, DMG_STUMBLE);
|
||||
player->pflags2 &= ~PF2_ALWAYSDAMAGED;
|
||||
}
|
||||
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue