From 2a140a6ce17d8f94e6ccd734ddc72fecc879f857 Mon Sep 17 00:00:00 2001 From: MagicBot Date: Thu, 19 Jan 2023 13:57:43 -0500 Subject: [PATCH] Serialize current time for all active mines regardless of claim status. --- src/engine/objects/Mine.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/engine/objects/Mine.java b/src/engine/objects/Mine.java index 9603ea00..64b340d7 100644 --- a/src/engine/objects/Mine.java +++ b/src/engine/objects/Mine.java @@ -286,8 +286,15 @@ public class Mine extends AbstractGameObject { mineOpenTime = guildMineTime.plusDays(1); else mineOpenTime = guildMineTime; + + // If a mine is active serialize current datetime irrespective + // of any claim + + if (mine.isActive == true) + mineOpenTime = LocalDateTime.now().withMinute(0).withSecond(0).withNano(0); } + writer.putLocalDateTime(mineOpenTime); writer.putLocalDateTime(mineOpenTime.plusHours(1)); writer.put(mine.isActive ? (byte) 0x01 : (byte) 0x00);