mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-13 16:07:40 +00:00
- Make player unmorphing the first thing that happens in G_PlayerFinishLevel() so that all
inventory fiddling happens on the real player and not the morphed player. SVN r3619 (trunk)
This commit is contained in:
parent
9d4ba3c7fd
commit
11bf757a2f
1 changed files with 5 additions and 5 deletions
|
@ -1208,6 +1208,11 @@ void G_PlayerFinishLevel (int player, EFinishLevelType mode, int flags)
|
||||||
|
|
||||||
p = &players[player];
|
p = &players[player];
|
||||||
|
|
||||||
|
if (p->morphTics != 0)
|
||||||
|
{ // Undo morph
|
||||||
|
P_UndoPlayerMorph (p, p, 0, true);
|
||||||
|
}
|
||||||
|
|
||||||
// Strip all current powers, unless moving in a hub and the power is okay to keep.
|
// Strip all current powers, unless moving in a hub and the power is okay to keep.
|
||||||
item = p->mo->Inventory;
|
item = p->mo->Inventory;
|
||||||
while (item != NULL)
|
while (item != NULL)
|
||||||
|
@ -1276,11 +1281,6 @@ void G_PlayerFinishLevel (int player, EFinishLevelType mode, int flags)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (p->morphTics)
|
|
||||||
{ // Undo morph
|
|
||||||
P_UndoPlayerMorph (p, p, 0, true);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Resets player health to default if not dead.
|
// Resets player health to default if not dead.
|
||||||
if ((flags & CHANGELEVEL_RESETHEALTH) && p->playerstate != PST_DEAD)
|
if ((flags & CHANGELEVEL_RESETHEALTH) && p->playerstate != PST_DEAD)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue