Remove Stairjank.
This commit is contained in:
parent
dc6d03c8ee
commit
ec7cfc56fb
15 changed files with 3 additions and 158 deletions
|
|
@ -582,8 +582,6 @@ typedef struct player_s
|
|||
|
||||
UINT8 kickstartaccel;
|
||||
|
||||
UINT8 stairjank;
|
||||
|
||||
#ifdef HWRENDER
|
||||
fixed_t fovadd; // adjust FOV for hw rendering
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -4493,12 +4493,6 @@ const char *const STATE_LIST[] = { // array length left dynamic for sanity testi
|
|||
"S_DEBTSPIKEC",
|
||||
"S_DEBTSPIKED",
|
||||
"S_DEBTSPIKEE",
|
||||
|
||||
// Sparks when driving on stairs
|
||||
"S_JANKSPARK1",
|
||||
"S_JANKSPARK2",
|
||||
"S_JANKSPARK3",
|
||||
"S_JANKSPARK4",
|
||||
};
|
||||
|
||||
// RegEx to generate this from info.h: ^\tMT_([^,]+), --> \t"MT_\1",
|
||||
|
|
@ -5289,7 +5283,6 @@ const char *const MOBJTYPE_LIST[] = { // array length left dynamic for sanity t
|
|||
"MT_DRIFTDUST",
|
||||
"MT_DRIFTELECTRICITY",
|
||||
"MT_DRIFTELECTRICSPARK",
|
||||
"MT_JANKSPARK",
|
||||
|
||||
"MT_ROCKETSNEAKER", // Rocket sneakers
|
||||
|
||||
|
|
|
|||
33
src/info.c
33
src/info.c
|
|
@ -5083,12 +5083,6 @@ state_t states[NUMSTATES] =
|
|||
{SPR_DEBT, 7|FF_FULLBRIGHT, 1, {NULL}, 0, 0, S_DEBTSPIKED}, // S_DEBTSPIKEC
|
||||
{SPR_DEBT, 6|FF_FULLBRIGHT, 1, {NULL}, 0, 0, S_DEBTSPIKEE}, // S_DEBTSPIKED
|
||||
{SPR_DEBT, 7|FF_FULLBRIGHT, 1, {NULL}, 0, 0, S_DEBTSPIKE1}, // S_DEBTSPIKEE
|
||||
|
||||
// Sparks when driving on stairs
|
||||
{SPR_JANK, 0, 1, {NULL}, 0, 0, S_JANKSPARK2}, // S_JANKSPARK1
|
||||
{SPR_JANK, FF_PAPERSPRITE|FF_FULLBRIGHT|FF_ANIMATE, 4, {NULL}, 3, 1, S_JANKSPARK3}, // S_JANKSPARK2
|
||||
{SPR_JANK, 0, 0, {A_SetCustomValue}, -1, 5, S_JANKSPARK4}, // S_JANKSPARK3
|
||||
{SPR_JANK, 0, 0, {A_ChangeAngleRelative}, 180, 180, S_JANKSPARK2}, // S_JANKSPARK4
|
||||
};
|
||||
|
||||
mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
||||
|
|
@ -23145,33 +23139,6 @@ mobjinfo_t mobjinfo[NUMMOBJTYPES] =
|
|||
S_NULL // raisestate
|
||||
},
|
||||
|
||||
{ // MT_JANKSPARK
|
||||
-1, // doomednum
|
||||
S_JANKSPARK1, // spawnstate
|
||||
1000, // spawnhealth
|
||||
S_NULL, // seestate
|
||||
sfx_None, // seesound
|
||||
8, // reactiontime
|
||||
sfx_None, // attacksound
|
||||
S_NULL, // painstate
|
||||
0, // painchance
|
||||
sfx_None, // painsound
|
||||
S_NULL, // meleestate
|
||||
S_NULL, // missilestate
|
||||
S_NULL, // deathstate
|
||||
S_NULL, // xdeathstate
|
||||
sfx_None, // deathsound
|
||||
8, // speed
|
||||
8*FRACUNIT, // radius
|
||||
8*FRACUNIT, // height
|
||||
0, // display offset
|
||||
100, // mass
|
||||
0, // damage
|
||||
sfx_None, // activesound
|
||||
MF_NOBLOCKMAP|MF_NOCLIPHEIGHT|MF_NOGRAVITY|MF_FLOAT|MF_DONTENCOREMAP, // flags
|
||||
S_NULL // raisestate
|
||||
},
|
||||
|
||||
{ // MT_ROCKETSNEAKER
|
||||
-1, // doomednum
|
||||
S_ROCKETSNEAKER_L, // spawnstate
|
||||
|
|
|
|||
|
|
@ -5501,11 +5501,6 @@ typedef enum state
|
|||
S_DEBTSPIKED,
|
||||
S_DEBTSPIKEE,
|
||||
|
||||
S_JANKSPARK1,
|
||||
S_JANKSPARK2,
|
||||
S_JANKSPARK3,
|
||||
S_JANKSPARK4,
|
||||
|
||||
S_FIRSTFREESLOT,
|
||||
S_LASTFREESLOT = S_FIRSTFREESLOT + NUMSTATEFREESLOTS - 1,
|
||||
NUMSTATES
|
||||
|
|
@ -6315,7 +6310,6 @@ typedef enum mobj_type
|
|||
MT_DRIFTDUST,
|
||||
MT_DRIFTELECTRICITY,
|
||||
MT_DRIFTELECTRICSPARK,
|
||||
MT_JANKSPARK,
|
||||
|
||||
MT_ROCKETSNEAKER,
|
||||
|
||||
|
|
|
|||
|
|
@ -641,10 +641,7 @@ static botprediction_t *K_CreateBotPrediction(player_t *player)
|
|||
{
|
||||
const precise_t time = I_GetPreciseTime();
|
||||
|
||||
// Stair janking makes it harder to steer, so attempt to steer harder.
|
||||
const UINT8 jankDiv = (player->stairjank > 0) ? 2 : 1;
|
||||
|
||||
const INT16 handling = K_GetKartTurnValue(player, KART_FULLTURN) / jankDiv; // Reduce prediction based on how fast you can turn
|
||||
const INT16 handling = K_GetKartTurnValue(player, KART_FULLTURN); // Reduce prediction based on how fast you can turn
|
||||
|
||||
const tic_t futuresight = (TICRATE * KART_FULLTURN) / max(1, handling); // How far ahead into the future to try and predict
|
||||
const fixed_t speed = K_BotSpeedScaled(player, P_AproxDistance(player->mo->momx, player->mo->momy));
|
||||
|
|
|
|||
|
|
@ -9054,11 +9054,6 @@ SINT8 K_Sliptiding(player_t *player)
|
|||
return player->drift ? 0 : player->aizdriftstrat;
|
||||
}
|
||||
|
||||
INT32 K_StairJankFlip(INT32 value)
|
||||
{
|
||||
return P_AltFlip(value, 2);
|
||||
}
|
||||
|
||||
// Ebraking visuals for mo
|
||||
// we use mo->hprev for the hold bubble. If another hprev exists for some reason, remove it.
|
||||
|
||||
|
|
|
|||
|
|
@ -107,7 +107,6 @@ INT16 K_UpdateSteeringValue(INT16 inputSteering, INT16 destSteering);
|
|||
INT16 K_GetKartTurnValue(player_t *player, INT16 turnvalue);
|
||||
INT32 K_GetUnderwaterTurnAdjust(player_t *player);
|
||||
INT32 K_GetKartDriftSparkValue(player_t *player);
|
||||
INT32 K_StairJankFlip(INT32 value);
|
||||
INT32 K_GetKartDriftSparkValueForStage(player_t *player, UINT8 stage);
|
||||
void K_SpawnDriftBoostExplosion(player_t *player, int stage);
|
||||
void K_SpawnDriftElectricSparks(player_t *player);
|
||||
|
|
|
|||
|
|
@ -424,26 +424,6 @@ void K_ProcessTerrainEffect(mobj_t *mo)
|
|||
P_InstaThrust(mo, mo->angle, speed);
|
||||
}
|
||||
|
||||
// Bumpy floor
|
||||
if (terrain->flags & TRF_STAIRJANK)
|
||||
{
|
||||
/* use a shorter sound if not two tics have passed
|
||||
* since the last step */
|
||||
S_StartSound(mo, player->stairjank
|
||||
>= 16 ? sfx_s23b : sfx_s268);
|
||||
|
||||
if (player->stairjank == 0)
|
||||
{
|
||||
mobj_t *spark = P_SpawnMobjFromMobj(mo,
|
||||
0, 0, 0, MT_JANKSPARK);
|
||||
spark->fuse = 9;
|
||||
spark->cusval = K_StairJankFlip(ANGLE_90);
|
||||
P_SetTarget(&spark->target, mo);
|
||||
}
|
||||
|
||||
player->stairjank = 17;
|
||||
}
|
||||
|
||||
// (Offroad is handled elsewhere!)
|
||||
}
|
||||
|
||||
|
|
@ -1096,10 +1076,6 @@ static void K_ParseTerrainParameter(size_t i, char *param, char *val)
|
|||
{
|
||||
K_FlagBoolean(&terrain->flags, TRF_SNEAKERPANEL, val);
|
||||
}
|
||||
else if (stricmp(param, "bumpy") == 0 || stricmp(param, "stairJank") == 0)
|
||||
{
|
||||
K_FlagBoolean(&terrain->flags, TRF_STAIRJANK, val);
|
||||
}
|
||||
else if (stricmp(param, "tripwire") == 0)
|
||||
{
|
||||
K_FlagBoolean(&terrain->flags, TRF_TRIPWIRE, val);
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ typedef enum
|
|||
// Terrain flag values.
|
||||
TRF_LIQUID = 1, // Texture water properties (wavy, slippery, etc)
|
||||
TRF_SNEAKERPANEL = 1<<1, // Texture is a booster
|
||||
TRF_STAIRJANK = 1<<2, // Texture is bumpy road
|
||||
// = 1<<2, // Was bumpy road.
|
||||
TRF_TRIPWIRE = 1<<3 // Texture is a tripwire when used as a midtexture
|
||||
} terrain_flags_t;
|
||||
|
||||
|
|
|
|||
35
src/p_map.c
35
src/p_map.c
|
|
@ -2496,7 +2496,6 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
fixed_t radius = thing->radius;
|
||||
fixed_t thingtop;
|
||||
fixed_t startingonground = P_IsObjectOnGround(thing);
|
||||
fixed_t stairjank = 0;
|
||||
pslope_t *oldslope = thing->standingslope;
|
||||
floatok = false;
|
||||
|
||||
|
|
@ -2573,9 +2572,6 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
{
|
||||
if (tmfloorstep <= maxstep)
|
||||
{
|
||||
if (!flipped)
|
||||
stairjank = tmfloorstep;
|
||||
|
||||
thing->z = thing->floorz = tmfloorz;
|
||||
thing->floorrover = tmfloorrover;
|
||||
thing->eflags |= MFE_JUSTSTEPPEDDOWN;
|
||||
|
|
@ -2589,9 +2585,6 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
{
|
||||
if (tmceilingstep <= maxstep)
|
||||
{
|
||||
if (flipped)
|
||||
stairjank = tmceilingstep;
|
||||
|
||||
thing->z = ( thing->ceilingz = tmceilingz ) - thing->height;
|
||||
thing->ceilingrover = tmceilingrover;
|
||||
thing->eflags |= MFE_JUSTSTEPPEDDOWN;
|
||||
|
|
@ -2608,9 +2601,6 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
|
||||
if (thingtop == thing->ceilingz && tmceilingz > thingtop && tmceilingz - thingtop <= maxstep)
|
||||
{
|
||||
if (flipped)
|
||||
stairjank = (tmceilingz - thingtop);
|
||||
|
||||
thing->z = (thing->ceilingz = tmceilingz) - thing->height;
|
||||
thing->ceilingrover = tmceilingrover;
|
||||
thing->eflags |= MFE_JUSTSTEPPEDDOWN;
|
||||
|
|
@ -2618,9 +2608,6 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
}
|
||||
else if (thing->z == thing->floorz && tmfloorz < thing->z && thing->z - tmfloorz <= maxstep)
|
||||
{
|
||||
if (!flipped)
|
||||
stairjank = (thing->z - tmfloorz);
|
||||
|
||||
thing->z = thing->floorz = tmfloorz;
|
||||
thing->floorrover = tmfloorrover;
|
||||
thing->eflags |= MFE_JUSTSTEPPEDDOWN;
|
||||
|
|
@ -2725,28 +2712,6 @@ boolean P_TryMove(mobj_t *thing, fixed_t x, fixed_t y, boolean allowdropoff)
|
|||
thing->terrain = NULL;
|
||||
}
|
||||
|
||||
/* FIXME: slope step down (even up) has some false
|
||||
positives, so just ignore them entirely. */
|
||||
if (stairjank && !oldslope && !thing->standingslope &&
|
||||
thing->player && !thing->player->spectator)
|
||||
{
|
||||
/* use a shorter sound if not two tics have passed
|
||||
* since the last step */
|
||||
S_StartSound(thing, thing->player->stairjank
|
||||
>= 16 ? sfx_s23b : sfx_s268);
|
||||
|
||||
if (!thing->player->stairjank)
|
||||
{
|
||||
mobj_t * spark = P_SpawnMobjFromMobj(thing,
|
||||
0, 0, 0, MT_JANKSPARK);
|
||||
spark->fuse = 9;
|
||||
spark->cusval = K_StairJankFlip(ANGLE_90);
|
||||
P_SetTarget(&spark->target, thing);
|
||||
}
|
||||
|
||||
thing->player->stairjank = 17;
|
||||
}
|
||||
|
||||
thing->x = x;
|
||||
thing->y = y;
|
||||
|
||||
|
|
|
|||
15
src/p_mobj.c
15
src/p_mobj.c
|
|
@ -7398,21 +7398,6 @@ static boolean P_MobjRegularThink(mobj_t *mobj)
|
|||
case MT_BRAKEDUST:
|
||||
//mobj->renderflags ^= RF_DONTDRAW;
|
||||
break;
|
||||
case MT_JANKSPARK:
|
||||
if (!mobj->target)
|
||||
{
|
||||
P_RemoveMobj(mobj);
|
||||
return false;
|
||||
}
|
||||
if (mobj->fuse == 1 && mobj->target->player &&
|
||||
mobj->target->player->stairjank >= 8)
|
||||
{
|
||||
mobj->fuse = 9;
|
||||
}
|
||||
P_MoveOrigin(mobj, mobj->target->x,
|
||||
mobj->target->y, mobj->target->z);
|
||||
mobj->angle = mobj->target->angle + mobj->cusval;
|
||||
break;
|
||||
case MT_PLAYERRETICULE:
|
||||
if (!mobj->target || !mobj->target->health)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -365,8 +365,6 @@ static void P_NetArchivePlayers(void)
|
|||
|
||||
WRITEUINT8(save_p, players[i].kickstartaccel);
|
||||
|
||||
WRITEUINT8(save_p, players[i].stairjank);
|
||||
|
||||
// respawnvars_t
|
||||
WRITEUINT8(save_p, players[i].respawn.state);
|
||||
WRITEUINT32(save_p, K_GetWaypointHeapIndex(players[i].respawn.wp));
|
||||
|
|
@ -652,8 +650,6 @@ static void P_NetUnArchivePlayers(void)
|
|||
|
||||
players[i].kickstartaccel = READUINT8(save_p);
|
||||
|
||||
players[i].stairjank = READUINT8(save_p);
|
||||
|
||||
// respawnvars_t
|
||||
players[i].respawn.state = READUINT8(save_p);
|
||||
players[i].respawn.wp = (waypoint_t *)(size_t)READUINT32(save_p);
|
||||
|
|
|
|||
|
|
@ -984,11 +984,6 @@ void P_SlopeLaunch(mobj_t *mo)
|
|||
//CONS_Printf("Launched off of slope.\n");
|
||||
mo->standingslope = NULL;
|
||||
mo->terrain = NULL;
|
||||
|
||||
if (mo->player)
|
||||
{
|
||||
mo->player->stairjank = 0; // fuck you
|
||||
}
|
||||
}
|
||||
|
||||
//
|
||||
|
|
|
|||
11
src/p_user.c
11
src/p_user.c
|
|
@ -1769,11 +1769,7 @@ static void P_3dMovement(player_t *player)
|
|||
// Get the old momentum; this will be needed at the end of the function! -SH
|
||||
oldMagnitude = R_PointToDist2(player->mo->momx - player->cmomx, player->mo->momy - player->cmomy, 0, 0);
|
||||
|
||||
if (player->stairjank > 8 && leveltime & 3)
|
||||
{
|
||||
movepushangle = K_MomentumAngle(player->mo);
|
||||
}
|
||||
else if (player->drift != 0)
|
||||
if (player->drift != 0)
|
||||
{
|
||||
movepushangle = player->mo->angle - (ANGLE_45/5) * player->drift;
|
||||
}
|
||||
|
|
@ -4460,11 +4456,6 @@ void P_PlayerThink(player_t *player)
|
|||
player->typing_duration = 0;
|
||||
}
|
||||
|
||||
if (player->stairjank > 0)
|
||||
{
|
||||
player->stairjank--;
|
||||
}
|
||||
|
||||
K_KartPlayerThink(player, cmd); // SRB2kart
|
||||
|
||||
DoABarrelRoll(player);
|
||||
|
|
|
|||
|
|
@ -55,12 +55,6 @@ static angle_t R_PlayerSpriteRotation(player_t *player, player_t *viewPlayer)
|
|||
FixedMul(sliptideLift, FINECOSINE(angleDelta >> ANGLETOFINESHIFT));
|
||||
}
|
||||
|
||||
if (player->stairjank)
|
||||
{
|
||||
rollAngle += K_StairJankFlip(ANGLE_11hh / 2 /
|
||||
(17 / player->stairjank));
|
||||
}
|
||||
|
||||
return rollAngle;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue