fixed dungeon gen

This commit is contained in:
StevenRS11
2013-06-02 23:49:47 -04:00
parent 004d06ab7d
commit a8ac17f81b
5 changed files with 42 additions and 32 deletions

View File

@@ -182,7 +182,15 @@ public class DungeonGenerator implements Serializable
}
catch(Exception e)
{
dungeon = mod_pocketDim.registeredDungeons.get(rand.nextInt(mod_pocketDim.registeredDungeons.size()));
if(mod_pocketDim.registeredDungeons.size()>0)
{
dungeon = mod_pocketDim.registeredDungeons.get(rand.nextInt(mod_pocketDim.registeredDungeons.size()));
}
else
{
e.printStackTrace();
return;
}
}