1
This commit is contained in:
parent
ed59fce738
commit
96136ae3ef
@ -1 +1,27 @@
|
||||
exports.TIME_ZONE = 0;
|
||||
|
||||
exports.NORMAL_HERO_FRAGMENT = [
|
||||
110101,
|
||||
110111,
|
||||
110121,
|
||||
110131,
|
||||
110141,
|
||||
110151,
|
||||
110161,
|
||||
110171
|
||||
];
|
||||
|
||||
exports.SPEC_HERO_FRAGMENT = 110181;
|
||||
|
||||
exports.NORMAL_GUN_FRAGMENT = [
|
||||
110201,
|
||||
110211,
|
||||
110221,
|
||||
110231,
|
||||
110241,
|
||||
110251,
|
||||
110261,
|
||||
110271
|
||||
];
|
||||
|
||||
exports.SPEC_GUN_FRAGMENT = 110281;
|
||||
|
@ -89,6 +89,33 @@ class Fragment {
|
||||
}
|
||||
|
||||
async realloc(conn, daySeconds, nowTime, hourSeconds, allocedFragments) {
|
||||
const totalHeroNum = this.getYesterDayHeroNum();
|
||||
const totalGunNum = this.getYesterDayGunNum();
|
||||
const hour = Math.floor(hourSeconds / 3600);
|
||||
|
||||
const normalHeroNum = Math.floor(totalHeroNum * 0.06 * 8);
|
||||
const specHeroNum = Math.floor(totalHeroNum * 0.02);
|
||||
const normalGunNum = Math.floor(totalGunNum * 0.06 * 8);
|
||||
const specGunNum = Math.floor(totalGunNum * 0.02);
|
||||
|
||||
const pvpNormalHeroNum = normalHeroNum * 0.6;
|
||||
const pvpSpecHeroNum = specHeroNum * 0.6;
|
||||
const pvpNormalGunNum = normalGunNum * 0.6;
|
||||
const pvpSpecGunNum = specGunNum * 0.6;
|
||||
|
||||
const pveNormalHeroNum = normalHeroNum * 0.4;
|
||||
const pveSpecHeroNum = specHeroNum * 0.4;
|
||||
const pveNormalGunNum = normalGunNum * 0.4;
|
||||
const pveSpecGunNum = specGunNum * 0.4;
|
||||
|
||||
}
|
||||
|
||||
getYesterDayHeroNum() {
|
||||
return YESTERDAY_HERO_NUM;
|
||||
}
|
||||
|
||||
getYesterDayGunNum() {
|
||||
return YESTERDAY_GUN_NUM;
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user