From fcf04a7df169ad36e672cf203dbaae2ed5112d71 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Thu, 13 Jan 2022 00:50:16 +0100 Subject: [PATCH] - delete unused variable. --- source/core/rendering/scene/hw_drawstructs.h | 1 - source/core/rendering/scene/hw_walls.cpp | 12 ++++-------- source/games/duke/src/constants.h | 1 + 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/source/core/rendering/scene/hw_drawstructs.h b/source/core/rendering/scene/hw_drawstructs.h index 4d1611bfe..3be4e20a2 100644 --- a/source/core/rendering/scene/hw_drawstructs.h +++ b/source/core/rendering/scene/hw_drawstructs.h @@ -164,7 +164,6 @@ public: float ViewDistance; float visibility; walltype* walldist; - FVector2 wallpoint; short shade, palette; PalEntry fade; diff --git a/source/core/rendering/scene/hw_walls.cpp b/source/core/rendering/scene/hw_walls.cpp index d5fdac62f..1c78348ca 100644 --- a/source/core/rendering/scene/hw_walls.cpp +++ b/source/core/rendering/scene/hw_walls.cpp @@ -50,6 +50,10 @@ DCoreActor* wall_to_sprite_actors[8]; // gets updated each frame. Todo: Encapsul static walltype* IsOnWall(tspritetype* tspr, int height, DVector2& outpos) { + if (tspr->picnum == 164) + { + return nullptr; + } const double maxdistsq = (tspr->ang & 0x1ff)? 3 * 3 : 1; // lower tolerance for perfectly orthogonal sprites auto sect = tspr->sectp; @@ -177,13 +181,6 @@ void HWWall::RenderMirrorSurface(HWDrawInfo *di, FRenderState &state) void HWWall::RenderTexturedWall(HWDrawInfo *di, FRenderState &state, int rflags) { -#ifdef _DEBUG - if (seg && (wallnum(seg) == 929 || wallnum(seg) == 930)) - { - int a = 0; - } -#endif - SetLightAndFog(di, state, fade, palette, shade, visibility, alpha); state.SetMaterial(texture, UF_Texture, 0, (flags & (HWF_CLAMPX | HWF_CLAMPY)), TRANSLATION(Translation_Remap + curbasepal, palette), -1); @@ -1123,7 +1120,6 @@ void HWWall::ProcessWallSprite(HWDrawInfo* di, tspritetype* spr, sectortype* sec DVector2 vec{}; walldist = IsOnWall(spr, height, vec); - wallpoint = { float(vec.X * (1 / 16.f)), float(vec.Y * (-1 / 16.f)) }; if (walldist) { // project the sprite right onto the wall. diff --git a/source/games/duke/src/constants.h b/source/games/duke/src/constants.h index cc8bf1c64..f713580c4 100644 --- a/source/games/duke/src/constants.h +++ b/source/games/duke/src/constants.h @@ -316,6 +316,7 @@ enum sflags_t SFLAG_TRIGGER_IFHITSECTOR = 0x00008000, SFLAG_MOVEFTA_WAKEUPCHECK = 0x00010000, SFLAG_MOVEFTA_CHECKSEEWITHPAL8 = 0x00020000, // let's hope this can be done better later. For now this was what blocked merging the Duke and RR variants of movefta + SFLAG_NOSHADOW = 0x00020000, };