装备添加

This commit is contained in:
2025-06-08 23:16:40 +08:00
parent 63f4d1067e
commit 094b55f349
50 changed files with 20810 additions and 62152 deletions

View File

@@ -61,7 +61,7 @@ export class Hero extends ecs.Entity {
}
/** 加载角色 */
load(pos: Vec3 = Vec3.ZERO,scale:number = 1,uuid:number=1001,info:any={ap:0,hp:0},fight_pos:number=0) {
console.log("英雄加载:",uuid,pos,scale,info)
// console.log("英雄加载:",uuid,pos,scale,info)
scale = 1
let box_group=BoxSet.HERO
var path = "game/heros/"+HeroInfo[uuid].path;
@@ -70,7 +70,7 @@ export class Hero extends ecs.Entity {
var scene = smc.map.MapView.scene;
node.parent = scene.entityLayer!.node!
node.setPosition(pos)
console.log("hero load",pos)
// console.log("hero load",pos)
var hv = node.getComponent(HeroViewComp)!;
let hero= HeroInfo[uuid] // 共用英雄数据
hv.scale = scale;