Fix the animation issue

This commit is contained in:
Schluffe
2026-02-25 23:59:06 +01:00
parent 9ab90b579c
commit a0671e7953
4 changed files with 12 additions and 11 deletions
+2 -2
View File
@@ -17,7 +17,7 @@ export type Hero = {
velocity: Vector;
body: Circle;
sprite: Sprite;
animation: SpriteAnimation;
$animation: { value: SpriteAnimation };
};
const speed = 0.05;
@@ -35,7 +35,7 @@ const state: Hero = {
velocity: createVector(),
body: createCircle(createVector(), 4),
sprite,
animation: createSpriteAnimation(sprite, 500, 2),
$animation: { value: createSpriteAnimation(sprite, 500, 2) },
};
const process = defineEntity("hero", state);