crt 改为crit

This commit is contained in:
2025-06-24 21:08:46 +08:00
parent 4ef2855e49
commit 766c1f8176
12 changed files with 11211 additions and 7154 deletions

View File

@@ -56,7 +56,7 @@ export class Hero extends ecs.Entity {
}
/** 加载角色 */
load(pos: Vec3 = Vec3.ZERO,scale:number = 1,uuid:number=1001,info:any={ap:0,hp:0,lv:1,crt:0,crt_d:0,dod:0,dod_no:false,crt_no:false},fight_pos:number=1) {
load(pos: Vec3 = Vec3.ZERO,scale:number = 1,uuid:number=1001,info:any={ap:0,hp:0,lv:1,crit:0,crit_d:0,dod:0,dod_no:false,crit_no:false},fight_pos:number=1) {
// console.log("英雄加载:",uuid,pos,scale,info)
scale = 1
let box_group=BoxSet.HERO
@@ -78,7 +78,7 @@ export class Hero extends ecs.Entity {
console.log("[Hero]:friend",hv)
}
hero_init(uuid:number=1001,node:Node,info:any={ap:0,hp:0,lv:1,crt:0,crt_d:0,dod:0,dod_no:false,crt_no:false}) {
hero_init(uuid:number=1001,node:Node,info:any={ap:0,hp:0,lv:1,crit:0,crit_d:0,dod:0,dod_no:false,crit_no:false}) {
var hv = node.getComponent(HeroViewComp)!;
let hero= HeroInfo[uuid] // 共用英雄数据
hv.scale = 1;
@@ -93,11 +93,11 @@ export class Hero extends ecs.Entity {
hv.cd = hero.a_cd
hv.hp= hv.hp_max =hero.hp+info.hp
hv.ap = hero.ap+info.ap;
hv.crt=hero.crt+info.crt
hv.crt_d=hero.crt_d+info.crt_d
hv.crit=hero.crit+info.crit
hv.crit_d=hero.crit_d+info.crit_d
hv.dod=hero.dod+info.dod
hv.dod_no=info.dod_no
hv.crt_no=info.crt_no
hv.crit_no=info.crit_no
hv.atk_skill=hero.skills[0]
return hv
}