You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/main/java/net/countercraft/movecraft/coreprotect/movecraftcoreprotect/listeners/CraftDetectListener.java
+9-20Lines changed: 9 additions & 20 deletions
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,6 @@
12
12
importorg.bukkit.block.Block;
13
13
importorg.bukkit.block.BlockState;
14
14
importorg.bukkit.block.Sign;
15
-
importorg.bukkit.block.data.BlockData;
16
15
importorg.bukkit.event.EventHandler;
17
16
importorg.bukkit.event.EventPriority;
18
17
importorg.bukkit.event.Listener;
@@ -38,25 +37,15 @@ public void onCraftDetect(@NotNull CraftDetectEvent e) {
38
37
Blockblock = loc.getBlock();
39
38
BlockStatestate = block.getState();
40
39
41
-
if (Config.LOG_INTERACTIONS) {
42
-
if (stateinstanceofSign) {
43
-
MovecraftCoreProtect.getInstance().getLogger().info("Found sign at " + movecraftLocation);
44
-
Signsign = (Sign) state;
45
-
if (sign.getLine(0).equalsIgnoreCase(typeName) // First line is of the correct type
46
-
|| (sign.getLine(0).equalsIgnoreCase("Subcraft Rotate") // Or first line is Subcraft Rotate
47
-
&& sign.getLine(1).equalsIgnoreCase(typeName)) // And second line is the correct type
48
-
|| sign.getLine(0).equalsIgnoreCase("Release")) { // Or first line is Release
49
-
// Log interaction with sign
50
-
if (!api.logInteraction(userName, loc))
51
-
thrownewRuntimeException(); // Throw an exception on failure to log
Copy file name to clipboardExpand all lines: src/main/java/net/countercraft/movecraft/coreprotect/movecraftcoreprotect/listeners/CraftReleaseListener.java
+9-19Lines changed: 9 additions & 19 deletions
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,6 @@
12
12
importorg.bukkit.block.Block;
13
13
importorg.bukkit.block.BlockState;
14
14
importorg.bukkit.block.Sign;
15
-
importorg.bukkit.block.data.BlockData;
16
15
importorg.bukkit.event.EventHandler;
17
16
importorg.bukkit.event.EventPriority;
18
17
importorg.bukkit.event.Listener;
@@ -38,24 +37,15 @@ public void onCraftRelease(@NotNull CraftReleaseEvent e) {
38
37
Blockblock = loc.getBlock();
39
38
BlockStatestate = block.getState();
40
39
41
-
if (Config.LOG_INTERACTIONS) {
42
-
if (stateinstanceofSign) {
43
-
Signsign = (Sign) state;
44
-
if (sign.getLine(0).equalsIgnoreCase(typeName) // First line is of the correct type
45
-
|| (sign.getLine(0).equalsIgnoreCase("Subcraft Rotate") // Or first line is Subcraft Rotate
46
-
&& sign.getLine(1).equalsIgnoreCase(typeName)) // And second line is the correct type
47
-
|| sign.getLine(0).equalsIgnoreCase("Release")) { // Or first line is Release
48
-
// Log interaction with sign
49
-
if (!api.logInteraction(userName, loc))
50
-
thrownewRuntimeException(); // Throw an exception on failure to log
0 commit comments