Interface IMapObject
- All Superinterfaces:
Comparable<Resource>,ICustomPropertyProvider,Resource
This interface represents an instance on a map that can define various things for an engine. e.g. it can be used to
define static collision boxes or other special regions on the map.
-
Method Summary
Modifier and TypeMethodDescriptionGets the hit box.intGets the grid id.floatintgetId()Gets the id.getLayer()Gets the location.getText()getTile()getType()floatgetWidth()floatgetX()floatgetY()booleanbooleanisPoint()booleanbooleanvoidsetGridId(int gid) voidsetHeight(float height) voidsetId(int id) voidsetLocation(float x, float y) voidsetLocation(Point2D location) voidsetPolygon(IPolyShape polygon) voidsetPolyline(IPolyShape polyline) voidvoidsetWidth(float width) voidsetX(float x) voidsetY(float y) Methods inherited from interface de.gurkenlabs.litiengine.environment.tilemap.ICustomPropertyProvider
getBoolValue, getBoolValue, getByteValue, getByteValue, getCharValue, getCharValue, getColorValue, getColorValue, getCommaSeparatedStringValues, getDoubleValue, getDoubleValue, getEnumValue, getEnumValue, getFileValue, getFileValue, getFloatValue, getFloatValue, getIntValue, getIntValue, getLongValue, getLongValue, getMapObjectId, getProperties, getProperty, getShortValue, getShortValue, getStringValue, getStringValue, hasCustomProperty, removeProperty, setProperties, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue, setValue
-
Method Details
-
getGridId
int getGridId()Gets the grid id.- Returns:
- the grid id
-
getTile
ITilesetEntry getTile() -
getBoundingBox
Rectangle2D getBoundingBox()Gets the hit box.- Returns:
- the hit box
-
getId
int getId()Gets the id.- Returns:
- the id
-
getLocation
Point2D getLocation()Gets the location.- Returns:
- the location
-
getType
String getType() -
getPolyline
IPolyShape getPolyline() -
getPolygon
IPolyShape getPolygon() -
getEllipse
Ellipse2D getEllipse() -
getText
IMapObjectText getText() -
getLayer
IMapObjectLayer getLayer() -
setGridId
void setGridId(int gid) -
setId
void setId(int id) -
setType
-
setX
void setX(float x) -
setY
void setY(float y) -
setLocation
-
setLocation
void setLocation(float x, float y) -
setWidth
void setWidth(float width) -
setHeight
void setHeight(float height) -
getX
float getX() -
getY
float getY() -
getWidth
float getWidth() -
getHeight
float getHeight() -
isPolyline
boolean isPolyline() -
isPolygon
boolean isPolygon() -
isPoint
boolean isPoint() -
isEllipse
boolean isEllipse() -
setPolyline
-
setPolygon
-