diff --git a/source/core/rendering/hw_sections.cpp b/source/core/rendering/hw_sections.cpp index 2d0673e47..967b08f07 100644 --- a/source/core/rendering/hw_sections.cpp +++ b/source/core/rendering/hw_sections.cpp @@ -246,7 +246,7 @@ static void CollectLoops(TArray& sectors) { // quick check for the only known cause of this in proper maps: // RRRA E1L3 and SW $yamato have a wall duplicate where the duplicate's index is the original's + 1. These can just be deleted here and be ignored. - if (ww > 1 && wall[ww-1].wall_int_pos().X == wall[ww-2].wall_int_pos().X && wall[ww-1].wall_int_pos().Y == wall[ww-2].wall_int_pos().Y && wall[ww-1].point2 == wall[ww-2].point2 && wall[ww - 1].point2 == ww) + if (ww > 1 && wall[ww-1].pos == wall[ww-2].pos && wall[ww-1].point2 == wall[ww-2].point2 && wall[ww - 1].point2 == ww) { thisloop.Clear(); break; diff --git a/source/core/sectorgeometry.cpp b/source/core/sectorgeometry.cpp index ef2d36c8c..b1219419f 100644 --- a/source/core/sectorgeometry.cpp +++ b/source/core/sectorgeometry.cpp @@ -363,8 +363,8 @@ bool SectionGeometry::ValidateSection(Section* section, int plane) ((sec->floorstat ^ compare->floorstat) & (CSTAT_SECTOR_ALIGN | CSTAT_SECTOR_YFLIP | CSTAT_SECTOR_XFLIP | CSTAT_SECTOR_TEXHALF | CSTAT_SECTOR_SWAPXY)) == 0 && sec->floorxpan_ == compare->floorxpan_ && sec->floorypan_ == compare->floorypan_ && - sec->firstWall()->wall_int_pos() == sdata.poscompare[0] && - sec->firstWall()->point2Wall()->wall_int_pos() == sdata.poscompare2[0] && + sec->firstWall()->pos == sdata.poscompare[0] && + sec->firstWall()->point2Wall()->pos == sdata.poscompare2[0] && !(section->dirty & EDirty::FloorDirty) && sdata.planes[plane].vertices.Size() ) return true; section->dirty &= ~EDirty::FloorDirty; @@ -376,15 +376,15 @@ bool SectionGeometry::ValidateSection(Section* section, int plane) ((sec->ceilingstat ^ compare->ceilingstat) & (CSTAT_SECTOR_ALIGN | CSTAT_SECTOR_YFLIP | CSTAT_SECTOR_XFLIP | CSTAT_SECTOR_TEXHALF | CSTAT_SECTOR_SWAPXY)) == 0 && sec->ceilingxpan_ == compare->ceilingxpan_ && sec->ceilingypan_ == compare->ceilingypan_ && - sec->firstWall()->wall_int_pos() == sdata.poscompare[1] && - sec->firstWall()->point2Wall()->wall_int_pos() == sdata.poscompare2[1] && + sec->firstWall()->pos == sdata.poscompare[1] && + sec->firstWall()->point2Wall()->pos == sdata.poscompare2[1] && !(section->dirty & EDirty::CeilingDirty) && sdata.planes[1].vertices.Size()) return true; section->dirty &= ~EDirty::CeilingDirty; } compare->copy(sec); - sdata.poscompare[plane] = sec->firstWall()->wall_int_pos(); - sdata.poscompare2[plane] = sec->firstWall()->point2Wall()->wall_int_pos(); + sdata.poscompare[plane] = sec->firstWall()->pos; + sdata.poscompare2[plane] = sec->firstWall()->point2Wall()->pos; return false; } diff --git a/source/core/sectorgeometry.h b/source/core/sectorgeometry.h index a1afb18b1..9c063540d 100644 --- a/source/core/sectorgeometry.h +++ b/source/core/sectorgeometry.h @@ -58,8 +58,8 @@ struct SectionGeometryData TArray meshVertices; // flat vertices. Stored separately so that plane changes won't require completely new triangulation. TArray meshIndices; sectortypelight compare[2] = {}; - vec2_t poscompare[2] = {}; - vec2_t poscompare2[2] = {}; + DVector2 poscompare[2] = {}; + DVector2 poscompare2[2] = {}; FVector3 normal[2]; };