From 1402a6d70b9911eeac42c812949ad64d16444601 Mon Sep 17 00:00:00 2001 From: helixhorned Date: Sat, 26 Nov 2011 14:12:30 +0000 Subject: [PATCH] corruption checker: catch TROR-nextwalls in non-extended sectors. These can be caused by copying map parts from one map to another (or a new one). The copying system is slightly broken right now.... git-svn-id: https://svn.eduke32.com/eduke32@2133 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/source/astub.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/polymer/eduke32/source/astub.c b/polymer/eduke32/source/astub.c index e7312a202..a3f93b375 100644 --- a/polymer/eduke32/source/astub.c +++ b/polymer/eduke32/source/astub.c @@ -11640,7 +11640,6 @@ int32_t CheckMapCorruption(int32_t printfromlev, uint64_t tryfixing) ynextwallok = 0; } - if (!ynextwallok) { int16_t bunchnum = yax_getbunch(i, cf); int32_t onumct = numcorruptthings; @@ -11648,16 +11647,18 @@ int32_t CheckMapCorruption(int32_t printfromlev, uint64_t tryfixing) if (bunchnum < 0 || bunchnum >= numyaxbunches) { CORRUPTCHK_PRINT(4, CORRUPT_WALL|j, "WALL %d has %s=%d, " - "but its bunchnum(%d)=%d is invalid\n", - j, YUPDOWNWALL[cf], ynw, cf, bunchnum); + "but its %s bunchnum=%d is invalid\n", + j, YUPDOWNWALL[cf], ynw, + cf==YAX_CEILING? "ceiling":"floor", bunchnum); } - else if (onumct < MAXCORRUPTTHINGS) + else if (!ynextwallok && onumct < MAXCORRUPTTHINGS) { if ((tryfixing & (1ull<=printfromlev) correct_yax_nextwall(j, bunchnum, cf, tryfixing!=0ull); } } - else + + if (ynextwallok) { int32_t onumct = numcorruptthings;