去掉hartmodel

This commit is contained in:
2025-06-06 16:26:13 +08:00
parent f9b3f56a04
commit fee9fc9852
7 changed files with 73 additions and 136 deletions

View File

@@ -23,11 +23,11 @@ export class SkillConComp extends CCComp {
}
onLoad(){
this.HeroView=this.node.getComponent(HeroViewComp)
console.log(this.HeroView.uuid+"=>"+this.HeroView.hero_name+"=> SkillConComp onLoad")
// console.log(this.HeroView.uuid+"=>"+this.HeroView.hero_name+"=> SkillConComp onLoad")
this.on(GameEvent.CastHeroSkill,this.cast_master_skill,this)
}
start() {
this.HeroView=this.node.getComponent(HeroViewComp)
console.log(this.HeroView.uuid+"=>"+this.HeroView.hero_name+"=> SkillConComp start")
// console.log(this.HeroView.uuid+"=>"+this.HeroView.hero_name+"=> SkillConComp start")
this.HeroEntity=this.HeroView.ent
}
@@ -41,6 +41,14 @@ export class SkillConComp extends CCComp {
}
}
cast_master_skill(e:string,uuid:any){
if(!this.HeroView) return
if(!this.HeroView.is_master) return
console.log("hart cast_skill",uuid ,e)
const config = SkillSet[uuid];
this.castSkill(config)
}
/** 施放技能 */
castSkill(config: typeof SkillSet[keyof typeof SkillSet]) {
// console.log(view.uuid+"=>"+view.hero_name+"施放技能:"+config.uuid);