Blood: fixed packSlots being cleared on loading a savegame.

Since the player refactor the order of operations had changed and this got called after reading the player, not before.
This commit is contained in:
Christoph Oelckers 2023-10-31 16:32:24 +01:00
parent 8545a2e74d
commit c64d333379
2 changed files with 3 additions and 3 deletions

View file

@ -391,6 +391,7 @@ void StartLevel(MapRecord* level, bool newgame)
//
//
//---------------------------------------------------------------------------
void packClear(DBloodPlayer* pPlayer);
void NewLevel(MapRecord *sng, int skill, bool newgame)
{
@ -403,6 +404,8 @@ void GameInterface::NewGame(MapRecord *sng, int skill, bool)
{
gGameOptions.uGameFlags = 0;
cheatReset();
DBloodPlayer* pPlayer = getPlayer(myconnectindex);
packClear(pPlayer);
NewLevel(sng, skill, true);
}

View file

@ -512,11 +512,8 @@ static cheatseq_t s_CheatInfo[] = {
void cheatReset(void)
{
DBloodPlayer* pPlayer = getPlayer(myconnectindex);
bPlayerCheated = 0;
playerSetGodMode(pPlayer, 0);
gNoClip = 0;
packClear(pPlayer);
gInfiniteAmmo = 0;
gFullMap = 0;
}