From ffba7996b377abb005c6187614af6a9af90c91db Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Tue, 30 Aug 2022 21:33:24 +0200 Subject: [PATCH] - SW: floatified PLAYER::siang --- source/games/sw/src/draw.cpp | 4 ++-- source/games/sw/src/game.h | 2 +- wadsrc/static/zscript/games/sw/swgame.zs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/source/games/sw/src/draw.cpp b/source/games/sw/src/draw.cpp index 17a95756c..fecc22286 100644 --- a/source/games/sw/src/draw.cpp +++ b/source/games/sw/src/draw.cpp @@ -767,7 +767,7 @@ void analyzesprites(tspriteArray& tsprites, int viewx, int viewy, int viewz, int pos.Z = tsp->pos.Z + pp->si.Z; tsp->pos = pos; - tsp->set_int_ang(pp->siang); + tsp->angle = pp->siang; //continue; } else @@ -1414,7 +1414,7 @@ void drawscreen(PLAYER* pp, double smoothratio, bool sceneonly) pp->si.X = tx * inttoworld; pp->si.Y = ty * inttoworld; pp->si.Z = tz * zinttoworld - pp->pos.Z; - pp->siang = tang.Buildang(); + pp->siang = tang; QuakeViewChange(camerapp, &quake_z, &quake_x, &quake_y, &quake_ang); int vis = g_visibility; diff --git a/source/games/sw/src/game.h b/source/games/sw/src/game.h index c04ec59d3..0bdf183ea 100644 --- a/source/games/sw/src/game.h +++ b/source/games/sw/src/game.h @@ -655,7 +655,7 @@ struct PLAYER int circle_camera_dist; DVector3 si; // save player interp position for PlayerSprite - int16_t siang; + DAngle siang; vec2_t vect, ovect, slide_vect; int friction; diff --git a/wadsrc/static/zscript/games/sw/swgame.zs b/wadsrc/static/zscript/games/sw/swgame.zs index 18c26d53e..e0315c3f3 100644 --- a/wadsrc/static/zscript/games/sw/swgame.zs +++ b/wadsrc/static/zscript/games/sw/swgame.zs @@ -194,7 +194,7 @@ struct SWPlayer native native double hiz,loz; native int p_ceiling_dist,p_floor_dist; native int circle_camera_dist; - native int16 siang; + native double siang; native int friction; native int16 slide_ang;