Added materials for animations
This commit is contained in:
9
FakeMon/src/fmon/draw/Sprite.scala
Normal file
9
FakeMon/src/fmon/draw/Sprite.scala
Normal file
@@ -0,0 +1,9 @@
|
||||
package fmon.draw
|
||||
|
||||
import scalafx.scene.image.{Image, ImageView}
|
||||
|
||||
class Sprite(var pose: String, val poses: Map[String, Drawable]) extends Drawable {
|
||||
def draw(view: ImageView, t: Double): Unit = {
|
||||
poses(pose).draw(view, t)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user