- fix automap cheat to avoid division by 0.

git-svn-id: http://mancubus.net/svn/hosted/gzdoom/trunk@788 b0f79afe-0144-0410-b225-9a4edf0717df
This commit is contained in:
Christoph Oelckers 2010-05-01 20:34:42 +00:00
parent f0ed61f588
commit e018761cb8

View file

@ -185,7 +185,7 @@ CUSTOM_CVAR (Int, am_showalllines, -1, 0) // This is a cheat so don't save it.
{
int flagged = 0;
int total = 0;
if (self > 0)
if (self > 0 && numlines > 0)
{
for(int i=0;i<numlines;i++)
{