refactor(hero): 将is_atking状态从HeroViewComp移到HeroAttrsComp
将攻击状态is_atking从视图组件HeroViewComp移动到属性组件HeroAttrsComp,以保持状态管理的集中性
This commit is contained in:
@@ -227,7 +227,7 @@ export class SkillAutocastSystem extends ecs.ComblockSystem implements ecs.ISyst
|
||||
if (heroModel.is_dead || heroModel.isStun() || heroModel.isFrost()) return;
|
||||
|
||||
// 检查是否正在攻击(只有攻击时才释放技能)
|
||||
if (!heroView.is_atking) return;
|
||||
if (!heroModel.is_atking) return;
|
||||
|
||||
// 获取所有可施放的技能
|
||||
const readySkills = skillsData.getReadySkills(heroModel.mp);
|
||||
|
||||
Reference in New Issue
Block a user