Beispiel #1
0
        public String getDungeonName()
        {
            int            lairs = 0;
            MonsterCounter mc    = new MonsterCounter();

            for (int i = 1; i <= this.getNumRooms(); ++i)
            {
                Room room = this.getRoom(i);
                if (room.isLair())
                {
                    lairs++;
                    Monster lair = room.createMonster();
                    mc.countMonster(lair);
                }
            }
            return(mc.toString());
//		return lairs + " lairs";
        }