怪物 改为3条直线 进入, 攻击动画 直线的已改, 抛物线和群攻的 也需要修改
This commit is contained in:
@@ -79,7 +79,8 @@ export class EquipSkillComp extends CCComp {
|
||||
update(dt: number): void {
|
||||
if(!smc.mission.play||smc.mission.pause) return
|
||||
if(this.skill1.uuid!=0){
|
||||
let cd=this.skill1.cd
|
||||
let cd_bar=this.boxs.getChildByName("skill1").getChildByName("icon").getChildByName("cd")
|
||||
let cd=this.skill1.cd*(100-smc.vmdata.hero.skill_cd_buff)/100
|
||||
if(this.skill1.cd_time < cd){
|
||||
this.skill1.cd_time+=dt
|
||||
}else{
|
||||
@@ -87,10 +88,11 @@ export class EquipSkillComp extends CCComp {
|
||||
this.do_skill1()
|
||||
}
|
||||
}
|
||||
this.boxs.getChildByName("skill1").getChildByName("icon").getChildByName("cd").getComponent(ProgressBar).progress=(1-this.skill1.cd_time/cd)
|
||||
cd_bar.getComponent(ProgressBar).progress=(1-this.skill1.cd_time/cd)
|
||||
}
|
||||
if(this.skill2.uuid!=0){
|
||||
let cd=this.skill2.cd
|
||||
let cd_bar=this.boxs.getChildByName("skill2").getChildByName("icon").getChildByName("cd")
|
||||
let cd=this.skill2.cd*(100-smc.vmdata.hero.skill_cd_buff)/100
|
||||
if(this.skill2.cd_time < cd){
|
||||
this.skill2.cd_time+=dt
|
||||
}else{
|
||||
@@ -98,10 +100,11 @@ export class EquipSkillComp extends CCComp {
|
||||
this.do_skill2()
|
||||
}
|
||||
}
|
||||
this.boxs.getChildByName("skill2").getChildByName("icon").getChildByName("cd").getComponent(ProgressBar).progress=(1-this.skill2.cd_time/cd)
|
||||
cd_bar.getComponent(ProgressBar).progress=(1-this.skill2.cd_time/cd)
|
||||
}
|
||||
if(this.skill3.uuid!=0){
|
||||
let cd=this.skill3.cd
|
||||
let cd_bar=this.boxs.getChildByName("skill3").getChildByName("icon").getChildByName("cd")
|
||||
let cd=this.skill3.cd*(100-smc.vmdata.hero.skill_cd_buff)/100
|
||||
if(this.skill3.cd_time < cd){
|
||||
this.skill3.cd_time+=dt
|
||||
}else{
|
||||
@@ -109,7 +112,7 @@ export class EquipSkillComp extends CCComp {
|
||||
// this.do_skill3()
|
||||
}
|
||||
}
|
||||
this.boxs.getChildByName("skill3").getChildByName("icon").getChildByName("cd").getComponent(ProgressBar).progress=(1-this.skill3.cd_time/cd)
|
||||
cd_bar.getComponent(ProgressBar).progress=(1-this.skill3.cd_time/cd)
|
||||
}
|
||||
}
|
||||
do_skill1(){
|
||||
|
||||
@@ -29,7 +29,7 @@ export class MissionMonCompComp extends CCComp {
|
||||
buffData?: any[] // 使用BuffAttr格式的buff数据
|
||||
}> = [];
|
||||
private isSpawning: boolean = false;// 是否正在生成怪物
|
||||
private spawnInterval: number = 0.5; // 每个怪物生成间隔时间
|
||||
private spawnInterval: number = 1; // 每个怪物生成间隔时间
|
||||
private spawnTimer: number = 0; // 生成计时器
|
||||
private is_fight:boolean = false;
|
||||
|
||||
@@ -78,7 +78,6 @@ export class MissionMonCompComp extends CCComp {
|
||||
const rogueWaveConfig = getRogueWaveConfig(currentWave);
|
||||
console.log(`[MissionMonComp]:肉鸽模式第${currentWave}波配置:`, rogueWaveConfig.description);
|
||||
this.generateRogueMonstersFromConfig(rogueWaveConfig);
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -106,9 +105,10 @@ export class MissionMonCompComp extends CCComp {
|
||||
// 为每个怪物组生成指定数量的怪物
|
||||
for (let i = 0; i < count; i++) {
|
||||
// 随机选择位置 (0-9)
|
||||
let x=i%3 //0 1 2
|
||||
this.addToSpawnQueueWithAffixes(
|
||||
uuid,
|
||||
i,
|
||||
x,
|
||||
isBoss || false,
|
||||
monsterLevel,
|
||||
affixes,
|
||||
@@ -189,9 +189,10 @@ export class MissionMonCompComp extends CCComp {
|
||||
lv: number = 1,
|
||||
buffData?: any[]
|
||||
) {
|
||||
let x=RandomManager.instance.getRandomInt(0,2)
|
||||
let mon = ecs.getEntity<Monster>(Monster);
|
||||
let scale = -1;
|
||||
let pos: Vec3 = v3(MonSet[i].pos);
|
||||
let pos: Vec3 = v3(MonSet[x].pos);
|
||||
|
||||
// 生成怪物,传递词条buff数据
|
||||
mon.load(pos, scale, uuid, is_boss, is_call, lv, buffData);
|
||||
|
||||
Reference in New Issue
Block a user