Examples of Dungeon


Examples of info.pello.tooomb.Dungeon

  @Test
  /**
   * test if newly created Dungeons have expected name
   */
  public void testNew() {
    testedDungeon = new Dungeon();
    assertEquals("Default dungeon name ok.",testedDungeon.getName(),"Dark Dungeon");
    String name = "Terror Dungeon";
    testedDungeon = new Dungeon(name);
    assertEquals("Set dungeon name and is ok.",testedDungeon.getName(),name);
  }
View Full Code Here

Examples of info.pello.tooomb.Dungeon

  @Test
  /**
   * test if Dungeons newly created Dungeons haven't exit
   */
  public void testNoExit() {
      testedDungeon = new Dungeon();
      assertFalse("Dungeons have no exit",testedDungeon.isExit());
  }
View Full Code Here

Examples of info.pello.tooomb.Dungeon

  /**
   * test if Dungeons have damage points within limits.
   */
  public void testDamage() {
    for (int i = 0; i < 100; i++) {
      testedDungeon = new Dungeon();
      assertTrue("Dungeon damage between 0 and 6",testedDungeon.getDamage()>= 0 && testedDungeon.getDamage() < 6);
    }
  }
View Full Code Here

Examples of net.bytten.metazelda.Dungeon

                        constraints.getMaxKeys();
                } else {
                    roomsPerLock = constraints.getMaxRooms();
                }
                while (true) {
                    dungeon = new Dungeon();
                   
                    // Maps keyLevel -> Rooms that were created when lockCount had that
                    // value
                    levels = new KeyLevelRoomMapping();
                   
View Full Code Here

Examples of net.bytten.metazelda.Dungeon

    @Override
    public void generate() {
        int attempts = 0, currentNonlinearity = Integer.MAX_VALUE;
        int bestAttempt = 0;
        Dungeon currentBest = null;
        while (attempts++ < MAX_ATTEMPTS) {
            super.generate();
           
            int nonlinearity = measureNonlinearity();
            log("Dungeon " + attempts + " nonlinearity: "+
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.