diff options
Diffstat (limited to 'core/src/ch/asynk/tankontank/engine/gfx')
-rw-r--r-- | core/src/ch/asynk/tankontank/engine/gfx/animations/RunnableAnimation.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/src/ch/asynk/tankontank/engine/gfx/animations/RunnableAnimation.java b/core/src/ch/asynk/tankontank/engine/gfx/animations/RunnableAnimation.java index 41a08a7..24b1e4b 100644 --- a/core/src/ch/asynk/tankontank/engine/gfx/animations/RunnableAnimation.java +++ b/core/src/ch/asynk/tankontank/engine/gfx/animations/RunnableAnimation.java @@ -8,6 +8,7 @@ import ch.asynk.tankontank.engine.gfx.Animation; public class RunnableAnimation implements Animation, Pool.Poolable { private Runnable runnable; + private Pawn pawn; private boolean ran; private static final Pool<RunnableAnimation> runnableAnimationPool = new Pool<RunnableAnimation>() { @@ -17,10 +18,11 @@ public class RunnableAnimation implements Animation, Pool.Poolable } }; - public static RunnableAnimation get(Runnable runnable) + public static RunnableAnimation get(Pawn pawn, Runnable runnable) { RunnableAnimation a = runnableAnimationPool.obtain(); a.runnable = runnable; + a.pawn = pawn; return a; } @@ -39,7 +41,7 @@ public class RunnableAnimation implements Animation, Pool.Poolable @Override public Pawn getPawn() { - return null; + return pawn; } @Override |