From dacb985878d37ab4e993f93cde67b24ab05635c4 Mon Sep 17 00:00:00 2001 From: Magnus Norddahl Date: Tue, 22 Nov 2016 01:59:28 +0100 Subject: [PATCH] Fix texture mapping bug --- src/r_poly_wall.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/r_poly_wall.cpp b/src/r_poly_wall.cpp index 075a6f2a2..63f35ccd5 100644 --- a/src/r_poly_wall.cpp +++ b/src/r_poly_wall.cpp @@ -314,7 +314,7 @@ void PolyWallTextureCoords::CalcU(FTexture *tex, const seg_t *lineseg, const lin if (!entireSegment) { lineLength = (lineseg->v2->fPos() - lineseg->v1->fPos()).Length(); - lineStart = (lineseg->v1->fPos() - lineseg->v1->fPos()).Length(); + lineStart = (lineseg->v1->fPos() - line->v1->fPos()).Length(); } int texWidth = tex->GetWidth();