"Promote" oob sectnum/statnum sprites to corruption level 4.

Also, always print at least level 5 corruptions (that is, have no instances
of completely silent corruptcheck).

git-svn-id: https://svn.eduke32.com/eduke32@2490 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2012-03-17 11:34:54 +00:00
parent 4042fa90c4
commit 5246f17169

View file

@ -542,7 +542,7 @@ void create_map_snapshot(void)
}
}
CheckMapCorruption(6, 0);
CheckMapCorruption(5, 0);
}
void map_undoredo_free(void)
@ -11234,7 +11234,7 @@ void ExtCheckKeys(void)
#if M32_UNDO
create_map_snapshot();
#else
CheckMapCorruption(6, 0);
CheckMapCorruption(5, 0);
#endif
asksave++;
}
@ -11246,7 +11246,7 @@ void ExtCheckKeys(void)
{
if (asksave == 4)
{
if (CheckMapCorruption(6, 0)>=4)
if (CheckMapCorruption(5, 0)>=4)
{
SaveBoard("autosave_corrupt.map", 1);
message("Board autosaved to AUTOSAVE_CORRUPT.MAP");
@ -11869,7 +11869,10 @@ int32_t CheckMapCorruption(int32_t printfromlev, uint64_t tryfixing)
continue;
if (sprite[i].sectnum<0 || sprite[i].sectnum>=numsectors)
CORRUPTCHK_PRINT(2, CORRUPT_SPRITE|i, "SPRITE[%d].SECTNUM=%d. Expect problems!", i, sprite[i].sectnum);
CORRUPTCHK_PRINT(4, CORRUPT_SPRITE|i, "SPRITE[%d].SECTNUM=%d. Expect problems!", i, sprite[i].sectnum);
if (sprite[i].statnum<0 || sprite[i].statnum>MAXSTATUS)
CORRUPTCHK_PRINT(4, CORRUPT_SPRITE|i, "SPRITE[%d].STATNUM=%d. Expect problems!", i, sprite[i].statnum);
if (sprite[i].picnum<0 || sprite[i].picnum>=MAXTILES)
{