数值不取整

This commit is contained in:
yuexin 2021-01-05 17:15:10 +08:00
parent 3d9c6b6c15
commit 89315451a0
2 changed files with 5 additions and 3 deletions

View File

@ -287,7 +287,8 @@ let CfgMan = {
if(!maxv){ if(!maxv){
return minv; return minv;
} }
return Math.round(Math.random() * maxv + minv); // return Math.round(Math.random() * maxv + minv);
return Math.random() * maxv + minv;
}, },
hasSummonPetSkill(skillids: number[]){ hasSummonPetSkill(skillids: number[]){

View File

@ -118,7 +118,8 @@ export class PetHandler {
}; };
private _I(v: number): number{ private _I(v: number): number{
return Math.ceil(v); return v;
// return Math.ceil(v);
}; };
private _isEnhancePower(enid: number){ private _isEnhancePower(enid: number){
@ -447,12 +448,12 @@ export class PetHandler {
public clear(onlyclear: boolean = false){ public clear(onlyclear: boolean = false){
if(this._halos.length > 0){ if(this._halos.length > 0){
this._halos.length = 0;
this.clearEffHalos(); this.clearEffHalos();
if(!onlyclear){ if(!onlyclear){
this._owner.onHaloRemove(this); this._owner.onHaloRemove(this);
} }
} }
this._halos.length = 0;
this._waitskills.length = 0; this._waitskills.length = 0;
}; };