Browse Source

Serialize current time for all active mines regardless of claim status.

master
MagicBot 2 years ago
parent
commit
2a140a6ce1
  1. 7
      src/engine/objects/Mine.java

7
src/engine/objects/Mine.java

@ -286,8 +286,15 @@ public class Mine extends AbstractGameObject { @@ -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);

Loading…
Cancel
Save