(deli, do_demo, lnd_sweep, guerrilla): Saturate items at ITEM_MAX.

With variables, item increases beyond the capacity of variables
(65535) were ignored here.

This should cover all item changes not going through putvec().
This commit is contained in:
Markus Armbruster 2004-03-05 06:48:57 +00:00
parent 95ef2b139d
commit 58e93c0ea3
4 changed files with 10 additions and 4 deletions

View file

@ -101,7 +101,8 @@ deli(void)
if (!check_sect_ok(&sect))
continue;
del = thresh + dir;
thresh = min(thresh, ITEM_MAX) & ~7;
del = thresh | dir;
sect.sct_del[ich->i_vtype] = del;
putsect(&sect);
}