Skip to content

Commit

Permalink
added playtest
Browse files Browse the repository at this point in the history
  • Loading branch information
dragoncoder047 committed Dec 30, 2024
1 parent a88ebe7 commit 71e712c
Showing 1 changed file with 29 additions and 0 deletions.
29 changes: 29 additions & 0 deletions examples/frames.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// @ts-check

kaplay({
scale: 4,
background: [0, 0, 0],
});

// https://0x72.itch.io/dungeontileset-ii
loadSpriteAtlas("/examples/sprites/dungeon.png", {
wizard: {
x: 128,
y: 140,
width: 144,
height: 28,
sliceX: 9,
anims: {
bouncy: {
frames: [8, 5, 0, 3, 2, 3, 0, 5],
speed: 10,
loop: true
}
},
},
});

add([
sprite("wizard", { anim: "bouncy" }),
pos(100, 100),
]);

0 comments on commit 71e712c

Please sign in to comment.