Minor things

- crash fix
- commented out player 2 spawning with balloons
- double checked battle exiting is 10 sec
This commit is contained in:
TehRealSalt 2017-11-17 17:36:04 -05:00
parent cca30d1095
commit 06eca5fbb5
3 changed files with 11 additions and 22 deletions

View File

@ -2597,16 +2597,9 @@ INT16 K_GetKartTurnValue(player_t *player, INT16 turnvalue)
static void K_KartDrift(player_t *player, boolean onground)
{
fixed_t dsone;
fixed_t dstwo;
// IF YOU CHANGE THESE: MAKE SURE YOU UPDATE THE SAME VALUES IN p_mobjc, "case MT_DRIFT:"
if (gametype != GT_RACE && player->kartstuff[k_balloon] <= 0)
dsone = 26*4 + 2;
else
dsone = 26*4 + player->kartspeed*2 + (9 - player->kartweight);
dstwo = dsone*2;
fixed_t dsone = 26*4 + player->kartspeed*2 + (9 - player->kartweight);
fixed_t dstwo = dsone*2;
// Drifting is actually straffing + automatic turning.
// Holding the Jump button will enable drifting.

View File

@ -6459,15 +6459,8 @@ void P_MobjThinker(mobj_t *mobj)
//{ SRB2kart mobs
case MT_DRIFT:
{
fixed_t dsone;
fixed_t dstwo;
if (gametype != GT_RACE && mobj->target->player->kartstuff[k_balloon] <= 0)
dsone = 26*4 + 2 + (9 - mobj->target->player->kartweight);
else
dsone = 26*4 + mobj->target->player->kartspeed*2 + (9 - mobj->target->player->kartweight);
dstwo = dsone*2;
fixed_t dsone = 26*4 + mobj->target->player->kartspeed*2 + (9 - mobj->target->player->kartweight);
fixed_t dstwo = dsone*2;
if ((mobj->target && mobj->target->player && mobj->target->player->mo && mobj->target->player->health > 0 && !mobj->target->player->spectator)
&& (mobj->type == MT_DRIFT && mobj->target->player->kartstuff[k_driftcharge] >= dsone))
@ -9449,7 +9442,7 @@ void P_SpawnPlayer(INT32 playernum)
if (gametype != GT_RACE)
{
INT32 i;
/*INT32 i;
INT32 pcount = 0;
for (i = 0; i < MAXPLAYERS; i++)
@ -9459,17 +9452,18 @@ void P_SpawnPlayer(INT32 playernum)
if (players[i].jointime > 0)
continue;
pcount++;
}
}*/
if (p->kartstuff[k_balloon] > 0 || leveltime < 1 || pcount <= 1) // srb2kart
if (p->kartstuff[k_balloon] > 0 || leveltime < 1/* || pcount <= 1*/) // srb2kart
{
INT32 i;
angle_t newangle;
angle_t diff;
fixed_t newx;
fixed_t newy;
mobj_t *mo;
if (leveltime < 1 || pcount <= 1) // Start of the map?
if (leveltime < 1 /*|| pcount <= 1*/) // Start of the map?
p->kartstuff[k_balloon] = cv_kartballoons.value; // Reset those balloons!
if (p->kartstuff[k_balloon] <= 1)

View File

@ -1650,6 +1650,8 @@ void P_DoPlayerExit(player_t *player)
if (P_CheckRacers())
player->exiting = (14*TICRATE)/5 + 1;
}
else if (gametype != GT_RACE)
player->exiting = 10*TICRATE + 2; // Accidental death safeguard???
else
player->exiting = (14*TICRATE)/5 + 2; // Accidental death safeguard???