feat: 重构英雄与怪物系统并添加等级机制
- 调整怪物配置映射,将兽人系列怪物ID从5xxx改为6xxx - 为英雄系统添加等级支持,英雄属性随等级线性增长 - 重构卡牌系统,区分英雄卡和功能卡显示逻辑 - 重新组织英雄配置数据,按职业分类并添加等级字段 - 扩展技能配置,为各等级添加对应技能变体 - 简化特殊卡配置结构,添加名称和描述字段
This commit is contained in:
@@ -52,17 +52,17 @@ export class MissionHeroCompComp extends CCComp {
|
||||
}
|
||||
|
||||
private call_hero(event: string, args: any){
|
||||
this.addHero(args.uuid)
|
||||
this.addHero(args.uuid,args.hero_lv)
|
||||
}
|
||||
/** 添加英雄 */
|
||||
private addHero(uuid:number=1001) {
|
||||
private addHero(uuid:number=1001,hero_lv:number=1) {
|
||||
console.log("addHero uuid:",uuid)
|
||||
let hero_pos=0
|
||||
let hero = ecs.getEntity<Hero>(Hero);
|
||||
let scale = 1
|
||||
let landingPos:Vec3 = HeroPos[hero_pos].pos;
|
||||
let spawnPos:Vec3 = v3(landingPos.x, landingPos.y + MissionHeroCompComp.HERO_DROP_HEIGHT, 0);
|
||||
hero.load(spawnPos,scale,uuid,landingPos.y);
|
||||
hero.load(spawnPos,scale,uuid,landingPos.y,hero_lv);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user