- Duke: Replace player_struct exitx with exit.X calls.

This commit is contained in:
Mitchell Richters 2021-12-30 22:37:32 +11:00
parent 19a9fc462f
commit 8d2595ea84
8 changed files with 10 additions and 10 deletions

View file

@ -296,8 +296,8 @@ void DoPlayer(bool bSet, int lVar1, int lLabelID, int lVar2, DDukeActor* sActor,
break;
case PLAYER_EXITX:
if (bSet) ps[iPlayer].exitx = lValue;
else SetGameVarID(lVar2, ps[iPlayer].exitx, sActor, sPlayer);
if (bSet) ps[iPlayer].exit.X = lValue;
else SetGameVarID(lVar2, ps[iPlayer].exit.X, sActor, sPlayer);
break;
case PLAYER_EXITY:

View file

@ -1072,7 +1072,7 @@ DEFINE_FIELD_X(DukePlayer, player_struct, orandom_club_frame)
DEFINE_FIELD_X(DukePlayer, player_struct, hard_landing)
DEFINE_FIELD_X(DukePlayer, player_struct, ohard_landing)
DEFINE_FIELD_X(DukePlayer, player_struct, psectlotag)
DEFINE_FIELD_X(DukePlayer, player_struct, exitx)
//DEFINE_FIELD_X(DukePlayer, player_struct, exitx)
DEFINE_FIELD_X(DukePlayer, player_struct, exity)
DEFINE_FIELD_X(DukePlayer, player_struct, loogiex)
DEFINE_FIELD_X(DukePlayer, player_struct, loogiey)

View file

@ -716,7 +716,7 @@ void prelevel_common(int g)
if (sectp->lotag == -1)
{
ps[0].exitx = sectp->firstWall()->pos.X;
ps[0].exit.X = sectp->firstWall()->pos.X;
ps[0].exity = sectp->firstWall()->pos.Y;
continue;
}

View file

@ -289,7 +289,7 @@ void prelevel_d(int g, TArray<DDukeActor*>& actors)
if (ac->spr.lotag == -1 && (ac->spr.cstat & CSTAT_SPRITE_ALIGNMENT_WALL))
{
ps[0].exitx = ac->spr.pos.X;
ps[0].exit.X = ac->spr.pos.X;
ps[0].exity = ac->spr.pos.Y;
}
else switch (ac->spr.picnum)

View file

@ -533,7 +533,7 @@ void prelevel_r(int g, TArray<DDukeActor*>& actors)
if (ac->spr.lotag == -1 && (ac->spr.cstat & CSTAT_SPRITE_ALIGNMENT_WALL))
{
ps[0].exitx = ac->spr.pos.X;
ps[0].exit.X = ac->spr.pos.X;
ps[0].exity = ac->spr.pos.Y;
}
else switch (ac->spr.picnum)

View file

@ -116,7 +116,7 @@ FSerializer& Serialize(FSerializer& arc, const char* keyname, player_struct& w,
("pals", w.pals)
("fricx", w.fric.X)
("fricy", w.fric.Y)
("exitx", w.exitx)
("exitx", w.exit.X)
("exity", w.exity)
("numloogs", w.numloogs)
("loogcnt", w.loogcnt)

View file

@ -187,7 +187,7 @@ struct player_struct
PalEntry pals;
// this was a global variable originally.
vec2_t fric;
vec2_t fric, exit;
// weapon drawer variables and their interpolation counterparts.
int weapon_sway;
@ -201,7 +201,7 @@ struct player_struct
short psectlotag;
// From here on it is unaltered from JFDuke with the exception of a few fields that are no longer needed and were removed.
int exitx, exity, loogiex[64], loogiey[64], numloogs, loogcnt;
int exity, loogiex[64], loogiey[64], numloogs, loogcnt;
int invdisptime;
int bobposx, bobposy, pyoff, opyoff;
int last_pissed_time, truefz, truecz;

View file

@ -150,7 +150,7 @@ struct DukePlayer
native int16 psectlotag;
// From here on it is unaltered from JFDuke with the exception of a few fields that are no longer needed and were removed.
native int exitx, exity, loogiex[64], loogiey[64], numloogs, loogcnt;
native int exity, loogiex[64], loogiey[64], numloogs, loogcnt;
native int invdisptime;
native int bobposx, bobposy, pyoff, opyoff;
native int last_pissed_time, truefz, truecz;