Class EntityDrawable
- java.lang.Object
-
- com.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
-
- com.badlogic.gdx.scenes.scene2d.utils.TextureRegionDrawable
-
- com.bombinggames.wurfelengine.mapeditor.EntityDrawable
-
public class EntityDrawable extends com.badlogic.gdx.scenes.scene2d.utils.TextureRegionDrawable
Draw an entity in projection space.
-
-
Constructor Summary
Constructors Constructor Description EntityDrawable(java.lang.Class<? extends AbstractEntity> type)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
draw(com.badlogic.gdx.graphics.g2d.Batch batch, float x, float y, float width, float height)
void
draw(com.badlogic.gdx.graphics.g2d.Batch batch, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)
float
getBottomHeight()
float
getLeftWidth()
float
getMinHeight()
float
getMinWidth()
float
getRightWidth()
float
getTopHeight()
-
Methods inherited from class com.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
getName, setBottomHeight, setLeftWidth, setMinHeight, setMinWidth, setName, setRightWidth, setTopHeight, toString
-
Methods inherited from interface com.badlogic.gdx.scenes.scene2d.utils.Drawable
setBottomHeight, setLeftWidth, setMinHeight, setMinWidth, setRightWidth, setTopHeight
-
-
-
-
Constructor Detail
-
EntityDrawable
public EntityDrawable(java.lang.Class<? extends AbstractEntity> type) throws java.lang.InstantiationException, java.lang.IllegalAccessException, java.lang.NoSuchMethodException, java.lang.IllegalArgumentException, java.lang.reflect.InvocationTargetException
- Parameters:
type
-- Throws:
java.lang.InstantiationException
java.lang.IllegalAccessException
java.lang.NoSuchMethodException
java.lang.reflect.InvocationTargetException
java.lang.IllegalArgumentException
-
-
Method Detail
-
draw
public void draw(com.badlogic.gdx.graphics.g2d.Batch batch, float x, float y, float width, float height)
- Overrides:
draw
in classcom.badlogic.gdx.scenes.scene2d.utils.TextureRegionDrawable
-
draw
public void draw(com.badlogic.gdx.graphics.g2d.Batch batch, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)
- Overrides:
draw
in classcom.badlogic.gdx.scenes.scene2d.utils.TextureRegionDrawable
- Parameters:
batch
-x
-y
-originX
-originY
-width
-height
-scaleX
-scaleY
-rotation
-
-
getLeftWidth
public float getLeftWidth()
- Overrides:
getLeftWidth
in classcom.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- Returns:
-
getRightWidth
public float getRightWidth()
- Overrides:
getRightWidth
in classcom.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- Returns:
-
getTopHeight
public float getTopHeight()
- Overrides:
getTopHeight
in classcom.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- Returns:
-
getBottomHeight
public float getBottomHeight()
- Overrides:
getBottomHeight
in classcom.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- Returns:
-
getMinHeight
public float getMinHeight()
- Overrides:
getMinHeight
in classcom.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- Returns:
-
getMinWidth
public float getMinWidth()
- Overrides:
getMinWidth
in classcom.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- Returns:
-
-