技能动画添加

This commit is contained in:
walkpan
2025-01-05 09:10:21 +08:00
parent 66f4a0de82
commit 511459c66c
118 changed files with 22272 additions and 8796 deletions

View File

@@ -31,18 +31,23 @@ export class Skill extends ecs.Entity {
pos=v3(pos.x,pos.y)
node.parent = parent;
node.setPosition(pos)
var sv = node.getComponent(SkillCom)!;
let angle=0
if(SkillSet[uuid].angle){
angle = Math.atan2(t_pos.y,t_pos.x) * 180 / Math.PI;
if(t_pos.x<0){
angle+=180
}
}
sv.angle = angle;
console.log(group+" "+SkillSet[uuid].name+"angle:"+angle)
var sv = node.getComponent(SkillCom);
// let angle=0
// if(SkillSet[uuid].angle){
// angle = Math.atan2(t_pos.y,t_pos.x) * 180 / Math.PI;
// if(t_pos.x<0){
// angle+=180
// }
// }
// sv.angle = angle;
// console.log(group+" "+SkillSet[uuid].name+"angle:"+angle)
sv.s_uuid = uuid;
sv.ap = ap;
sv.s_name = SkillSet[uuid].name;
sv.ap = ap*SkillSet[uuid].ap;
sv.cd = SkillSet[uuid].cd;
sv.decd = SkillSet[uuid].decd;
sv.debuff = SkillSet[uuid].debuff;
sv.rate = SkillSet[uuid].rate;
sv.is_crit=is_crit
sv.crit_add=crit_add
// node.setScale(v3(node.scale.x*scale,node.scale.y))