diff options
-rw-r--r-- | core/src/ch/asynk/gdx/boardgame/FramedSprite.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/core/src/ch/asynk/gdx/boardgame/FramedSprite.java b/core/src/ch/asynk/gdx/boardgame/FramedSprite.java index 2f41afe..d6c5fc7 100644 --- a/core/src/ch/asynk/gdx/boardgame/FramedSprite.java +++ b/core/src/ch/asynk/gdx/boardgame/FramedSprite.java @@ -46,10 +46,11 @@ public class FramedSprite implements Drawable, Positionable public FramedSprite(FramedSprite other) { - this.frames = other.frames; - this.frame = other.frame; + Texture t = other.frame.getTexture(); this.rows = other.rows; this.cols = other.cols; + this.frames = TextureRegion.split(t, (t.getWidth() / cols), (t.getHeight() / rows)); + this.frame = frames[0][0]; this.x = other.x; this.y = other.y; this.a = other.a; |