Merge branch 'master' of git.kingsome.cn:node/card_svr

This commit is contained in:
zhl 2021-02-24 20:17:20 +08:00
commit b94889eaa2
4 changed files with 4 additions and 19 deletions

File diff suppressed because one or more lines are too long

View File

@ -512,12 +512,12 @@ export class BattleHandler {
let nt = this._sktime * 1000; let nt = this._sktime * 1000;
if(this._cachePets.length > 0){ if(this._cachePets.length > 0){
if(nt > 0){ if(nt > 0){
nt += 100; // 延时100ms处理随从
this._room.clock.setTimeout(()=>{ this._room.clock.setTimeout(()=>{
this.onUpdatePets(this._cachePets, null); this.onUpdatePets(this._cachePets, null);
this.checkPets(this._cachePets); this.checkPets(this._cachePets);
this._cachePets.length = 0; this._cachePets.length = 0;
}, nt); }, nt);
nt += 100;
}else{ }else{
this.onUpdatePets(this._cachePets, null); this.onUpdatePets(this._cachePets, null);
this.checkPets(this._cachePets); this.checkPets(this._cachePets);
@ -526,7 +526,7 @@ export class BattleHandler {
} }
this._flowcount = res; this._flowcount = res;
return nt; return nt + 100; // 延时100ms开始下个步骤
} }
this._flowcount = res; this._flowcount = res;

View File

@ -547,7 +547,7 @@ export class PetHandler {
this._halos.forEach((item: Skill)=>{ this._halos.forEach((item: Skill)=>{
if(item.canEffect(this, apet)){ if(item.canEffect(this, apet)){
if(item.isAPHaloSkill()){ if(item.isAPHaloSkill()){
res += apet.addExAP(item.getEffValue(), item, this); // 加战力 res += apet.addExAP(item.getHaloValue(), item, this); // 加战力
}else if(item.isBuffHaloSkill()){ }else if(item.isBuffHaloSkill()){
item.trigger(new SkillParam(0, 0, 0, this._owner, item.trigger(new SkillParam(0, 0, 0, this._owner,
this, apet._owner, apet)); // 触发技能 this, apet._owner, apet)); // 触发技能

View File

@ -269,21 +269,6 @@ export class Skill {
return this.halo_v; return this.halo_v;
}; };
addHaloValue(v: number): number{
this.checkHaloValue();
if(this.halo_v > 0){
let tmp = this.halo_v;
this.halo_v += v;
if(this.halo_v < 0){
this.halo_v = 0;
return -tmp;
}else{
return v;
}
}
return 0;
};
resetHaloValue(){ resetHaloValue(){
this.halo_v = -1; this.halo_v = -1;
}; };