about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGenny <gen@nyble.dev>2020-06-11 16:23:27 -0500
committerGenny <gen@nyble.dev>2020-06-11 16:23:27 -0500
commitb9f26aa0c729fc1fe0864991366f10df3ab4945c (patch)
tree6447ba7301f36ba77bc79fe74c61f64ffa0196aa
parent67acdf42e31d5c49de121f4b497c71637605b7ae (diff)
downloadsunfright-b9f26aa0c729fc1fe0864991366f10df3ab4945c.tar.gz
sunfright-b9f26aa0c729fc1fe0864991366f10df3ab4945c.zip
Check for only thunder with cover all case
-rw-r--r--src/main/java/dev/genbyte/sunfright/Damager.java10
-rw-r--r--src/main/java/dev/genbyte/sunfright/Sunfright.java1
2 files changed, 4 insertions, 7 deletions
diff --git a/src/main/java/dev/genbyte/sunfright/Damager.java b/src/main/java/dev/genbyte/sunfright/Damager.java
index 28420d4..c84de86 100644
--- a/src/main/java/dev/genbyte/sunfright/Damager.java
+++ b/src/main/java/dev/genbyte/sunfright/Damager.java
@@ -40,15 +40,11 @@ public class Damager extends BukkitRunnable {
 		long time = sunnedWorld.getTime();
 		boolean storming = sunnedWorld.hasStorm();
 		boolean thundering = sunnedWorld.isThundering();
-
+		
 		// Times are pulled from Minecraft Gamepedia page on Light, specifically the internal light
 		// level section. https://minecraft.gamepedia.com/Light
 		// Times correspond to when the light level is over 8.
-		if (!storming && !thundering) {
-			if (time >= 13027 && time <= 22973) {
-				return false;
-			}
-		} else if (storming && !thundering) {
+		 if (storming && !thundering) {
 			if (time >= 12734 && time <= 23266) {
 				return false;
 			}
@@ -56,6 +52,8 @@ public class Damager extends BukkitRunnable {
 			if (time >= 12300 && time <= 23700) {
 				return false;
 			}
+		} else if (time >= 13027 && time <= 22973) {
+			return false;
 		}
 		return true;
 	}
diff --git a/src/main/java/dev/genbyte/sunfright/Sunfright.java b/src/main/java/dev/genbyte/sunfright/Sunfright.java
index 051ac13..6404360 100644
--- a/src/main/java/dev/genbyte/sunfright/Sunfright.java
+++ b/src/main/java/dev/genbyte/sunfright/Sunfright.java
@@ -1,7 +1,6 @@
 package dev.genbyte.sunfright;
 
 import java.util.logging.Level;
-import java.util.logging.Logger;
 
 import org.bukkit.World;
 import org.bukkit.plugin.java.JavaPlugin;