From 56365b38dff1e9158c7bb981269fe1c2e0e0d1db Mon Sep 17 00:00:00 2001 From: unanmed <1319491857@qq.com> Date: Fri, 22 Nov 2024 19:51:03 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=8B=87=E5=A3=AB=E5=8E=9F=E5=9C=B0?= =?UTF-8?q?=E8=B8=8F=E6=AD=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/core/main/action/move.ts | 2 +- src/core/render/preset/hero.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/main/action/move.ts b/src/core/main/action/move.ts index b895722..3773689 100644 --- a/src/core/main/action/move.ts +++ b/src/core/main/action/move.ts @@ -57,7 +57,7 @@ export class HeroKeyMover { } private onPressKey = (code: KeyCode) => { - if (core.isReplaying()) return; + if (core.isReplaying() || !core.isPlaying()) return; core.waitHeroToStop(); if (code === this.hotkeyData.left.key) this.press('left'); else if (code === this.hotkeyData.right.key) this.press('right'); diff --git a/src/core/render/preset/hero.ts b/src/core/render/preset/hero.ts index 4d79c10..90e338b 100644 --- a/src/core/render/preset/hero.ts +++ b/src/core/render/preset/hero.ts @@ -389,7 +389,7 @@ export class HeroRenderer render() { if (!this.renderable) return; if (!this.animate) { - this.renderable.animate = -1; + this.renderable.animate = 0; } else { this.renderable.animate = this.movingFrame; }