|
@@ -239,7 +239,7 @@ export default class GameUI extends BaseUI {
|
|
|
private timeRolesPos: number[]
|
|
|
private timeRolesDrop: idNum[]
|
|
|
private createEnemyNum: number
|
|
|
- private addEnemyArr: boolean[]
|
|
|
+ private extraEnemyCreateArr: boolean[]
|
|
|
private rightAreaFriend: number[] = []
|
|
|
|
|
|
protected onLoad() {
|
|
@@ -1024,7 +1024,7 @@ export default class GameUI extends BaseUI {
|
|
|
|
|
|
this.roundNextRoleTime = this.timeRolesTime[this.curRoundCreateIndex]
|
|
|
if ('additional' in this.curRoundCfg) {
|
|
|
- this.addEnemyArr = new Array(this.curRoundCfg.additional.map(v => v).length).fill(false)
|
|
|
+ this.extraEnemyCreateArr = new Array(this.curRoundCfg.additional.map(v => v).length).fill(false)
|
|
|
}
|
|
|
}
|
|
|
|
|
@@ -1617,8 +1617,8 @@ export default class GameUI extends BaseUI {
|
|
|
this.rightAreaFriend = this.rightAreaFriend.filter(v => !this.world.isDie(v))
|
|
|
this.rightAreaFriend.push(entity)
|
|
|
if ('extraRoles' in this.curRoundCfg) {
|
|
|
- for (let i = 0; i < this.addEnemyArr.length; i++) {
|
|
|
- if (!this.addEnemyArr[i] && this.rightAreaFriend.length >= this.curRoundCfg.additional[i]) {
|
|
|
+ for (let i = 0; i < this.extraEnemyCreateArr.length; i++) {
|
|
|
+ if (!this.extraEnemyCreateArr[i] && this.rightAreaFriend.length >= this.curRoundCfg.additional[i]) {
|
|
|
for (let j = 0; j < this.curRoundCfg.addNum[i]; j++) {
|
|
|
this.world.createRoleEntity(
|
|
|
this.getRoleCfgByCfgID(this.curRoundCfg.extraRoles[i]),
|
|
@@ -1629,7 +1629,7 @@ export default class GameUI extends BaseUI {
|
|
|
true,
|
|
|
)
|
|
|
}
|
|
|
- this.addEnemyArr[i] = true
|
|
|
+ this.extraEnemyCreateArr[i] = true
|
|
|
}
|
|
|
}
|
|
|
}
|