SW: Copy the sln==1 GetUpperLowerSector case from the editor to the game

This avoids upper and lower remaining unmodified.

Sector 469 in Seppuku Station causes it!

git-svn-id: https://svn.eduke32.com/eduke32@8306 1a8010ca-5511-0410-912e-c29ae57300e0

# Conflicts:
#	source/sw/src/brooms.cpp
This commit is contained in:
hendricks266 2019-11-26 08:24:49 +00:00 committed by Christoph Oelckers
parent a51e91d4e9
commit 9dde07ced9
1 changed files with 9 additions and 2 deletions

View File

@ -846,10 +846,17 @@ GetUpperLowerSector(short match, int x, int y, short *upper, short *lower)
*lower = -1;
return;
}
else
// Map rooms have NOT been dragged on top of each other
else if (sln == 1)
{
*lower = sectorlist[0];
*upper = sectorlist[0];
return;
}
// Map rooms HAVE been dragged on top of each other
// inside will somtimes find that you are in two different sectors if the x,y
// is exactly on a sector line.
if (sln > 2)
else if (sln > 2)
{
//DSPRINTF(ds, "TOO MANY SECTORS FOUND: x=%d, y=%d, match=%d, num sectors %d, %d, %d, %d, %d, %d", x, y, match, sln, sectorlist[0], sectorlist[1], sectorlist[2], sectorlist[3], sectorlist[4]);
MONO_PRINT(ds);