diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2014-09-19 15:47:14 +0200 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2014-09-19 15:47:14 +0200 |
commit | cde5813835a5c61fff1c556346170400d1b66960 (patch) | |
tree | c9f2d936e300aed0d2696e54121dbe66442c7795 /core/src/ch/asynk/tankontank/engine/gfx | |
parent | 21e328d9cd7445b068622af9e516eef974510336 (diff) | |
download | RustAndDust-cde5813835a5c61fff1c556346170400d1b66960.zip RustAndDust-cde5813835a5c61fff1c556346170400d1b66960.tar.gz |
Drawable: add drawDebug(ShapeRenderer), call it from Layer drawDebug(ShapeRenderer)
Diffstat (limited to 'core/src/ch/asynk/tankontank/engine/gfx')
-rw-r--r-- | core/src/ch/asynk/tankontank/engine/gfx/AbstractDrawable.java | 4 | ||||
-rw-r--r-- | core/src/ch/asynk/tankontank/engine/gfx/Drawable.java | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/core/src/ch/asynk/tankontank/engine/gfx/AbstractDrawable.java b/core/src/ch/asynk/tankontank/engine/gfx/AbstractDrawable.java index 5d4705c..bfafb38 100644 --- a/core/src/ch/asynk/tankontank/engine/gfx/AbstractDrawable.java +++ b/core/src/ch/asynk/tankontank/engine/gfx/AbstractDrawable.java @@ -1,6 +1,7 @@ package ch.asynk.tankontank.engine.gfx; import com.badlogic.gdx.graphics.Color; +import com.badlogic.gdx.graphics.glutils.ShapeRenderer; public abstract class AbstractDrawable implements Drawable { @@ -24,6 +25,9 @@ public abstract class AbstractDrawable implements Drawable } @Override + public void drawDebug(ShapeRenderer debugShapes) {} + + @Override public float getWidth() { return w; diff --git a/core/src/ch/asynk/tankontank/engine/gfx/Drawable.java b/core/src/ch/asynk/tankontank/engine/gfx/Drawable.java index 8b700df..075c33d 100644 --- a/core/src/ch/asynk/tankontank/engine/gfx/Drawable.java +++ b/core/src/ch/asynk/tankontank/engine/gfx/Drawable.java @@ -1,6 +1,7 @@ package ch.asynk.tankontank.engine.gfx; import com.badlogic.gdx.graphics.g2d.Batch; +import com.badlogic.gdx.graphics.glutils.ShapeRenderer; import com.badlogic.gdx.utils.Disposable; public interface Drawable extends Disposable @@ -26,4 +27,6 @@ public interface Drawable extends Disposable public void setCoords(float x, float y, int r); public void draw(Batch batch, float parentAlpha); + + public void drawDebug(ShapeRenderer debugShapes); } |