pvp随机地图

This commit is contained in:
mamengke01
2021-01-07 12:25:40 +08:00
parent a339b8adcc
commit 94fc48a59a
17 changed files with 327 additions and 84 deletions
+15
View File
@@ -0,0 +1,15 @@
const PER_SECOND = 1 * 1000;
const PER_DAY = 24 * 60 * 60;
export function nowSeconds() {
return Math.floor(Date.now() / PER_SECOND );
}
export function getTodayZeroPoint() {
var date = new Date();
date.setHours(0);
date.setMinutes(0);
date.setSeconds(0);
var time = Math.floor(date.getTime() / PER_SECOND);
return time;
}