mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
WIP: Trickpanel crack experiments
This commit is contained in:
parent
239388a1fa
commit
954bd85139
14 changed files with 165 additions and 108 deletions
|
|
@ -2550,7 +2550,7 @@ void CL_ClearPlayer(INT32 playernum)
|
||||||
PlayerPointerRemove(players[playernum].mo);
|
PlayerPointerRemove(players[playernum].mo);
|
||||||
PlayerPointerRemove(players[playernum].followmobj);
|
PlayerPointerRemove(players[playernum].followmobj);
|
||||||
PlayerPointerRemove(players[playernum].stumbleIndicator);
|
PlayerPointerRemove(players[playernum].stumbleIndicator);
|
||||||
PlayerPointerRemove(players[playernum].sliptideZipIndicator);
|
PlayerPointerRemove(players[playernum].wavedashIndicator);
|
||||||
PlayerPointerRemove(players[playernum].trickIndicator);
|
PlayerPointerRemove(players[playernum].trickIndicator);
|
||||||
|
|
||||||
#undef PlayerPointerRemove
|
#undef PlayerPointerRemove
|
||||||
|
|
|
||||||
|
|
@ -895,14 +895,16 @@ struct player_t
|
||||||
|
|
||||||
UINT8 tripwireReboundDelay; // When failing Tripwire, brieftly lock out speed-based tripwire pass (anti-cheese)
|
UINT8 tripwireReboundDelay; // When failing Tripwire, brieftly lock out speed-based tripwire pass (anti-cheese)
|
||||||
|
|
||||||
UINT16 sliptideZip; // How long is our chained sliptide? Grant a proportional boost when it's over.
|
UINT16 wavedash; // How long is our chained sliptide? Grant a proportional boost when it's over.
|
||||||
UINT8 sliptideZipDelay; // How long since the last sliptide? Only boost once you've been straightened out for a bit.
|
UINT8 wavedashdelay; // How long since the last sliptide? Only boost once you've been straightened out for a bit.
|
||||||
UINT16 sliptideZipBoost; // The actual boost granted from sliptideZip.
|
UINT16 wavedashboost; // The actual boost granted from wavedash.
|
||||||
|
UINT16 trickdashboost; // The actual boost granted from wavedash.
|
||||||
|
boolean trickdash;
|
||||||
|
|
||||||
UINT8 lastsafelap;
|
UINT8 lastsafelap;
|
||||||
|
|
||||||
mobj_t *stumbleIndicator;
|
mobj_t *stumbleIndicator;
|
||||||
mobj_t *sliptideZipIndicator;
|
mobj_t *wavedashIndicator;
|
||||||
mobj_t *trickIndicator;
|
mobj_t *trickIndicator;
|
||||||
mobj_t *whip;
|
mobj_t *whip;
|
||||||
mobj_t *hand;
|
mobj_t *hand;
|
||||||
|
|
|
||||||
|
|
@ -3314,7 +3314,7 @@ const char *const STATE_LIST[] = { // array length left dynamic for sanity testi
|
||||||
"S_MAGICIANBOXTOP",
|
"S_MAGICIANBOXTOP",
|
||||||
"S_MAGICIANBOXBOTTOM",
|
"S_MAGICIANBOXBOTTOM",
|
||||||
|
|
||||||
"S_SLIPTIDEZIP",
|
"S_WAVEDASH",
|
||||||
|
|
||||||
"S_INSTAWHIP",
|
"S_INSTAWHIP",
|
||||||
"S_INSTAWHIP_RECHARGE1",
|
"S_INSTAWHIP_RECHARGE1",
|
||||||
|
|
@ -5547,7 +5547,7 @@ const char *const MOBJTYPE_LIST[] = { // array length left dynamic for sanity t
|
||||||
"MT_MONITOR_SHARD",
|
"MT_MONITOR_SHARD",
|
||||||
"MT_MAGICIANBOX",
|
"MT_MAGICIANBOX",
|
||||||
|
|
||||||
"MT_SLIPTIDEZIP",
|
"MT_WAVEDASH",
|
||||||
|
|
||||||
"MT_INSTAWHIP",
|
"MT_INSTAWHIP",
|
||||||
"MT_INSTAWHIP_RECHARGE",
|
"MT_INSTAWHIP_RECHARGE",
|
||||||
|
|
|
||||||
|
|
@ -2243,7 +2243,7 @@ void G_PlayerReborn(INT32 player, boolean betweenmaps)
|
||||||
// These are mostly subservient to the player, and may not clean themselves up.
|
// These are mostly subservient to the player, and may not clean themselves up.
|
||||||
PlayerPointerRemove(players[player].followmobj);
|
PlayerPointerRemove(players[player].followmobj);
|
||||||
PlayerPointerRemove(players[player].stumbleIndicator);
|
PlayerPointerRemove(players[player].stumbleIndicator);
|
||||||
PlayerPointerRemove(players[player].sliptideZipIndicator);
|
PlayerPointerRemove(players[player].wavedashIndicator);
|
||||||
PlayerPointerRemove(players[player].trickIndicator);
|
PlayerPointerRemove(players[player].trickIndicator);
|
||||||
|
|
||||||
#undef PlayerPointerRemove
|
#undef PlayerPointerRemove
|
||||||
|
|
|
||||||
|
|
@ -558,7 +558,8 @@ char sprnames[NUMSPRITES + 1][5] =
|
||||||
"IMDB", // Item Monitor Small Shard (Debris)
|
"IMDB", // Item Monitor Small Shard (Debris)
|
||||||
"MTWK", // Item Monitor Glass Twinkle
|
"MTWK", // Item Monitor Glass Twinkle
|
||||||
|
|
||||||
"SLPT", // Sliptide zip indicator
|
"SLPT", // Wavedash indicator
|
||||||
|
"TRBS", // Trickdash indicator
|
||||||
|
|
||||||
"IWHP", // Instawhip
|
"IWHP", // Instawhip
|
||||||
"WPRE", // Instawhip Recharge
|
"WPRE", // Instawhip Recharge
|
||||||
|
|
@ -4126,7 +4127,7 @@ state_t states[NUMSTATES] =
|
||||||
{SPR_MGBT, FF_FLOORSPRITE|0, -1, {NULL}, 0, 0, S_NULL}, // S_MAGICIANBOX_TOP
|
{SPR_MGBT, FF_FLOORSPRITE|0, -1, {NULL}, 0, 0, S_NULL}, // S_MAGICIANBOX_TOP
|
||||||
{SPR_MGBB, FF_FLOORSPRITE|0, -1, {NULL}, 0, 0, S_NULL}, // S_MAGICIANBOX_BOTTOM
|
{SPR_MGBB, FF_FLOORSPRITE|0, -1, {NULL}, 0, 0, S_NULL}, // S_MAGICIANBOX_BOTTOM
|
||||||
|
|
||||||
{SPR_SLPT, FF_PAPERSPRITE|0, -1, {NULL}, 0, 0, S_NULL}, // S_SLIPTIDEZIP
|
{SPR_SLPT, FF_PAPERSPRITE|0, -1, {NULL}, 0, 0, S_NULL}, // S_WAVEDASH
|
||||||
|
|
||||||
{SPR_IWHP, FF_FLOORSPRITE|FF_ANIMATE|0, -1, {NULL}, 6, 2, S_NULL}, // S_INSTAWHIP
|
{SPR_IWHP, FF_FLOORSPRITE|FF_ANIMATE|0, -1, {NULL}, 6, 2, S_NULL}, // S_INSTAWHIP
|
||||||
{SPR_NULL, 0, 1, {NULL}, 0, 0, S_INSTAWHIP_RECHARGE2}, // S_INSTAWHIP_RECHARGE1
|
{SPR_NULL, 0, 1, {NULL}, 0, 0, S_INSTAWHIP_RECHARGE2}, // S_INSTAWHIP_RECHARGE1
|
||||||
|
|
@ -23078,9 +23079,9 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||||
S_NULL // raisestate
|
S_NULL // raisestate
|
||||||
},
|
},
|
||||||
|
|
||||||
{ // MT_SLIPTIDEZIP
|
{ // MT_WAVEDASH
|
||||||
-1, // doomednum
|
-1, // doomednum
|
||||||
S_SLIPTIDEZIP, // spawnstate
|
S_WAVEDASH, // spawnstate
|
||||||
1000, // spawnhealth
|
1000, // spawnhealth
|
||||||
S_NULL, // seestate
|
S_NULL, // seestate
|
||||||
sfx_None, // seesound
|
sfx_None, // seesound
|
||||||
|
|
|
||||||
|
|
@ -1115,7 +1115,8 @@ typedef enum sprite
|
||||||
SPR_IMDB, // Item Monitor Small Shard (Debris)
|
SPR_IMDB, // Item Monitor Small Shard (Debris)
|
||||||
SPR_MTWK, // Item Monitor Glass Twinkle
|
SPR_MTWK, // Item Monitor Glass Twinkle
|
||||||
|
|
||||||
SPR_SLPT, // Sliptide zip indicator
|
SPR_SLPT, // Wavedash indicator
|
||||||
|
SPR_TRBS, // Trickdash indicator
|
||||||
|
|
||||||
SPR_IWHP, // Instawhip
|
SPR_IWHP, // Instawhip
|
||||||
SPR_WPRE, // Instawhip Recharge
|
SPR_WPRE, // Instawhip Recharge
|
||||||
|
|
@ -4537,7 +4538,7 @@ typedef enum state
|
||||||
S_MAGICIANBOX_TOP,
|
S_MAGICIANBOX_TOP,
|
||||||
S_MAGICIANBOX_BOTTOM,
|
S_MAGICIANBOX_BOTTOM,
|
||||||
|
|
||||||
S_SLIPTIDEZIP,
|
S_WAVEDASH,
|
||||||
|
|
||||||
S_INSTAWHIP,
|
S_INSTAWHIP,
|
||||||
S_INSTAWHIP_RECHARGE1,
|
S_INSTAWHIP_RECHARGE1,
|
||||||
|
|
@ -6808,7 +6809,7 @@ typedef enum mobj_type
|
||||||
MT_MONITOR_PART,
|
MT_MONITOR_PART,
|
||||||
MT_MONITOR_SHARD,
|
MT_MONITOR_SHARD,
|
||||||
MT_MAGICIANBOX,
|
MT_MAGICIANBOX,
|
||||||
MT_SLIPTIDEZIP,
|
MT_WAVEDASH,
|
||||||
|
|
||||||
MT_INSTAWHIP,
|
MT_INSTAWHIP,
|
||||||
MT_INSTAWHIP_RECHARGE,
|
MT_INSTAWHIP_RECHARGE,
|
||||||
|
|
|
||||||
154
src/k_kart.c
154
src/k_kart.c
|
|
@ -1263,6 +1263,9 @@ static boolean K_HasInfiniteTether(player_t *player)
|
||||||
if (player->eggmanexplode > 0)
|
if (player->eggmanexplode > 0)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
if (player->trickdash)
|
||||||
|
return true;
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1881,9 +1884,9 @@ static void K_SpawnGenericSpeedLines(player_t *player, boolean top)
|
||||||
fast->colorized = true;
|
fast->colorized = true;
|
||||||
fast->renderflags |= RF_ADD;
|
fast->renderflags |= RF_ADD;
|
||||||
}
|
}
|
||||||
else if (player->sliptideZipBoost)
|
else if (player->wavedashboost || player->trickdashboost)
|
||||||
{
|
{
|
||||||
fast->color = SKINCOLOR_WHITE;
|
fast->color = (player->trickdashboost) ? K_RainbowColor(leveltime) : SKINCOLOR_WHITE;
|
||||||
fast->colorized = true;
|
fast->colorized = true;
|
||||||
}
|
}
|
||||||
else if (player->ringboost)
|
else if (player->ringboost)
|
||||||
|
|
@ -3231,12 +3234,17 @@ static void K_GetKartBoostPower(player_t *player)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (player->sliptideZipBoost)
|
if (player->wavedashboost)
|
||||||
{
|
{
|
||||||
// NB: This is intentionally under the 25% threshold required to initiate a sliptide
|
// NB: This is intentionally under the 25% handleboost threshold required to initiate a sliptide
|
||||||
ADDBOOST(8*FRACUNIT/10, 4*FRACUNIT, 2*SLIPTIDEHANDLING/5); // + 80% top speed, + 400% acceleration, +20% handling
|
ADDBOOST(8*FRACUNIT/10, 4*FRACUNIT, 2*SLIPTIDEHANDLING/5); // + 80% top speed, + 400% acceleration, +20% handling
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (player->trickdashboost)
|
||||||
|
{
|
||||||
|
ADDBOOST(8*FRACUNIT/10, 8*FRACUNIT, 3*SLIPTIDEHANDLING/5); // + 80% top speed, + 800% acceleration, +30% handling
|
||||||
|
}
|
||||||
|
|
||||||
if (player->spindashboost) // Spindash boost
|
if (player->spindashboost) // Spindash boost
|
||||||
{
|
{
|
||||||
const fixed_t MAXCHARGESPEED = K_GetSpindashChargeSpeed(player);
|
const fixed_t MAXCHARGESPEED = K_GetSpindashChargeSpeed(player);
|
||||||
|
|
@ -4074,7 +4082,7 @@ void K_InitStumbleIndicator(player_t *player)
|
||||||
P_SetTarget(&new->target, player->mo);
|
P_SetTarget(&new->target, player->mo);
|
||||||
}
|
}
|
||||||
|
|
||||||
void K_InitSliptideZipIndicator(player_t *player)
|
void K_InitWavedashIndicator(player_t *player)
|
||||||
{
|
{
|
||||||
mobj_t *new = NULL;
|
mobj_t *new = NULL;
|
||||||
|
|
||||||
|
|
@ -4088,14 +4096,14 @@ void K_InitSliptideZipIndicator(player_t *player)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (P_MobjWasRemoved(player->sliptideZipIndicator) == false)
|
if (P_MobjWasRemoved(player->wavedashIndicator) == false)
|
||||||
{
|
{
|
||||||
P_RemoveMobj(player->sliptideZipIndicator);
|
P_RemoveMobj(player->wavedashIndicator);
|
||||||
}
|
}
|
||||||
|
|
||||||
new = P_SpawnMobjFromMobj(player->mo, 0, 0, 0, MT_SLIPTIDEZIP);
|
new = P_SpawnMobjFromMobj(player->mo, 0, 0, 0, MT_WAVEDASH);
|
||||||
|
|
||||||
P_SetTarget(&player->sliptideZipIndicator, new);
|
P_SetTarget(&player->wavedashIndicator, new);
|
||||||
P_SetTarget(&new->target, player->mo);
|
P_SetTarget(&new->target, player->mo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4250,11 +4258,11 @@ void K_UpdateStumbleIndicator(player_t *player)
|
||||||
|
|
||||||
#define MIN_WAVEDASH_CHARGE ((7*TICRATE/16)*9)
|
#define MIN_WAVEDASH_CHARGE ((7*TICRATE/16)*9)
|
||||||
|
|
||||||
static boolean K_IsLosingSliptideZip(player_t *player)
|
static boolean K_IsLosingWavedash(player_t *player)
|
||||||
{
|
{
|
||||||
if (player->mo == NULL || P_MobjWasRemoved(player->mo) == true)
|
if (player->mo == NULL || P_MobjWasRemoved(player->mo) == true)
|
||||||
return true;
|
return true;
|
||||||
if (!K_Sliptiding(player) && player->sliptideZip < MIN_WAVEDASH_CHARGE)
|
if (!K_Sliptiding(player) && player->wavedash < MIN_WAVEDASH_CHARGE)
|
||||||
return true;
|
return true;
|
||||||
if (!K_Sliptiding(player) && player->drift == 0
|
if (!K_Sliptiding(player) && player->drift == 0
|
||||||
&& P_IsObjectOnGround(player->mo) && player->sneakertimer == 0
|
&& P_IsObjectOnGround(player->mo) && player->sneakertimer == 0
|
||||||
|
|
@ -4263,7 +4271,7 @@ static boolean K_IsLosingSliptideZip(player_t *player)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void K_UpdateSliptideZipIndicator(player_t *player)
|
void K_UpdateWavedashIndicator(player_t *player)
|
||||||
{
|
{
|
||||||
mobj_t *mobj = NULL;
|
mobj_t *mobj = NULL;
|
||||||
|
|
||||||
|
|
@ -4277,13 +4285,13 @@ void K_UpdateSliptideZipIndicator(player_t *player)
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (player->sliptideZipIndicator == NULL || P_MobjWasRemoved(player->sliptideZipIndicator) == true)
|
if (player->wavedashIndicator == NULL || P_MobjWasRemoved(player->wavedashIndicator) == true)
|
||||||
{
|
{
|
||||||
K_InitSliptideZipIndicator(player);
|
K_InitWavedashIndicator(player);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
mobj = player->sliptideZipIndicator;
|
mobj = player->wavedashIndicator;
|
||||||
angle_t momentumAngle = K_MomentumAngle(player->mo);
|
angle_t momentumAngle = K_MomentumAngle(player->mo);
|
||||||
|
|
||||||
P_MoveOrigin(mobj, player->mo->x - FixedMul(40*mapobjectscale, FINECOSINE(momentumAngle >> ANGLETOFINESHIFT)),
|
P_MoveOrigin(mobj, player->mo->x - FixedMul(40*mapobjectscale, FINECOSINE(momentumAngle >> ANGLETOFINESHIFT)),
|
||||||
|
|
@ -4293,7 +4301,7 @@ void K_UpdateSliptideZipIndicator(player_t *player)
|
||||||
P_SetScale(mobj, 3 * player->mo->scale / 2);
|
P_SetScale(mobj, 3 * player->mo->scale / 2);
|
||||||
|
|
||||||
// No stored boost (or negligible enough that it might be a mistake)
|
// No stored boost (or negligible enough that it might be a mistake)
|
||||||
if (player->sliptideZip <= HIDEWAVEDASHCHARGE)
|
if (player->wavedash <= HIDEWAVEDASHCHARGE)
|
||||||
{
|
{
|
||||||
mobj->renderflags |= RF_DONTDRAW;
|
mobj->renderflags |= RF_DONTDRAW;
|
||||||
mobj->frame = 7;
|
mobj->frame = 7;
|
||||||
|
|
@ -4302,8 +4310,8 @@ void K_UpdateSliptideZipIndicator(player_t *player)
|
||||||
|
|
||||||
mobj->renderflags &= ~RF_DONTDRAW;
|
mobj->renderflags &= ~RF_DONTDRAW;
|
||||||
|
|
||||||
UINT32 chargeFrame = 7 - min(7, player->sliptideZip / 100);
|
UINT32 chargeFrame = 7 - min(7, player->wavedash / 100);
|
||||||
UINT32 decayFrame = min(7, player->sliptideZipDelay / 2);
|
UINT32 decayFrame = min(7, player->wavedashdelay / 2);
|
||||||
if (max(chargeFrame, decayFrame) > mobj->frame)
|
if (max(chargeFrame, decayFrame) > mobj->frame)
|
||||||
mobj->frame++;
|
mobj->frame++;
|
||||||
else if (max(chargeFrame, decayFrame) < mobj->frame)
|
else if (max(chargeFrame, decayFrame) < mobj->frame)
|
||||||
|
|
@ -4312,7 +4320,7 @@ void K_UpdateSliptideZipIndicator(player_t *player)
|
||||||
mobj->renderflags &= ~RF_TRANSMASK;
|
mobj->renderflags &= ~RF_TRANSMASK;
|
||||||
mobj->renderflags |= RF_PAPERSPRITE;
|
mobj->renderflags |= RF_PAPERSPRITE;
|
||||||
|
|
||||||
if (K_IsLosingSliptideZip(player))
|
if (K_IsLosingWavedash(player))
|
||||||
{
|
{
|
||||||
// Decay timer's ticking
|
// Decay timer's ticking
|
||||||
mobj->rollangle += 3*ANG30/4;
|
mobj->rollangle += 3*ANG30/4;
|
||||||
|
|
@ -4324,6 +4332,17 @@ void K_UpdateSliptideZipIndicator(player_t *player)
|
||||||
// Storing boost
|
// Storing boost
|
||||||
mobj->rollangle += 3*ANG15/4;
|
mobj->rollangle += 3*ANG15/4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (player->trickdash)
|
||||||
|
{
|
||||||
|
mobj->sprite = SPR_TRBS;
|
||||||
|
mobj->renderflags |= RF_ADD;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
mobj->sprite = SPR_SLPT;
|
||||||
|
mobj->renderflags &= ~RF_ADD;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static mobj_t *K_TrickCatholocismBlast(mobj_t *trickIndicator, fixed_t destscale, angle_t rollangle)
|
static mobj_t *K_TrickCatholocismBlast(mobj_t *trickIndicator, fixed_t destscale, angle_t rollangle)
|
||||||
|
|
@ -8107,7 +8126,7 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
||||||
if (player->sneakertimer || player->ringboost
|
if (player->sneakertimer || player->ringboost
|
||||||
|| player->driftboost || player->startboost
|
|| player->driftboost || player->startboost
|
||||||
|| player->eggmanexplode || player->trickboost
|
|| player->eggmanexplode || player->trickboost
|
||||||
|| player->gateBoost || player->sliptideZipBoost)
|
|| player->gateBoost || player->wavedashboost || player->trickdashboost)
|
||||||
{
|
{
|
||||||
#if 0
|
#if 0
|
||||||
if (player->invincibilitytimer)
|
if (player->invincibilitytimer)
|
||||||
|
|
@ -8393,9 +8412,14 @@ void K_KartPlayerThink(player_t *player, ticcmd_t *cmd)
|
||||||
if (player->dropdashboost)
|
if (player->dropdashboost)
|
||||||
player->dropdashboost--;
|
player->dropdashboost--;
|
||||||
|
|
||||||
if (player->sliptideZipBoost > 0 && onground == true)
|
if (player->wavedashboost > 0 && onground == true)
|
||||||
{
|
{
|
||||||
player->sliptideZipBoost--;
|
player->wavedashboost--;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (player->trickdashboost > 0 && onground == true)
|
||||||
|
{
|
||||||
|
player->trickdashboost--;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (player->spindashboost)
|
if (player->spindashboost)
|
||||||
|
|
@ -8864,7 +8888,7 @@ void K_KartPlayerAfterThink(player_t *player)
|
||||||
K_KartResetPlayerColor(player);
|
K_KartResetPlayerColor(player);
|
||||||
|
|
||||||
K_UpdateStumbleIndicator(player);
|
K_UpdateStumbleIndicator(player);
|
||||||
K_UpdateSliptideZipIndicator(player);
|
K_UpdateWavedashIndicator(player);
|
||||||
K_UpdateTrickIndicator(player);
|
K_UpdateTrickIndicator(player);
|
||||||
|
|
||||||
// Move held objects (Bananas, Orbinaut, etc)
|
// Move held objects (Bananas, Orbinaut, etc)
|
||||||
|
|
@ -9925,8 +9949,9 @@ static void K_KartDrift(player_t *player, boolean onground)
|
||||||
player->drift = player->driftcharge = player->aizdriftstrat = 0;
|
player->drift = player->driftcharge = player->aizdriftstrat = 0;
|
||||||
player->pflags &= ~(PF_BRAKEDRIFT|PF_GETSPARKS);
|
player->pflags &= ~(PF_BRAKEDRIFT|PF_GETSPARKS);
|
||||||
// And take away wavedash properties: advanced cornering demands advanced finesse
|
// And take away wavedash properties: advanced cornering demands advanced finesse
|
||||||
player->sliptideZip = 0;
|
player->wavedash = 0;
|
||||||
player->sliptideZipBoost = 0;
|
player->wavedashboost = 0;
|
||||||
|
player->trickdashboost = 0;
|
||||||
}
|
}
|
||||||
else if ((player->pflags & PF_DRIFTINPUT) && player->drift != 0)
|
else if ((player->pflags & PF_DRIFTINPUT) && player->drift != 0)
|
||||||
{
|
{
|
||||||
|
|
@ -10028,11 +10053,11 @@ static void K_KartDrift(player_t *player, boolean onground)
|
||||||
|| (!player->aizdriftstrat)
|
|| (!player->aizdriftstrat)
|
||||||
|| (player->steering > 0) != (player->aizdriftstrat > 0))
|
|| (player->steering > 0) != (player->aizdriftstrat > 0))
|
||||||
{
|
{
|
||||||
if (!player->drift && player->steering && player->aizdriftstrat && player->sliptideZip // If we were sliptiding last tic,
|
if (!player->drift && player->steering && player->aizdriftstrat && player->wavedash // If we were sliptiding last tic,
|
||||||
&& (player->steering > 0) == (player->aizdriftstrat > 0) // we're steering in the right direction,
|
&& (player->steering > 0) == (player->aizdriftstrat > 0) // we're steering in the right direction,
|
||||||
&& player->speed >= K_GetKartSpeed(player, false, true)) // and we're above the threshold to spawn dust...
|
&& player->speed >= K_GetKartSpeed(player, false, true)) // and we're above the threshold to spawn dust...
|
||||||
{
|
{
|
||||||
keepsliptide = true; // Then keep your current sliptide, but note the behavior change for sliptidezip handling.
|
keepsliptide = true; // Then keep your current sliptide, but note the behavior change for wavedash handling.
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
@ -10060,9 +10085,9 @@ static void K_KartDrift(player_t *player, boolean onground)
|
||||||
// This makes wavedash charge noticeably slower on even modest delay, despite the magnitude of the turn seeming the same.
|
// This makes wavedash charge noticeably slower on even modest delay, despite the magnitude of the turn seeming the same.
|
||||||
// So we only require 90% of a turn to get full charge strength.
|
// So we only require 90% of a turn to get full charge strength.
|
||||||
|
|
||||||
player->sliptideZip += addCharge;
|
player->wavedash += addCharge;
|
||||||
|
|
||||||
if (player->sliptideZip >= MIN_WAVEDASH_CHARGE && (player->sliptideZip - addCharge) < MIN_WAVEDASH_CHARGE)
|
if (player->wavedash >= MIN_WAVEDASH_CHARGE && (player->wavedash - addCharge) < MIN_WAVEDASH_CHARGE)
|
||||||
S_StartSound(player->mo, sfx_waved5);
|
S_StartSound(player->mo, sfx_waved5);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10088,16 +10113,16 @@ static void K_KartDrift(player_t *player, boolean onground)
|
||||||
|
|
||||||
if (!K_Sliptiding(player) || keepsliptide)
|
if (!K_Sliptiding(player) || keepsliptide)
|
||||||
{
|
{
|
||||||
if (!keepsliptide && K_IsLosingSliptideZip(player) && player->sliptideZip > 0)
|
if (!keepsliptide && K_IsLosingWavedash(player) && player->wavedash > 0)
|
||||||
{
|
{
|
||||||
if (player->sliptideZip > HIDEWAVEDASHCHARGE && !S_SoundPlaying(player->mo, sfx_waved2))
|
if (player->wavedash > HIDEWAVEDASHCHARGE && !S_SoundPlaying(player->mo, sfx_waved2))
|
||||||
S_StartSoundAtVolume(player->mo, sfx_waved2, 255); // Losing combo time, going to boost
|
S_StartSoundAtVolume(player->mo, sfx_waved2, 255); // Losing combo time, going to boost
|
||||||
S_StopSoundByID(player->mo, sfx_waved1);
|
S_StopSoundByID(player->mo, sfx_waved1);
|
||||||
S_StopSoundByID(player->mo, sfx_waved4);
|
S_StopSoundByID(player->mo, sfx_waved4);
|
||||||
player->sliptideZipDelay++;
|
player->wavedashdelay++;
|
||||||
if (player->sliptideZipDelay > TICRATE/2)
|
if (player->wavedashdelay > TICRATE/2)
|
||||||
{
|
{
|
||||||
if (player->sliptideZip >= MIN_WAVEDASH_CHARGE)
|
if (player->wavedash >= MIN_WAVEDASH_CHARGE)
|
||||||
{
|
{
|
||||||
fixed_t maxZipPower = 2*FRACUNIT;
|
fixed_t maxZipPower = 2*FRACUNIT;
|
||||||
fixed_t minZipPower = 1*FRACUNIT;
|
fixed_t minZipPower = 1*FRACUNIT;
|
||||||
|
|
@ -10112,30 +10137,36 @@ static void K_KartDrift(player_t *player, boolean onground)
|
||||||
|
|
||||||
fixed_t yourPowerReduction = FixedDiv(yourPenalty * FRACUNIT, penaltySpread * FRACUNIT);
|
fixed_t yourPowerReduction = FixedDiv(yourPenalty * FRACUNIT, penaltySpread * FRACUNIT);
|
||||||
fixed_t yourPower = maxZipPower - FixedMul(yourPowerReduction, powerSpread);
|
fixed_t yourPower = maxZipPower - FixedMul(yourPowerReduction, powerSpread);
|
||||||
int yourBoost = FixedInt(FixedMul(yourPower, player->sliptideZip/10 * FRACUNIT));
|
int yourBoost = FixedInt(FixedMul(yourPower, player->wavedash/10 * FRACUNIT));
|
||||||
|
|
||||||
/*
|
if (player->trickdash)
|
||||||
CONS_Printf("SZ %d MZ %d mZ %d pwS %d mP %d MP %d peS %d yPe %d yPR %d yPw %d yB %d\n",
|
{
|
||||||
player->sliptideZip, maxZipPower, minZipPower, powerSpread, minPenalty, maxPenalty, penaltySpread, yourPenalty, yourPowerReduction, yourPower, yourBoost);
|
player->trickdashboost += 3*yourBoost/2;
|
||||||
*/
|
S_StartSoundAtVolume(player->mo, sfx_gshba, 255);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
player->wavedashboost += yourBoost;
|
||||||
|
}
|
||||||
|
|
||||||
player->sliptideZipBoost += yourBoost;
|
S_StartSoundAtVolume(player->mo, sfx_waved3, 255); // Boost
|
||||||
|
|
||||||
|
player->trickdash = 0;
|
||||||
|
|
||||||
K_SpawnDriftBoostExplosion(player, 0);
|
K_SpawnDriftBoostExplosion(player, 0);
|
||||||
S_StartSoundAtVolume(player->mo, sfx_waved3, 255); // Boost
|
|
||||||
}
|
}
|
||||||
S_StopSoundByID(player->mo, sfx_waved1);
|
S_StopSoundByID(player->mo, sfx_waved1);
|
||||||
S_StopSoundByID(player->mo, sfx_waved2);
|
S_StopSoundByID(player->mo, sfx_waved2);
|
||||||
S_StopSoundByID(player->mo, sfx_waved4);
|
S_StopSoundByID(player->mo, sfx_waved4);
|
||||||
player->sliptideZip = 0;
|
player->wavedash = 0;
|
||||||
player->sliptideZipDelay = 0;
|
player->wavedashdelay = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
S_StopSoundByID(player->mo, sfx_waved1);
|
S_StopSoundByID(player->mo, sfx_waved1);
|
||||||
S_StopSoundByID(player->mo, sfx_waved2);
|
S_StopSoundByID(player->mo, sfx_waved2);
|
||||||
if (player->sliptideZip > 0 && !S_SoundPlaying(player->mo, sfx_waved4))
|
if (player->wavedash > 0 && !S_SoundPlaying(player->mo, sfx_waved4))
|
||||||
S_StartSoundAtVolume(player->mo, sfx_waved4, 255); // Passive woosh
|
S_StartSoundAtVolume(player->mo, sfx_waved4, 255); // Passive woosh
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10149,10 +10180,10 @@ static void K_KartDrift(player_t *player, boolean onground)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
player->sliptideZipDelay = 0;
|
player->wavedashdelay = 0;
|
||||||
S_StopSoundByID(player->mo, sfx_waved2);
|
S_StopSoundByID(player->mo, sfx_waved2);
|
||||||
S_StopSoundByID(player->mo, sfx_waved4);
|
S_StopSoundByID(player->mo, sfx_waved4);
|
||||||
if (player->sliptideZip > HIDEWAVEDASHCHARGE && !S_SoundPlaying(player->mo, sfx_waved1))
|
if (player->wavedash > HIDEWAVEDASHCHARGE && !S_SoundPlaying(player->mo, sfx_waved1))
|
||||||
S_StartSoundAtVolume(player->mo, sfx_waved1, 255); // Charging
|
S_StartSoundAtVolume(player->mo, sfx_waved1, 255); // Charging
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10711,7 +10742,7 @@ static void K_KartSpindashWind(mobj_t *parent)
|
||||||
|
|
||||||
P_SetTarget(&wind->target, parent);
|
P_SetTarget(&wind->target, parent);
|
||||||
|
|
||||||
if (parent->player && parent->player->sliptideZipBoost)
|
if (parent->player && parent->player->wavedashboost)
|
||||||
P_SetScale(wind, wind->scale * 2);
|
P_SetScale(wind, wind->scale * 2);
|
||||||
|
|
||||||
if (parent->momx || parent->momy)
|
if (parent->momx || parent->momy)
|
||||||
|
|
@ -10775,7 +10806,7 @@ static void K_KartSpindash(player_t *player)
|
||||||
K_KartSpindashWind(player->mo);
|
K_KartSpindashWind(player->mo);
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((player->sliptideZipBoost > 0) && (spawnWind == true))
|
if ((player->wavedashboost > 0 || player->trickdashboost > 0) && (spawnWind == true))
|
||||||
{
|
{
|
||||||
K_KartSpindashWind(player->mo);
|
K_KartSpindashWind(player->mo);
|
||||||
}
|
}
|
||||||
|
|
@ -11885,7 +11916,7 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
||||||
if (player->throwdir == -1)
|
if (player->throwdir == -1)
|
||||||
{
|
{
|
||||||
P_InstaThrust(player->mo, player->mo->angle, player->speed + (80 * mapobjectscale));
|
P_InstaThrust(player->mo, player->mo->angle, player->speed + (80 * mapobjectscale));
|
||||||
player->sliptideZipBoost += TICRATE; // Just for keeping speed briefly vs. tripwire etc.
|
player->wavedashboost += 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.
|
// If this doesn't turn out to be reliable, I'll change it to directly set leniency or something.
|
||||||
}
|
}
|
||||||
K_PlayAttackTaunt(player->mo);
|
K_PlayAttackTaunt(player->mo);
|
||||||
|
|
@ -12218,6 +12249,7 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
||||||
{
|
{
|
||||||
S_StartSound(player->mo, sfx_trick0);
|
S_StartSound(player->mo, sfx_trick0);
|
||||||
player->dotrickfx = true;
|
player->dotrickfx = true;
|
||||||
|
player->trickboostdecay = min(TICRATE*3/4, abs(momz/FRACUNIT));
|
||||||
|
|
||||||
if (cmd->turning > 0)
|
if (cmd->turning > 0)
|
||||||
{
|
{
|
||||||
|
|
@ -12252,6 +12284,7 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
||||||
{
|
{
|
||||||
S_StartSound(player->mo, sfx_trick0);
|
S_StartSound(player->mo, sfx_trick0);
|
||||||
player->dotrickfx = true;
|
player->dotrickfx = true;
|
||||||
|
player->trickboostdecay = min(TICRATE*3/4, abs(momz/FRACUNIT));
|
||||||
|
|
||||||
if (cmd->throwdir > 0) // forward trick
|
if (cmd->throwdir > 0) // forward trick
|
||||||
{
|
{
|
||||||
|
|
@ -12366,24 +12399,31 @@ void K_MoveKartPlayer(player_t *player, boolean onground)
|
||||||
}
|
}
|
||||||
else if ((player->trickpanel != TRICKSTATE_NONE) && P_IsObjectOnGround(player->mo)) // Landed from trick
|
else if ((player->trickpanel != TRICKSTATE_NONE) && P_IsObjectOnGround(player->mo)) // Landed from trick
|
||||||
{
|
{
|
||||||
|
K_SpawnDashDustRelease(player);
|
||||||
|
|
||||||
if (player->fastfall)
|
if (player->fastfall)
|
||||||
{
|
{
|
||||||
|
P_InstaThrust(player->mo, player->mo->angle, 2*abs(player->fastfall)/3 + 15*FRACUNIT);
|
||||||
player->mo->hitlag = 3;
|
player->mo->hitlag = 3;
|
||||||
K_SpawnDashDustRelease(player);
|
S_StartSound(player->mo, sfx_gshac); // TODO
|
||||||
P_InstaThrust(player->mo, player->mo->angle, 30*FRACUNIT);
|
|
||||||
S_StartSound(player->mo, sfx_gshce);
|
|
||||||
player->fastfall = 0; // intentionally skip bounce
|
player->fastfall = 0; // intentionally skip bounce
|
||||||
}
|
}
|
||||||
|
else
|
||||||
if (player->trickpanel == TRICKSTATE_BACK) // upward trick
|
|
||||||
{
|
{
|
||||||
S_StartSound(player->mo, sfx_s23c);
|
S_StartSound(player->mo, sfx_s23c);
|
||||||
K_SpawnDashDustRelease(player);
|
K_SpawnDashDustRelease(player);
|
||||||
player->trickboost = TICRATE - player->trickboostdecay;
|
player->trickboost = TICRATE - player->trickboostdecay;
|
||||||
}
|
player->wavedash += 150; // bonus for the slow fall
|
||||||
|
//player->wavedashdelay = TICRATE/2 - 2;
|
||||||
|
player->wavedashdelay = 0;
|
||||||
|
|
||||||
player->sliptideZip += 300;
|
if (player->trickpanel == TRICKSTATE_FORWARD)
|
||||||
player->sliptideZipDelay = 0;
|
player->trickboostpower /= 18;
|
||||||
|
else if (player->trickpanel != TRICKSTATE_BACK)
|
||||||
|
player->trickboostpower /= 9;
|
||||||
|
|
||||||
|
player->trickdash = true;
|
||||||
|
}
|
||||||
|
|
||||||
player->trickpanel = TRICKSTATE_NONE;
|
player->trickpanel = TRICKSTATE_NONE;
|
||||||
player->trickboostdecay = 0;
|
player->trickboostdecay = 0;
|
||||||
|
|
|
||||||
|
|
@ -119,10 +119,10 @@ angle_t K_StumbleSlope(angle_t angle, angle_t pitch, angle_t roll);
|
||||||
void K_StumblePlayer(player_t *player);
|
void K_StumblePlayer(player_t *player);
|
||||||
boolean K_CheckStumble(player_t *player, angle_t oldPitch, angle_t oldRoll, boolean fromAir);
|
boolean K_CheckStumble(player_t *player, angle_t oldPitch, angle_t oldRoll, boolean fromAir);
|
||||||
void K_InitStumbleIndicator(player_t *player);
|
void K_InitStumbleIndicator(player_t *player);
|
||||||
void K_InitSliptideZipIndicator(player_t *player);
|
void K_InitWavedashIndicator(player_t *player);
|
||||||
void K_InitTrickIndicator(player_t *player);
|
void K_InitTrickIndicator(player_t *player);
|
||||||
void K_UpdateStumbleIndicator(player_t *player);
|
void K_UpdateStumbleIndicator(player_t *player);
|
||||||
void K_UpdateSliptideZipIndicator(player_t *player);
|
void K_UpdateWavedashIndicator(player_t *player);
|
||||||
void K_UpdateTrickIndicator(player_t *player);
|
void K_UpdateTrickIndicator(player_t *player);
|
||||||
INT32 K_ExplodePlayer(player_t *player, mobj_t *inflictor, mobj_t *source);
|
INT32 K_ExplodePlayer(player_t *player, mobj_t *inflictor, mobj_t *source);
|
||||||
void K_DebtStingPlayer(player_t *player, mobj_t *source);
|
void K_DebtStingPlayer(player_t *player, mobj_t *source);
|
||||||
|
|
|
||||||
|
|
@ -156,7 +156,8 @@ void K_DoIngameRespawn(player_t *player)
|
||||||
player->ringboost = 0;
|
player->ringboost = 0;
|
||||||
player->driftboost = player->strongdriftboost = 0;
|
player->driftboost = player->strongdriftboost = 0;
|
||||||
player->gateBoost = 0;
|
player->gateBoost = 0;
|
||||||
player->sliptideZip = player->sliptideZipBoost = player->sliptideZipDelay = 0;
|
player->trickdash = 0;
|
||||||
|
player->wavedash = player->wavedashboost = player->wavedashdelay = player->trickdashboost = 0;
|
||||||
|
|
||||||
K_TumbleInterrupt(player);
|
K_TumbleInterrupt(player);
|
||||||
P_ResetPlayer(player);
|
P_ResetPlayer(player);
|
||||||
|
|
|
||||||
|
|
@ -325,12 +325,16 @@ static int player_get(lua_State *L)
|
||||||
lua_pushinteger(L, plr->tripwireLeniency);
|
lua_pushinteger(L, plr->tripwireLeniency);
|
||||||
else if (fastcmp(field,"tripwireReboundDelay"))
|
else if (fastcmp(field,"tripwireReboundDelay"))
|
||||||
lua_pushinteger(L, plr->tripwireReboundDelay);
|
lua_pushinteger(L, plr->tripwireReboundDelay);
|
||||||
else if (fastcmp(field,"sliptideZip"))
|
else if (fastcmp(field,"wavedash"))
|
||||||
lua_pushinteger(L, plr->sliptideZip);
|
lua_pushinteger(L, plr->wavedash);
|
||||||
else if (fastcmp(field,"sliptideZipDelay"))
|
else if (fastcmp(field,"wavedashdelay"))
|
||||||
lua_pushinteger(L, plr->sliptideZipDelay);
|
lua_pushinteger(L, plr->wavedashdelay);
|
||||||
else if (fastcmp(field,"sliptideZipBoost"))
|
else if (fastcmp(field,"wavedashboost"))
|
||||||
lua_pushinteger(L, plr->sliptideZipBoost);
|
lua_pushinteger(L, plr->wavedashboost);
|
||||||
|
else if (fastcmp(field,"trickdashboost"))
|
||||||
|
lua_pushinteger(L, plr->trickdashboost);
|
||||||
|
else if (fastcmp(field,"trickdash"))
|
||||||
|
lua_pushinteger(L, plr->trickdash);
|
||||||
else if (fastcmp(field,"lastsafelap"))
|
else if (fastcmp(field,"lastsafelap"))
|
||||||
lua_pushinteger(L, plr->lastsafelap);
|
lua_pushinteger(L, plr->lastsafelap);
|
||||||
else if (fastcmp(field,"instaWhipCharge"))
|
else if (fastcmp(field,"instaWhipCharge"))
|
||||||
|
|
@ -809,12 +813,16 @@ static int player_set(lua_State *L)
|
||||||
plr->tripwireLeniency = luaL_checkinteger(L, 3);
|
plr->tripwireLeniency = luaL_checkinteger(L, 3);
|
||||||
else if (fastcmp(field,"tripwireReboundDelay"))
|
else if (fastcmp(field,"tripwireReboundDelay"))
|
||||||
plr->tripwireReboundDelay = luaL_checkinteger(L, 3);
|
plr->tripwireReboundDelay = luaL_checkinteger(L, 3);
|
||||||
else if (fastcmp(field,"sliptideZip"))
|
else if (fastcmp(field,"wavedash"))
|
||||||
plr->sliptideZip = luaL_checkinteger(L, 3);
|
plr->wavedash = luaL_checkinteger(L, 3);
|
||||||
else if (fastcmp(field,"sliptideZipDelay"))
|
else if (fastcmp(field,"wavedashdelay"))
|
||||||
plr->sliptideZipDelay = luaL_checkinteger(L, 3);
|
plr->wavedashdelay = luaL_checkinteger(L, 3);
|
||||||
else if (fastcmp(field,"sliptideZipBoost"))
|
else if (fastcmp(field,"wavedashboost"))
|
||||||
plr->sliptideZipBoost = luaL_checkinteger(L, 3);
|
plr->wavedashboost = luaL_checkinteger(L, 3);
|
||||||
|
else if (fastcmp(field,"trickdashboost"))
|
||||||
|
plr->trickdashboost = luaL_checkinteger(L, 3);
|
||||||
|
else if (fastcmp(field,"trickdash"))
|
||||||
|
plr->trickdash = luaL_checkinteger(L, 3);
|
||||||
else if (fastcmp(field,"lastsafelap"))
|
else if (fastcmp(field,"lastsafelap"))
|
||||||
plr->lastsafelap = luaL_checkinteger(L, 3);
|
plr->lastsafelap = luaL_checkinteger(L, 3);
|
||||||
else if (fastcmp(field,"instaWhipCharge"))
|
else if (fastcmp(field,"instaWhipCharge"))
|
||||||
|
|
|
||||||
|
|
@ -2558,7 +2558,7 @@ static boolean P_KillPlayer(player_t *player, mobj_t *inflictor, mobj_t *source,
|
||||||
}
|
}
|
||||||
|
|
||||||
PlayerPointerRemove(player->stumbleIndicator);
|
PlayerPointerRemove(player->stumbleIndicator);
|
||||||
PlayerPointerRemove(player->sliptideZipIndicator);
|
PlayerPointerRemove(player->wavedashIndicator);
|
||||||
PlayerPointerRemove(player->trickIndicator);
|
PlayerPointerRemove(player->trickIndicator);
|
||||||
|
|
||||||
#undef PlayerPointerRemove
|
#undef PlayerPointerRemove
|
||||||
|
|
|
||||||
|
|
@ -12543,7 +12543,7 @@ void P_SpawnPlayer(INT32 playernum)
|
||||||
p->griefValue = 0;
|
p->griefValue = 0;
|
||||||
|
|
||||||
K_InitStumbleIndicator(p);
|
K_InitStumbleIndicator(p);
|
||||||
K_InitSliptideZipIndicator(p);
|
K_InitWavedashIndicator(p);
|
||||||
K_InitTrickIndicator(p);
|
K_InitTrickIndicator(p);
|
||||||
|
|
||||||
if (gametyperules & GTR_ITEMARROWS)
|
if (gametyperules & GTR_ITEMARROWS)
|
||||||
|
|
|
||||||
|
|
@ -75,7 +75,7 @@ typedef enum
|
||||||
SKYBOXCENTER = 0x0010,
|
SKYBOXCENTER = 0x0010,
|
||||||
HOVERHYUDORO = 0x0020,
|
HOVERHYUDORO = 0x0020,
|
||||||
STUMBLE = 0x0040,
|
STUMBLE = 0x0040,
|
||||||
SLIPTIDEZIP = 0x0080,
|
WAVEDASH = 0x0080,
|
||||||
RINGSHOOTER = 0x0100,
|
RINGSHOOTER = 0x0100,
|
||||||
WHIP = 0x0200,
|
WHIP = 0x0200,
|
||||||
HAND = 0x0400,
|
HAND = 0x0400,
|
||||||
|
|
@ -311,8 +311,8 @@ static void P_NetArchivePlayers(savebuffer_t *save)
|
||||||
if (players[i].stumbleIndicator)
|
if (players[i].stumbleIndicator)
|
||||||
flags |= STUMBLE;
|
flags |= STUMBLE;
|
||||||
|
|
||||||
if (players[i].sliptideZipIndicator)
|
if (players[i].wavedashIndicator)
|
||||||
flags |= SLIPTIDEZIP;
|
flags |= WAVEDASH;
|
||||||
|
|
||||||
if (players[i].trickIndicator)
|
if (players[i].trickIndicator)
|
||||||
flags |= TRICKINDICATOR;
|
flags |= TRICKINDICATOR;
|
||||||
|
|
@ -352,8 +352,8 @@ static void P_NetArchivePlayers(savebuffer_t *save)
|
||||||
if (flags & STUMBLE)
|
if (flags & STUMBLE)
|
||||||
WRITEUINT32(save->p, players[i].stumbleIndicator->mobjnum);
|
WRITEUINT32(save->p, players[i].stumbleIndicator->mobjnum);
|
||||||
|
|
||||||
if (flags & SLIPTIDEZIP)
|
if (flags & WAVEDASH)
|
||||||
WRITEUINT32(save->p, players[i].sliptideZipIndicator->mobjnum);
|
WRITEUINT32(save->p, players[i].wavedashIndicator->mobjnum);
|
||||||
|
|
||||||
if (flags & TRICKINDICATOR)
|
if (flags & TRICKINDICATOR)
|
||||||
WRITEUINT32(save->p, players[i].trickIndicator->mobjnum);
|
WRITEUINT32(save->p, players[i].trickIndicator->mobjnum);
|
||||||
|
|
@ -542,9 +542,11 @@ static void P_NetArchivePlayers(savebuffer_t *save)
|
||||||
|
|
||||||
WRITEUINT8(save->p, players[i].tripwireReboundDelay);
|
WRITEUINT8(save->p, players[i].tripwireReboundDelay);
|
||||||
|
|
||||||
WRITEUINT16(save->p, players[i].sliptideZip);
|
WRITEUINT16(save->p, players[i].wavedash);
|
||||||
WRITEUINT8(save->p, players[i].sliptideZipDelay);
|
WRITEUINT8(save->p, players[i].wavedashdelay);
|
||||||
WRITEUINT16(save->p, players[i].sliptideZipBoost);
|
WRITEUINT16(save->p, players[i].wavedashboost);
|
||||||
|
WRITEUINT8(save->p, players[i].trickdash);
|
||||||
|
WRITEUINT16(save->p, players[i].trickdashboost);
|
||||||
|
|
||||||
WRITEUINT8(save->p, players[i].lastsafelap);
|
WRITEUINT8(save->p, players[i].lastsafelap);
|
||||||
|
|
||||||
|
|
@ -869,8 +871,8 @@ static void P_NetUnArchivePlayers(savebuffer_t *save)
|
||||||
if (flags & STUMBLE)
|
if (flags & STUMBLE)
|
||||||
players[i].stumbleIndicator = (mobj_t *)(size_t)READUINT32(save->p);
|
players[i].stumbleIndicator = (mobj_t *)(size_t)READUINT32(save->p);
|
||||||
|
|
||||||
if (flags & SLIPTIDEZIP)
|
if (flags & WAVEDASH)
|
||||||
players[i].sliptideZipIndicator = (mobj_t *)(size_t)READUINT32(save->p);
|
players[i].wavedashIndicator = (mobj_t *)(size_t)READUINT32(save->p);
|
||||||
|
|
||||||
if (flags & TRICKINDICATOR)
|
if (flags & TRICKINDICATOR)
|
||||||
players[i].trickIndicator = (mobj_t *)(size_t)READUINT32(save->p);
|
players[i].trickIndicator = (mobj_t *)(size_t)READUINT32(save->p);
|
||||||
|
|
@ -1060,9 +1062,11 @@ static void P_NetUnArchivePlayers(savebuffer_t *save)
|
||||||
|
|
||||||
players[i].tripwireReboundDelay = READUINT8(save->p);
|
players[i].tripwireReboundDelay = READUINT8(save->p);
|
||||||
|
|
||||||
players[i].sliptideZip = READUINT16(save->p);
|
players[i].wavedash = READUINT16(save->p);
|
||||||
players[i].sliptideZipDelay = READUINT8(save->p);
|
players[i].wavedashdelay = READUINT8(save->p);
|
||||||
players[i].sliptideZipBoost = READUINT16(save->p);
|
players[i].wavedashboost = READUINT16(save->p);
|
||||||
|
players[i].trickdash = READUINT8(save->p);
|
||||||
|
players[i].trickdashboost = READUINT16(save->p);
|
||||||
|
|
||||||
players[i].lastsafelap = READUINT8(save->p);
|
players[i].lastsafelap = READUINT8(save->p);
|
||||||
|
|
||||||
|
|
@ -5600,12 +5604,12 @@ static void P_RelinkPointers(void)
|
||||||
if (!P_SetTarget(&players[i].stumbleIndicator, P_FindNewPosition(temp)))
|
if (!P_SetTarget(&players[i].stumbleIndicator, P_FindNewPosition(temp)))
|
||||||
CONS_Debug(DBG_GAMELOGIC, "stumbleIndicator not found on player %d\n", i);
|
CONS_Debug(DBG_GAMELOGIC, "stumbleIndicator not found on player %d\n", i);
|
||||||
}
|
}
|
||||||
if (players[i].sliptideZipIndicator)
|
if (players[i].wavedashIndicator)
|
||||||
{
|
{
|
||||||
temp = (UINT32)(size_t)players[i].sliptideZipIndicator;
|
temp = (UINT32)(size_t)players[i].wavedashIndicator;
|
||||||
players[i].sliptideZipIndicator = NULL;
|
players[i].wavedashIndicator = NULL;
|
||||||
if (!P_SetTarget(&players[i].sliptideZipIndicator, P_FindNewPosition(temp)))
|
if (!P_SetTarget(&players[i].wavedashIndicator, P_FindNewPosition(temp)))
|
||||||
CONS_Debug(DBG_GAMELOGIC, "sliptideZipIndicator not found on player %d\n", i);
|
CONS_Debug(DBG_GAMELOGIC, "wavedashIndicator not found on player %d\n", i);
|
||||||
}
|
}
|
||||||
if (players[i].trickIndicator)
|
if (players[i].trickIndicator)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -4000,7 +4000,7 @@ void P_PlayerThink(player_t *player)
|
||||||
|
|
||||||
PlayerPointerErase(player->followmobj);
|
PlayerPointerErase(player->followmobj);
|
||||||
PlayerPointerErase(player->stumbleIndicator);
|
PlayerPointerErase(player->stumbleIndicator);
|
||||||
PlayerPointerErase(player->sliptideZipIndicator);
|
PlayerPointerErase(player->wavedashIndicator);
|
||||||
PlayerPointerErase(player->trickIndicator);
|
PlayerPointerErase(player->trickIndicator);
|
||||||
PlayerPointerErase(player->whip);
|
PlayerPointerErase(player->whip);
|
||||||
PlayerPointerErase(player->hand);
|
PlayerPointerErase(player->hand);
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue