Some NiGHTS change oversights I forgot to correct before.

This commit is contained in:
toasterbabe 2016-12-25 19:56:33 +00:00
parent 5164ee7fc9
commit 877065250e
2 changed files with 3 additions and 14 deletions

View file

@ -2200,12 +2200,7 @@ static void ResetNode(INT32 node);
void CL_ClearPlayer(INT32 playernum)
{
if (players[playernum].mo)
{
// Don't leave a NiGHTS ghost!
if ((players[playernum].pflags & PF_NIGHTSMODE) && players[playernum].mo->tracer)
P_RemoveMobj(players[playernum].mo->tracer);
P_RemoveMobj(players[playernum].mo);
}
players[playernum].mo = NULL;
memset(&players[playernum], 0, sizeof (player_t));
}

View file

@ -3920,12 +3920,8 @@ void G_WriteGhostTic(mobj_t *ghost)
if (!(demoflags & DF_GHOST))
return; // No ghost data to write.
if (ghost->player && ghost->player->pflags & PF_NIGHTSMODE && ghost->tracer)
{
// We're talking about the NiGHTS thing, not the normal platforming thing!
if (ghost->player && ghost->player->pflags & PF_NIGHTSMODE) // We're talking about the NiGHTS thing, not the normal platforming thing!
ziptic |= GZT_NIGHTS;
ghost = ghost->tracer;
}
ziptic_p = demo_p++; // the ziptic, written at the end of this function
@ -4107,11 +4103,9 @@ void G_ConsGhostTic(void)
demo_p++;
if (ziptic & GZT_SPR2)
demo_p++;
if(ziptic & GZT_NIGHTS) {
if (!testmo->player || !(testmo->player->pflags & PF_NIGHTSMODE) || !testmo->tracer)
if (ziptic & GZT_NIGHTS) {
if (!testmo->player || !(testmo->player->pflags & PF_NIGHTSMODE))
nightsfail = true;
else
testmo = testmo->tracer;
}
if (ziptic & GZT_EXTRA)