- Changed singleplayer allowrespawn to act like a co-op game when you
change levels while dead by immediately respawning you before the switch so that you get to keep all your inventory. - Fixed: G_InitLevelLocals() did not set flags2. SVN r1406 (trunk)
This commit is contained in:
parent
cccdfd6336
commit
64b783f4bd
3 changed files with 9 additions and 2 deletions
|
|
@ -605,7 +605,7 @@ void G_ChangeLevel(const char *levelname, int position, bool keepFacing, int nex
|
|||
|
||||
// If this is co-op, respawn any dead players now so they can
|
||||
// keep their inventory on the next map.
|
||||
if (multiplayer && !deathmatch && player->playerstate == PST_DEAD)
|
||||
if ((multiplayer || level.flags2 & LEVEL2_ALLOWRESPAWN) && !deathmatch && player->playerstate == PST_DEAD)
|
||||
{
|
||||
// Copied from the end of P_DeathThink [[
|
||||
player->cls = NULL; // Force a new class if the player is using a random class
|
||||
|
|
@ -1270,6 +1270,7 @@ void G_InitLevelLocals ()
|
|||
level.cluster = info->cluster;
|
||||
level.clusterflags = clus ? clus->flags : 0;
|
||||
level.flags |= info->flags;
|
||||
level.flags2 |= info->flags2;
|
||||
level.levelnum = info->levelnum;
|
||||
level.Music = info->Music;
|
||||
level.musicorder = info->musicorder;
|
||||
|
|
@ -1296,6 +1297,7 @@ void G_InitLevelLocals ()
|
|||
strcpy (level.skypic1, "SKY1");
|
||||
strcpy (level.skypic2, "SKY1");
|
||||
level.flags = 0;
|
||||
level.flags2 = 0;
|
||||
level.levelnum = 1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue