refactor(character): 重构角色动作与动画系统

- 移除自动回退动作生成逻辑,改为严格检查动作定义
- 增加动作资源缺失时的详细错误报告机制
- 统一输入事件处理接口,优化角色对象生命周期管理
- 改进动画标签管理,移除隐式回退逻辑
- 增强状态机对无效动作的处理能力
This commit is contained in:
2026-04-04 05:53:07 +08:00
parent f64180ebed
commit 1200cf0181
13 changed files with 380 additions and 202 deletions

View File

@@ -46,8 +46,8 @@ bool CharacterInputRouter::OnKeyDown(const KeyEvent& event) {
}
}
bool CharacterInputRouter::OnKeyUp(KeyCode keyCode) {
switch (keyCode) {
bool CharacterInputRouter::OnKeyUp(const KeyUpEvent& event) {
switch (event.getKeyCode()) {
case KeyCode::a:
case KeyCode::Left:
left_ = false;