mirror of
https://github.com/DrBeef/Raze.git
synced 2025-01-19 07:31:03 +00:00
- SW: clear all pointer variables the player may still hold when terminating a level.
This commit is contained in:
parent
34bee8116c
commit
46d7487a3b
2 changed files with 8 additions and 1 deletions
|
@ -79,7 +79,6 @@ void StatusMessage(int messageTime, const char *fmt, ...);
|
|||
|
||||
void DoSpiritHead();
|
||||
|
||||
void GameTicker();
|
||||
void InitLevel(MapRecord*);
|
||||
void InitNewGame();
|
||||
|
||||
|
|
|
@ -545,8 +545,16 @@ void TerminateLevel(void)
|
|||
// Free panel sprites for players
|
||||
pClearSpriteList(pp);
|
||||
|
||||
// clear *all* pointers in Player!
|
||||
pp->remote = {};
|
||||
pp->sop = pp->sop_remote = nullptr;
|
||||
pp->LadderSector = nullptr;
|
||||
pp->cookieTime = 0;
|
||||
pp->hi_sectp = pp->lo_sectp = nullptr;
|
||||
pp->cursector = pp->lastcursector = pp->lv_sector = nullptr;
|
||||
pp->sop_control = pp->sop_riding = nullptr;
|
||||
pp->PanelSpriteList = {};
|
||||
|
||||
memset(pp->cookieQuote, 0, sizeof(pp->cookieQuote));
|
||||
pp->DoPlayerAction = nullptr;
|
||||
|
||||
|
|
Loading…
Reference in a new issue