30 minute mine windows

This commit is contained in:
2024-03-07 19:45:12 -06:00
parent 7175f79bfe
commit 24bc0097be
3 changed files with 24 additions and 46 deletions
+5 -1
View File
@@ -230,7 +230,11 @@ public class WorldServer {
Thread hourlyJobThread = new Thread(new HourlyJobThread());
hourlyJobThread.setName("hourlyJob");
hourlyJobThread.start();
nextHourlyJobTime = LocalDateTime.now().withMinute(0).withSecond(0).plusHours(1);
if(LocalDateTime.now().isAfter(LocalDateTime.now().withMinute(30).withSecond(0))) {
nextHourlyJobTime = LocalDateTime.now().withMinute(0).withSecond(0).plusHours(1);
}else{
nextHourlyJobTime = LocalDateTime.now().withMinute(30).withSecond(0);
}
}
if (LocalDateTime.now().isAfter(nextWareHousePushTime)) {