diff --git a/src/engine/objects/Mine.java b/src/engine/objects/Mine.java index 2f47b888..0ada9544 100644 --- a/src/engine/objects/Mine.java +++ b/src/engine/objects/Mine.java @@ -114,34 +114,35 @@ public class Mine extends AbstractGameObject { mineTower.setMaxHitPoints(5000 * this.capSize); mineTower.setCurrentHitPoints((float)5000 * this.capSize); this.mineTime = ThreadLocalRandom.current().nextInt(1-23); + this.mineTime *= 100; refactorMineTime(this); } public static void refactorMineTime(Mine mine){ if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("sunday")){ - mine.mineTime += 1; + mine.mineTime += 100; } if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("monday")){ - mine.mineTime += 2; + mine.mineTime += 200; } if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("tuesday")){ - mine.mineTime += 3; + mine.mineTime += 300; } if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("wednesday")){ - mine.mineTime += 4; + mine.mineTime += 400; } if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("thursday")){ - mine.mineTime += 5; + mine.mineTime += 500; } if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("friday")){ - mine.mineTime += 6; + mine.mineTime += 600; } if(DateTime.now().dayOfWeek().getName().toLowerCase().equals("saturday")){ - mine.mineTime += 7; + mine.mineTime += 700; } - if(mine.mineTime >= 24) - mine.mineTime -= 24; + if(mine.mineTime >= 2400) + mine.mineTime -= 2400; } public static void releaseMineClaims(PlayerCharacter playerCharacter) { @@ -227,7 +228,7 @@ public class Mine extends AbstractGameObject { // Mine times are those of the nation not individual guild. - Guild mineNatonGuild = mine.getOwningGuild().getNation(); + Guild mineNatonGuild = mine.getOwningGuild(); // Adjust the serialized mine time based upon whether // the Guild's mine window has passed or not and if it was claimed. @@ -236,7 +237,8 @@ public class Mine extends AbstractGameObject { if (mineNatonGuild.isEmptyGuild() == false && mine.isActive == false) { - int guildWOO = mineNatonGuild.getNation().getMineTime(); + //int guildWOO = mineNatonGuild.getNation().getMineTime(); + int guildWOO = mine.mineTime; LocalDateTime guildMineTime = mineOpenTime.withHour(guildWOO); if (mineOpenTime.isAfter(guildMineTime) || mine.wasClaimed == true)