Damn I hate mode #2

This commit is contained in:
md_5 2013-07-28 20:29:49 +10:00
parent a8269a5119
commit cb44b83822
1 changed files with 4 additions and 4 deletions

View File

@ -1,4 +1,4 @@
From 7c011c07c77395789c96298dd5745a74dec4c84d Mon Sep 17 00:00:00 2001 From 08ff6f95339bf788c1d8a79c53642cdab3b72c2f Mon Sep 17 00:00:00 2001
From: md_5 <md_5@live.com.au> From: md_5 <md_5@live.com.au>
Date: Thu, 16 May 2013 18:51:05 +1000 Date: Thu, 16 May 2013 18:51:05 +1000
Subject: [PATCH] Orebfuscator Subject: [PATCH] Orebfuscator
@ -108,7 +108,7 @@ index a7afa55..1a60229 100644
diff --git a/src/main/java/org/spigotmc/AntiXray.java b/src/main/java/org/spigotmc/AntiXray.java diff --git a/src/main/java/org/spigotmc/AntiXray.java b/src/main/java/org/spigotmc/AntiXray.java
new file mode 100644 new file mode 100644
index 0000000..0128d11 index 0000000..59bae3b
--- /dev/null --- /dev/null
+++ b/src/main/java/org/spigotmc/AntiXray.java +++ b/src/main/java/org/spigotmc/AntiXray.java
@@ -0,0 +1,186 @@ @@ -0,0 +1,186 @@
@ -209,7 +209,7 @@ index 0000000..0128d11
+ // TODO: extended IDs are not yet supported + // TODO: extended IDs are not yet supported
+ int blockId = buffer[index] & 0xFF; + int blockId = buffer[index] & 0xFF;
+ // Check if the block should be obfuscated + // Check if the block should be obfuscated
+ if ( obfuscateBlocks[blockId] ) + if ( obfuscateBlocks[blockId] || replaceBlocks[blockId] )
+ { + {
+ // TODO: Don't really understand this, but if radius is not 0 and the world isn't loaded, bail out + // TODO: Don't really understand this, but if radius is not 0 and the world isn't loaded, bail out
+ if ( initialRadius != 0 && !isLoaded( world, startX + x, ( i << 4 ) + y, startZ + z, initialRadius ) ) + if ( initialRadius != 0 && !isLoaded( world, startX + x, ( i << 4 ) + y, startZ + z, initialRadius ) )
@ -255,7 +255,7 @@ index 0000000..0128d11
+ int id = world.getTypeId( x, y, z ); + int id = world.getTypeId( x, y, z );
+ +
+ // See if it needs update + // See if it needs update
+ if ( updateSelf && ( obfuscateBlocks[id] || world.spigotConfig.xRayReplacements.contains( id ) ) ) + if ( updateSelf && ( obfuscateBlocks[id] || replaceBlocks[id] ) )
+ { + {
+ // Send the update + // Send the update
+ world.notify( x, y, z ); + world.notify( x, y, z );