攻击次数 继续完善

This commit is contained in:
2025-06-12 10:56:12 +08:00
parent a0bd1da1ca
commit 4c0d1023a0
8 changed files with 91 additions and 53 deletions

View File

@@ -24,11 +24,11 @@ export class Skill extends ecs.Entity {
}
load(
startPos: Vec3, // 起始位置
group: number, // 阵营
parent: Node, // 父节点
uuid: number, // 技能ID
targetPos: Vec3, // 目标位置
caster:any=null // 施法者
caster:any=null, // 施法者
angle:number=0
) {
let FIGHTCON=parent.getComponent(FightConComp);
const config = SkillSet[uuid];
@@ -65,8 +65,8 @@ export class Skill extends ecs.Entity {
skillComp.targetPos =targetPos
skillComp.caster = caster;
skillComp.prefabName = config.sp_name;
skillComp.group = group;
skillComp.fac= group==BoxSet.HERO?0:1;
skillComp.group = caster.box_group;
skillComp.fac= caster.box_group==BoxSet.HERO?0:caster.box_group==BoxSet.MONSTER?1:2;
// console.log(config.sp_name+"技能配置",skillComp);
// 初始化动画名称

View File

@@ -60,6 +60,7 @@ export class SkillCom extends CCComp {
}
if(SkillSet[this.s_uuid].AnimType==AnimType.parabolic){
this.node.angle +=10
let bm=this.node.getComponent(BezierMove)
// bm.speed=700
if(this.group==BoxSet.MONSTER) bm.controlPointSide=-1