From 52c8a82283eb204704d6500ce29d04992eb618eb Mon Sep 17 00:00:00 2001 From: Luke Street Date: Tue, 31 May 2022 20:51:14 -0400 Subject: [PATCH] CMapArea: Fix incorrect pointer punning --- Runtime/AutoMapper/CMapArea.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Runtime/AutoMapper/CMapArea.cpp b/Runtime/AutoMapper/CMapArea.cpp index 0b99daf0e..8168ad9e6 100644 --- a/Runtime/AutoMapper/CMapArea.cpp +++ b/Runtime/AutoMapper/CMapArea.cpp @@ -273,12 +273,11 @@ void CMapArea::CMapAreaSurface::Draw(const zeus::CVector3f* verts, const zeus::C if (lineColor.a()) { bool draw2 = lineWidth > 1.f; - u32 outlineCount = *reinterpret_cast(&x1c_outlineOffset); + u32 outlineCount = *reinterpret_cast(x1c_outlineOffset); #if METAFORCE_TARGET_BYTE_ORDER == __ORDER_LITTLE_ENDIAN__ outlineCount = CBasics::SwapBytes(outlineCount); #endif - std::vector& linePrims = instance.m_linePrims; zeus::CColor color = lineColor; if (draw2)