Line special 2003: respawn player if crossing this line

This commit is contained in:
James R 2021-02-04 18:40:50 -08:00
parent 090daaac02
commit 8c047372a6
2 changed files with 10 additions and 0 deletions

View file

@ -213,6 +213,7 @@ static boolean P_SpecialIsLinedefCrossType(UINT16 ldspecial)
switch (ldspecial)
{
case 2001: // Finish line
case 2003: // Respawn line
{
linedefcrossspecial = true;
}

View file

@ -2182,6 +2182,13 @@ void P_CrossSpecialLine(line_t *line, INT32 side, mobj_t *thing)
}
break;
case 2003: // Respawn Line
{
if (player->respawn.state == RESPAWNST_NONE)
P_DamageMobj(player->mo, NULL, NULL, 1, DMG_DEATHPIT);
}
break;
default:
{
// Do nothing
@ -6939,6 +6946,8 @@ void P_SpawnSpecials(boolean fromnetsave)
break;
case 2002: // Linedef Trigger: Race Lap
break;
case 2003: // Respawn Line
break;
default:
break;