mirror of
https://gitlab.bixilon.de/bixilon/minosoft.git
synced 2025-09-14 09:56:37 -04:00
fix sprite animations
Always the same texture was copied :)
This commit is contained in:
parent
83c67d795a
commit
0435e316d6
@ -57,7 +57,7 @@ class SpriteTexture(private val original: Texture) : Texture {
|
||||
|
||||
for (i in 0 until animationProperties.frameCount) {
|
||||
val buffer = original.create(size)
|
||||
buffer.put(original, Vec2i(0, size.y), Vec2i.EMPTY, size)
|
||||
buffer.put(original, Vec2i(0, i * size.y), Vec2i.EMPTY, size)
|
||||
|
||||
val splitTexture = MemoryTexture(size, mipmaps = this.original.mipmaps, buffer = buffer)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user