]> git.localhorst.tv Git - l2e.git/blobdiff - test-data/test.l2s
interpret Monster's meleeAnimation property
[l2e.git] / test-data / test.l2s
index 31c4ace27abea7f986edc6222c8c28d566d4b40e..74e71cd9908a49182533114dfa41048cc6c376c5 100644 (file)
@@ -1,14 +1,17 @@
 Number frameTime 33
 Number twoFramesTime 66
-Number fiveFramesTime 165
+Number fourFramesTime 132
+Number fiveFramesTime 165 // darn, i really need to implement expressions
+
+Sprite lizardSprite {
+       // using pathes relative to project root until path resolution is implemented
+       image: "test-data/monster.png",
+       size: <64,64>
+}
 
 export Monster lizard {
        name: "Lizard",
-       sprite: Sprite {
-               // using pathes relative to project root until path resolution is implemented
-               image: "test-data/monster.png",
-               size: <64,64>
-       },
+       sprite: lizardSprite,
        level: 1,
        maxHealth: 8,
        health: 8,
@@ -21,7 +24,18 @@ export Monster lizard {
                gut:  6,
                mgr:  6
        },
-       attackAnimation: SimpleAnimation {
+       attackAnimation: ComplexAnimation {
+               sprite: lizardSprite,
+               frametime: fourFramesTime,
+               repeat: false,
+               frames: [
+                       { column: 0, row: 1, disposition: < 0, 16> },
+                       { column: 0, row: 0, disposition: < 0, 16> },
+                       { column: 0, row: 1, disposition: < 0, 16> },
+                       { column: 0, row: 0, disposition: < 0, 16> }
+               ]
+       },
+       meleeAnimation: SimpleAnimation {
                sprite: Sprite {
                        image: "test-data/attack-monster.png",
                        size: <96,64>