Skip to content

Commit

Permalink
libcommon: Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
danij-deng committed Aug 14, 2013
1 parent 1183883 commit ecb3dfe
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
9 changes: 4 additions & 5 deletions doomsday/plugins/common/src/g_game.c
Original file line number Diff line number Diff line change
Expand Up @@ -2312,7 +2312,7 @@ static void G_ApplyGameRules(skillmode_t skill)

#if __JDOOM__ || __JHERETIC__
// Is respawning enabled at all in nightmare skill?
if(skill == SM_NIGHTMARE)
if(gameSkill == SM_NIGHTMARE)
respawnMonsters = cfg.respawnMonstersNightmare;
#endif

Expand Down Expand Up @@ -3050,9 +3050,9 @@ void G_DoSaveGame(void)

void G_DeferredNewGame(skillmode_t skill, uint episode, uint map, uint mapEntryPoint)
{
dSkill = skill;
dEpisode = episode;
dMap = map;
dSkill = skill;
dEpisode = episode;
dMap = map;
dMapEntryPoint = mapEntryPoint;

G_SetGameAction(GA_NEWGAME);
Expand Down Expand Up @@ -3105,7 +3105,6 @@ void G_NewGame(skillmode_t skill, uint episode, uint map, uint mapEntryPoint)
// Make sure that the episode and map numbers are good.
G_ValidateMap(&episode, &map);

gameSkill = skill;
gameEpisode = episode;
gameMap = map;
gameMapEntryPoint = mapEntryPoint;
Expand Down
2 changes: 2 additions & 0 deletions doomsday/plugins/common/src/p_saveg.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5136,6 +5136,8 @@ static int SV_LoadState(Str const *path, SaveInfo *saveInfo)

gameEpisode = hdr->episode - 1;
gameMap = hdr->map - 1;

// Apply the game rules:
#if __JHEXEN__
gameSkill = skillmode_t( hdr->skill );
#else
Expand Down

0 comments on commit ecb3dfe

Please sign in to comment.