mirror of
https://github.com/DrBeef/Raze.git
synced 2025-01-31 21:20:39 +00:00
- Duke: Wrap calls that set player_struct::PlayerOldPosition.Z
.
This commit is contained in:
parent
4027f7256d
commit
830480b8b9
3 changed files with 7 additions and 2 deletions
|
@ -388,7 +388,7 @@ void DoPlayer(bool bSet, int lVar1, int lLabelID, int lVar2, DDukeActor* sActor,
|
|||
break;
|
||||
|
||||
case PLAYER_OPOSZ:
|
||||
if (bSet) ps[iPlayer].PlayerOldPosition.Z = lValue * zmaptoworld;
|
||||
if (bSet) ps[iPlayer].posoldZset(lValue * zmaptoworld);
|
||||
else SetGameVarID(lVar2, int(ps[iPlayer].PlayerOldPosition.Z * (1 / zmaptoworld)), sActor, sPlayer);
|
||||
break;
|
||||
|
||||
|
|
|
@ -774,7 +774,7 @@ void player_struct::backuppos(bool noclipping)
|
|||
posY() = posoldY();
|
||||
}
|
||||
|
||||
PlayerOldPosition.Z = posZget();
|
||||
posoldZset(posZget());
|
||||
bobpos = posXY();
|
||||
opyoff = pyoff;
|
||||
}
|
||||
|
|
|
@ -413,6 +413,11 @@ struct player_struct
|
|||
{
|
||||
return PlayerOldPosition.XY();
|
||||
}
|
||||
|
||||
void posoldZset(const double val)
|
||||
{
|
||||
PlayerOldPosition.Z = val;
|
||||
}
|
||||
};
|
||||
|
||||
struct Cycler
|
||||
|
|
Loading…
Reference in a new issue