pvp:修改赛季debug接口逻辑
This commit is contained in:
@@ -117,9 +117,7 @@ async function setPvpSeason(isForce?: boolean, hour?: number) {
|
|||||||
console.log(`******** setPvpSeason4: newSeasonStartTime-${newSeasonStartTime}, during-${during}`)
|
console.log(`******** setPvpSeason4: newSeasonStartTime-${newSeasonStartTime}, during-${during}`)
|
||||||
|
|
||||||
if(isForce) { // debug使用,如果seasonEndTime是未来的,强行结束掉,新赛季从现在开始
|
if(isForce) { // debug使用,如果seasonEndTime是未来的,强行结束掉,新赛季从现在开始
|
||||||
if(newSeasonStartTime > nowSeconds()) {
|
newSeasonStartTime = nowSeconds();
|
||||||
newSeasonStartTime = nowSeconds();
|
|
||||||
}
|
|
||||||
} else { // 不是用debug的情况,如果(因为debug)newSeasonStartTime不是每天0点结算,那么改成lastSeasonEndTime之后的0点开始
|
} else { // 不是用debug的情况,如果(因为debug)newSeasonStartTime不是每天0点结算,那么改成lastSeasonEndTime之后的0点开始
|
||||||
let d = new Date(newSeasonStartTime * 1000);
|
let d = new Date(newSeasonStartTime * 1000);
|
||||||
if(d.getHours() != 0) {
|
if(d.getHours() != 0) {
|
||||||
|
|||||||
Reference in New Issue
Block a user