diff --git a/source/games/sw/src/draw.cpp b/source/games/sw/src/draw.cpp index a7abf462d..7bcb5dab6 100644 --- a/source/games/sw/src/draw.cpp +++ b/source/games/sw/src/draw.cpp @@ -825,7 +825,7 @@ void analyzesprites(tspritetype* tsprite, int& spritesortcnt, int viewx, int vie PLAYERp pp = tu->PlayerP; int sr = 65536 - int(smoothratio); tsp->pos.X -= MulScale(pp->pos.X - pp->opos.X, sr, 16); - tsp->pos.Y -= MulScale(pp->pos.Y - pp->oposy, sr, 16); + tsp->pos.Y -= MulScale(pp->pos.Y - pp->opos.Y, sr, 16); tsp->pos.Z -= MulScale(pp->pos.Z - pp->oposz, sr, 16); tsp->ang -= MulScale(pp->angle.ang.asbuild() - pp->angle.oang.asbuild(), sr, 16); } @@ -1459,7 +1459,7 @@ void drawscreen(PLAYERp pp, double smoothratio) camerapp = pp; tx = interpolatedvalue(camerapp->opos.X, camerapp->pos.X, sr); - ty = interpolatedvalue(camerapp->oposy, camerapp->pos.Y, sr); + ty = interpolatedvalue(camerapp->opos.Y, camerapp->pos.Y, sr); tz = interpolatedvalue(camerapp->oposz, camerapp->pos.Z, sr); // Interpolate the player's angle while on a sector object, just like VoidSW. diff --git a/source/games/sw/src/game.h b/source/games/sw/src/game.h index 7fcdfa06b..6a61d5923 100644 --- a/source/games/sw/src/game.h +++ b/source/games/sw/src/game.h @@ -677,7 +677,7 @@ struct PLAYERstruct } // interpolation - int oposy, oposz; + int oposz; // holds last valid move position int lv_x,lv_y,lv_z; diff --git a/source/games/sw/src/jsector.cpp b/source/games/sw/src/jsector.cpp index 9c3544453..5e56bfd9a 100644 --- a/source/games/sw/src/jsector.cpp +++ b/source/games/sw/src/jsector.cpp @@ -641,7 +641,7 @@ void JS_DrawCameras(PLAYERp pp, int tx, int ty, int tz, double smoothratio) // If player is dead still then update at MoveSkip4 // rate. - if (pp->pos.X == pp->opos.X && pp->pos.Y == pp->oposy && pp->pos.Z == pp->oposz) + if (pp->pos.X == pp->opos.X && pp->pos.Y == pp->opos.Y && pp->pos.Z == pp->oposz) DoCam = true; diff --git a/source/games/sw/src/osdcmds.cpp b/source/games/sw/src/osdcmds.cpp index bc6701515..b1ee088f5 100644 --- a/source/games/sw/src/osdcmds.cpp +++ b/source/games/sw/src/osdcmds.cpp @@ -52,7 +52,7 @@ BEGIN_SW_NS void GameInterface::WarpToCoords(int x, int y, int z, int ang, int horz) { Player->opos.X = Player->pos.X = x; - Player->oposy = Player->pos.Y = y; + Player->opos.Y = Player->pos.Y = y; Player->oposz = Player->pos.Z = z; if (ang != INT_MIN) diff --git a/source/games/sw/src/player.cpp b/source/games/sw/src/player.cpp index 40c961551..d367d6da4 100644 --- a/source/games/sw/src/player.cpp +++ b/source/games/sw/src/player.cpp @@ -1281,7 +1281,7 @@ void DoPlayerTeleportToSprite(PLAYERp pp, vec3_t* sp, int ang) { pp->angle.ang = pp->angle.oang = buildang(ang); pp->pos.X = pp->opos.X = pp->oldposx = sp->X; - pp->pos.Y = pp->oposy = pp->oldposy = sp->Y; + pp->pos.Y = pp->opos.Y = pp->oldposy = sp->Y; //getzsofslopeptr(sp->sector(), pp->posx, pp->posy, &cz, &fz); //pp->posz = pp->oposz = fz - PLAYER_HEIGHT; @@ -1295,7 +1295,7 @@ void DoPlayerTeleportToSprite(PLAYERp pp, vec3_t* sp, int ang) void DoPlayerTeleportToOffset(PLAYERp pp) { pp->opos.X = pp->oldposx = pp->pos.X; - pp->oposy = pp->oldposy = pp->pos.Y; + pp->opos.Y = pp->oldposy = pp->pos.Y; updatesector(pp->pos.X, pp->pos.Y, &pp->cursector); SET(pp->Flags2, PF2_TELEPORTED); @@ -2082,7 +2082,7 @@ void DoPlayerMove(PLAYERp pp) if (interpolate_ride) { pp->opos.X = pp->pos.X; - pp->oposy = pp->pos.Y; + pp->opos.Y = pp->pos.Y; } pp->pos.X += pp->xvect >> 14; pp->pos.Y += pp->yvect >> 14; @@ -2109,7 +2109,7 @@ void DoPlayerMove(PLAYERp pp) if (interpolate_ride) { pp->opos.X = pp->pos.X; - pp->oposy = pp->pos.Y; + pp->opos.Y = pp->pos.Y; } auto save_cstat = sp->cstat; @@ -3604,7 +3604,7 @@ void PlayerWarpUpdatePos(PLAYERp pp) return; pp->opos.X = pp->pos.X; - pp->oposy = pp->pos.Y; + pp->opos.Y = pp->pos.Y; pp->oposz = pp->pos.Z; DoPlayerZrange(pp); UpdatePlayerSprite(pp); @@ -4120,7 +4120,7 @@ void DoPlayerWarpToUnderwater(PLAYERp pp) pp->pos.Z = under_sp->sector()->ceilingz + Z(6); pp->opos.X = pp->pos.X; - pp->oposy = pp->pos.Y; + pp->opos.Y = pp->pos.Y; pp->oposz = pp->pos.Z; DoPlayerZrange(pp); @@ -4198,7 +4198,7 @@ void DoPlayerWarpToSurface(PLAYERp pp) pp->pos.Z -= Z(pp->WadeDepth); pp->opos.X = pp->pos.X; - pp->oposy = pp->pos.Y; + pp->opos.Y = pp->pos.Y; pp->oposz = pp->pos.Z; return; @@ -6486,7 +6486,7 @@ void MoveSkipSavePos(void) pp = Player + pnum; pp->opos.X = pp->pos.X; - pp->oposy = pp->pos.Y; + pp->opos.Y = pp->pos.Y; pp->oposz = pp->pos.Z; pp->obob_z = pp->bob_z; pp->angle.backup(); @@ -6826,7 +6826,7 @@ void InitAllPlayers(void) for (pp = Player; pp < &Player[MAX_SW_PLAYERS]; pp++) { pp->pos.X = pp->opos.X = pfirst->pos.X; - pp->pos.Y = pp->oposy = pfirst->pos.Y; + pp->pos.Y = pp->opos.Y = pfirst->pos.Y; pp->pos.Z = pp->oposz = pfirst->pos.Z; pp->angle.ang = pp->angle.oang = pfirst->angle.ang; pp->horizon.horiz = pp->horizon.ohoriz = pfirst->horizon.horiz; @@ -6983,7 +6983,7 @@ void PlayerSpawnPosition(PLAYERp pp) pp->pos.X = pp->opos.X = sp->pos.X; - pp->pos.Y = pp->oposy = sp->pos.Y; + pp->pos.Y = pp->opos.Y = sp->pos.Y; pp->pos.Z = pp->oposz = sp->pos.Z; pp->angle.ang = pp->angle.oang = buildang(sp->ang); pp->setcursector(sp->sector()); diff --git a/source/games/sw/src/save.cpp b/source/games/sw/src/save.cpp index f0b928817..e3334e286 100644 --- a/source/games/sw/src/save.cpp +++ b/source/games/sw/src/save.cpp @@ -581,7 +581,7 @@ FSerializer& Serialize(FSerializer& arc, const char* keyname, PLAYERstruct& w, P if (arc.isReading()) { w.opos.X = w.pos.X; - w.oposy = w.pos.X; + w.opos.Y = w.pos.X; w.oposz = w.pos.X; w.oz_speed = w.z_speed; w.oxvect = w.xvect; diff --git a/source/games/sw/src/sprite.cpp b/source/games/sw/src/sprite.cpp index f7d12569d..03555d194 100644 --- a/source/games/sw/src/sprite.cpp +++ b/source/games/sw/src/sprite.cpp @@ -1532,7 +1532,7 @@ void PreMapCombineFloors(void) pp->pos.X += dx; pp->pos.Y += dy; pp->opos.X = pp->oldposx = pp->pos.X; - pp->oposy = pp->oldposy = pp->pos.Y; + pp->opos.Y = pp->oldposy = pp->pos.Y; break; } } diff --git a/wadsrc/static/zscript/games/sw/swgame.zs b/wadsrc/static/zscript/games/sw/swgame.zs index 3875ae672..7ad69c8e2 100644 --- a/wadsrc/static/zscript/games/sw/swgame.zs +++ b/wadsrc/static/zscript/games/sw/swgame.zs @@ -152,7 +152,7 @@ struct SWPlayer native */ // interpolation - //int oposy, oposz; + //int oposz; // holds last valid move position //int16 lv_sectnum;