Package com.hobbitsadventure.model

Examples of com.hobbitsadventure.model.Thing


        Tile tile = realmMap.getTile(rowIndex, colIndex);
        int x = (j - minJ) * TILE_WIDTH;
        tile.paint(g, x, baseY);
       
        // Paint thing if it's occluded by subsequent tile roles
        Thing thing = realmMap.getThing(rowIndex, colIndex);
        if (thing != null && thing.isOccludedByTerrain()) {
          int y = baseY - 65 + tile.getHeight();
          g.drawImage(thing.getSprite(), x, y, null);
        }
      }
    }
  }
View Full Code Here


        Tile tile = realmMap.getTile(rowIndex, colIndex);
        int x = (j - minJ) * TILE_WIDTH;
        int y = baseY - 65 + tile.getHeight();
       
        // Paint thing (if we haven't already)
        Thing thing = realmMap.getThing(rowIndex, colIndex);
        if (thing != null && !thing.isOccludedByTerrain()) {
          g.drawImage(thing.getSprite(), x, y, null);
         
        }
       
        // Paint character
        GameCharacter character = realmMap.getCharacter(rowIndex, colIndex);
        if (character != null) {
          if (thing != null) { y += thing.getYOffset(); }
          g.drawImage(character.getSprite(), x, y, null);
        }
      }
    }
  }
View Full Code Here

    while ((rowStr = br.readLine()) != null) {
      int numCols = rowStr.length();
      RealmCell[] row = new RealmCell[numCols];
      for (int j = 0; j < numCols; j++) {
        TileClass tileClass = null;
        Thing thing = null;
        int heightNoise = 0;
       
        char ch = rowStr.charAt(j);
        switch (ch) {
        case '.':
View Full Code Here

TOP

Related Classes of com.hobbitsadventure.model.Thing

Copyright © 2018 www.massapicom. 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.