com.badlogic.gdx.maps.tiled
Class TiledMapTileLayer

java.lang.Object
  extended by com.badlogic.gdx.maps.MapLayer
      extended by com.badlogic.gdx.maps.tiled.TiledMapTileLayer

public class TiledMapTileLayer
extends MapLayer


Nested Class Summary
static class TiledMapTileLayer.Cell
           
 
Constructor Summary
TiledMapTileLayer(int width, int height, int tileWidth, int tileHeight)
          Creates TiledMap layer
 
Method Summary
 TiledMapTileLayer.Cell getCell(int x, int y)
           
 int getHeight()
           
 float getTileHeight()
           
 float getTileWidth()
           
 int getWidth()
           
 void setCell(int x, int y, TiledMapTileLayer.Cell cell)
          Sets the TiledMapTileLayer.Cell at the given coordinates.
 
Methods inherited from class com.badlogic.gdx.maps.MapLayer
getName, getObjects, getOpacity, getProperties, isVisible, setName, setOpacity, setVisible
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TiledMapTileLayer

public TiledMapTileLayer(int width,
                         int height,
                         int tileWidth,
                         int tileHeight)
Creates TiledMap layer

Parameters:
width - layer width in tiles
height - layer height in tiles
tileWidth - tile width in pixels
tileHeight - tile height in pixels
Method Detail

getWidth

public int getWidth()
Returns:
layer's witdth in tiles

getHeight

public int getHeight()
Returns:
layer's height in tiles

getTileWidth

public float getTileWidth()
Returns:
tiles' width in pixels

getTileHeight

public float getTileHeight()
Returns:
tiles' height in pixels

getCell

public TiledMapTileLayer.Cell getCell(int x,
                                      int y)
Parameters:
x -
y -
Returns:
cell at (x, y)

setCell

public void setCell(int x,
                    int y,
                    TiledMapTileLayer.Cell cell)
Sets the TiledMapTileLayer.Cell at the given coordinates.

Parameters:
x -
y -
cell -


Copyright © 2013. All Rights Reserved.