feat(技能): 支持英雄技能的多重触发
修改 Hero、Monster 和 HeroAtkSystem 中的技能触发逻辑,将 call、dead 等技能字段从单个 uuid 改为 uuid 数组,支持同时触发多个技能。同时更新 heroSet.ts 中的类型定义和英雄配置以匹配此变更。
This commit is contained in:
@@ -144,12 +144,14 @@ export class Hero extends ecs.Entity {
|
||||
hv.as.idle();
|
||||
|
||||
// 触发 call 技能
|
||||
if (hero.call) {
|
||||
oops.message.dispatchEvent(GameEvent.TriggerSkill, {
|
||||
s_uuid: hero.call,
|
||||
heroAttrs: model,
|
||||
heroView: hv,
|
||||
triggerType: 'call'
|
||||
if (hero.call && hero.call.length > 0) {
|
||||
hero.call.forEach(uuid => {
|
||||
oops.message.dispatchEvent(GameEvent.TriggerSkill, {
|
||||
s_uuid: uuid,
|
||||
heroAttrs: model,
|
||||
heroView: hv,
|
||||
triggerType: 'call'
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user