Update patch fluff + only record sync times.
This commit is contained in:
parent
71abb6768d
commit
01b495fd02
@ -1,4 +1,4 @@
|
||||
From 87a3ec2b6f68e6f87645abcc32426e4c0141e666 Mon Sep 17 00:00:00 2001
|
||||
From 773d5d2e6c47548c120cb5c33619964136a384e5 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Tue, 22 Jan 2013 15:56:54 +1100
|
||||
Subject: [PATCH] Spigot changes.
|
||||
@ -163,7 +163,7 @@ index 79a007c..0bc7882 100644
|
||||
int j1 = j + random.nextInt(5) - 3;
|
||||
int k1 = k + random.nextInt(3) - 1;
|
||||
diff --git a/src/main/java/net/minecraft/server/BlockMushroom.java b/src/main/java/net/minecraft/server/BlockMushroom.java
|
||||
index bfc48d4..8fa8302 100644
|
||||
index 38fac4c..4ff3111 100644
|
||||
--- a/src/main/java/net/minecraft/server/BlockMushroom.java
|
||||
+++ b/src/main/java/net/minecraft/server/BlockMushroom.java
|
||||
@@ -23,7 +23,7 @@ public class BlockMushroom extends BlockFlower {
|
||||
@ -586,7 +586,7 @@ index fac9ea5..43a24f5 100644
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index 2fb83cf..ced8cf0 100644
|
||||
index f669a00..dee6579 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -253,7 +253,7 @@ public abstract class PlayerList {
|
||||
@ -598,7 +598,7 @@ index 2fb83cf..ced8cf0 100644
|
||||
} else {
|
||||
String s2 = socketaddress.toString();
|
||||
|
||||
@@ -901,7 +901,13 @@ public abstract class PlayerList {
|
||||
@@ -913,7 +913,13 @@ public abstract class PlayerList {
|
||||
|
||||
public void r() {
|
||||
while (!this.players.isEmpty()) {
|
||||
@ -1277,7 +1277,7 @@ index 3f73ef9..a42aa1e 100644
|
||||
+ // Spigot end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index 936cbc6..b8e9085 100644
|
||||
index e7c0760..a7785b7 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -146,7 +146,7 @@ public final class CraftServer implements Server {
|
||||
@ -1348,7 +1348,7 @@ index 936cbc6..b8e9085 100644
|
||||
boolean animals = config.getBoolean("spawn-animals", console.getSpawnAnimals());
|
||||
boolean monsters = config.getBoolean("spawn-monsters", console.worlds.get(0).difficulty > 0);
|
||||
int difficulty = config.getInt("difficulty", console.worlds.get(0).difficulty);
|
||||
@@ -588,6 +610,7 @@ public final class CraftServer implements Server {
|
||||
@@ -591,6 +613,7 @@ public final class CraftServer implements Server {
|
||||
"This plugin is not properly shutting down its async tasks when it is being reloaded. This may cause conflicts with the newly loaded version of the plugin"
|
||||
));
|
||||
}
|
||||
@ -1356,7 +1356,7 @@ index 936cbc6..b8e9085 100644
|
||||
loadPlugins();
|
||||
enablePlugins(PluginLoadOrder.STARTUP);
|
||||
enablePlugins(PluginLoadOrder.POSTWORLD);
|
||||
@@ -1036,11 +1059,8 @@ public final class CraftServer implements Server {
|
||||
@@ -1039,11 +1062,8 @@ public final class CraftServer implements Server {
|
||||
return count;
|
||||
}
|
||||
|
||||
@ -1369,7 +1369,7 @@ index 936cbc6..b8e9085 100644
|
||||
OfflinePlayer result = getPlayerExact(name);
|
||||
String lname = name.toLowerCase();
|
||||
|
||||
@@ -1048,17 +1068,7 @@ public final class CraftServer implements Server {
|
||||
@@ -1051,17 +1071,7 @@ public final class CraftServer implements Server {
|
||||
result = offlinePlayers.get(lname);
|
||||
|
||||
if (result == null) {
|
||||
@ -1388,7 +1388,7 @@ index 936cbc6..b8e9085 100644
|
||||
result = new CraftOfflinePlayer(this, name);
|
||||
offlinePlayers.put(lname, result);
|
||||
}
|
||||
@@ -1196,7 +1206,7 @@ public final class CraftServer implements Server {
|
||||
@@ -1199,7 +1209,7 @@ public final class CraftServer implements Server {
|
||||
Set<OfflinePlayer> players = new HashSet<OfflinePlayer>();
|
||||
|
||||
for (String file : files) {
|
||||
@ -1397,7 +1397,7 @@ index 936cbc6..b8e9085 100644
|
||||
}
|
||||
players.addAll(Arrays.asList(getOnlinePlayers()));
|
||||
|
||||
@@ -1302,7 +1312,7 @@ public final class CraftServer implements Server {
|
||||
@@ -1305,7 +1315,7 @@ public final class CraftServer implements Server {
|
||||
public List<String> tabCompleteCommand(Player player, String message) {
|
||||
List<String> completions = null;
|
||||
try {
|
||||
@ -1406,7 +1406,7 @@ index 936cbc6..b8e9085 100644
|
||||
} catch (CommandException ex) {
|
||||
player.sendMessage(ChatColor.RED + "An internal error occurred while attempting to tab-complete this command");
|
||||
getLogger().log(Level.SEVERE, "Exception when " + player.getName() + " attempted to tab complete " + message, ex);
|
||||
@@ -1338,4 +1348,52 @@ public final class CraftServer implements Server {
|
||||
@@ -1341,4 +1351,52 @@ public final class CraftServer implements Server {
|
||||
public CraftItemFactory getItemFactory() {
|
||||
return CraftItemFactory.instance();
|
||||
}
|
||||
@ -1460,10 +1460,10 @@ index 936cbc6..b8e9085 100644
|
||||
+ // Spigot end
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index cb20066..3544aa3 100644
|
||||
index 6e364b1..45217cd 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -73,7 +73,81 @@ public class CraftWorld implements World {
|
||||
@@ -75,7 +75,81 @@ public class CraftWorld implements World {
|
||||
if (server.chunkGCPeriod > 0) {
|
||||
chunkGCTickCount = rand.nextInt(server.chunkGCPeriod);
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 9b45e7ed5ccba94e2730105b6234da7945fa8be3 Mon Sep 17 00:00:00 2001
|
||||
From f303848293ac86066ccea4f00947253af6e9c8f0 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@bigpond.com>
|
||||
Date: Sat, 12 Jan 2013 19:57:45 +1100
|
||||
Subject: [PATCH] Per world view distance.
|
||||
@ -10,7 +10,7 @@ Subject: [PATCH] Per world view distance.
|
||||
3 files changed, 7 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||
index 6de6b12..6e5434b 100644
|
||||
index a42aa1e..842d722 100644
|
||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||
@@ -49,7 +49,7 @@ public class WorldServer extends World implements org.bukkit.BlockChangeDelegate
|
||||
@ -23,10 +23,10 @@ index 6de6b12..6e5434b 100644
|
||||
this.entitiesById = new IntHashMap();
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index 3544aa3..856307f 100644
|
||||
index 45217cd..94e07fe 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -114,6 +114,9 @@ public class CraftWorld implements World {
|
||||
@@ -116,6 +116,9 @@ public class CraftWorld implements World {
|
||||
treeGrowthModifier = configuration.getInt("world-settings." + name + ".tree-growth-modifier", treeGrowthModifier);
|
||||
mushroomGrowthModifier = configuration.getInt("world-settings." + name + ".mushroom-growth-modifier", mushroomGrowthModifier);
|
||||
|
||||
@ -36,7 +36,7 @@ index 3544aa3..856307f 100644
|
||||
server.getLogger().info("-------------- Spigot ----------------");
|
||||
server.getLogger().info("-------- World Settings For [" + name + "] --------");
|
||||
server.getLogger().info("Growth Per Chunk: " + growthPerTick);
|
||||
@@ -129,6 +132,7 @@ public class CraftWorld implements World {
|
||||
@@ -131,6 +134,7 @@ public class CraftWorld implements World {
|
||||
server.getLogger().info("Sugar Growth Modifier: " + sugarGrowthModifier);
|
||||
server.getLogger().info("Tree Growth Modifier: " + treeGrowthModifier);
|
||||
server.getLogger().info("Mushroom Growth Modifier: " + mushroomGrowthModifier);
|
||||
@ -44,7 +44,7 @@ index 3544aa3..856307f 100644
|
||||
server.getLogger().info("-------------------------------------------------");
|
||||
// Spigot end
|
||||
}
|
||||
@@ -139,6 +143,7 @@ public class CraftWorld implements World {
|
||||
@@ -141,6 +145,7 @@ public class CraftWorld implements World {
|
||||
public boolean randomLightingUpdates = false;
|
||||
public int mobSpawnRange = 4;
|
||||
public int aggregateTicks = 4;
|
||||
@ -53,7 +53,7 @@ index 3544aa3..856307f 100644
|
||||
public int wheatGrowthModifier = 100;
|
||||
public int cactusGrowthModifier = 100;
|
||||
diff --git a/src/main/resources/configurations/bukkit.yml b/src/main/resources/configurations/bukkit.yml
|
||||
index 78134f9..c41fac1 100644
|
||||
index 55bfb77..9d6d613 100644
|
||||
--- a/src/main/resources/configurations/bukkit.yml
|
||||
+++ b/src/main/resources/configurations/bukkit.yml
|
||||
@@ -52,6 +52,7 @@ world-settings:
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 3ab7a7febeae0b35fc8cb278d2a26414b05ec5f7 Mon Sep 17 00:00:00 2001
|
||||
From 79ce6e3a28a745cd7a16498149dc6b66204b211a Mon Sep 17 00:00:00 2001
|
||||
From: lishid <lishid@gmail.com>
|
||||
Date: Mon, 21 Jan 2013 16:59:04 +1100
|
||||
Subject: [PATCH] Add oreobfuscator for Spigot.
|
||||
@ -110,7 +110,7 @@ index 5faee12..55f9ffa 100644
|
||||
|
||||
if (false) { // Never trigger
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index b8e9085..dac1cb7 100644
|
||||
index a7785b7..ef52f32 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -163,6 +163,11 @@ public final class CraftServer implements Server {
|
||||
@ -126,10 +126,10 @@ index b8e9085..dac1cb7 100644
|
||||
private boolean value = true;
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
index 856307f..4861609 100644
|
||||
index 94e07fe..21bd64a 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftWorld.java
|
||||
@@ -117,6 +117,8 @@ public class CraftWorld implements World {
|
||||
@@ -119,6 +119,8 @@ public class CraftWorld implements World {
|
||||
viewDistance = Bukkit.getServer().getViewDistance();
|
||||
viewDistance = configuration.getInt("world-settings." + name + ".view-distance", viewDistance);
|
||||
|
||||
@ -138,7 +138,7 @@ index 856307f..4861609 100644
|
||||
server.getLogger().info("-------------- Spigot ----------------");
|
||||
server.getLogger().info("-------- World Settings For [" + name + "] --------");
|
||||
server.getLogger().info("Growth Per Chunk: " + growthPerTick);
|
||||
@@ -133,6 +135,7 @@ public class CraftWorld implements World {
|
||||
@@ -135,6 +137,7 @@ public class CraftWorld implements World {
|
||||
server.getLogger().info("Tree Growth Modifier: " + treeGrowthModifier);
|
||||
server.getLogger().info("Mushroom Growth Modifier: " + mushroomGrowthModifier);
|
||||
server.getLogger().info("View distance: " + viewDistance);
|
||||
@ -146,7 +146,7 @@ index 856307f..4861609 100644
|
||||
server.getLogger().info("-------------------------------------------------");
|
||||
// Spigot end
|
||||
}
|
||||
@@ -144,6 +147,7 @@ public class CraftWorld implements World {
|
||||
@@ -146,6 +149,7 @@ public class CraftWorld implements World {
|
||||
public int mobSpawnRange = 4;
|
||||
public int aggregateTicks = 4;
|
||||
public int viewDistance;
|
||||
@ -156,7 +156,7 @@ index 856307f..4861609 100644
|
||||
public int cactusGrowthModifier = 100;
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java b/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java
|
||||
new file mode 100644
|
||||
index 0000000..1ac8c26
|
||||
index 0000000..7178dfb
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java
|
||||
@@ -0,0 +1,95 @@
|
||||
|
@ -1,14 +1,28 @@
|
||||
From c7fe2d7f3ac2abda1bcda274e0fd36648a2f7c3d Mon Sep 17 00:00:00 2001
|
||||
From a92dd621c34cdca2b5c4ceb27ea92dec45129bba Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Fri, 25 Jan 2013 13:15:42 +1100
|
||||
Subject: [PATCH] Track Xray timings.
|
||||
|
||||
---
|
||||
src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java | 7 +++++++
|
||||
1 file changed, 7 insertions(+)
|
||||
src/main/java/net/minecraft/server/Packet51MapChunk.java | 2 +-
|
||||
src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java | 11 +++++++++++
|
||||
2 files changed, 12 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Packet51MapChunk.java b/src/main/java/net/minecraft/server/Packet51MapChunk.java
|
||||
index 365116a..230dd62 100644
|
||||
--- a/src/main/java/net/minecraft/server/Packet51MapChunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Packet51MapChunk.java
|
||||
@@ -46,7 +46,7 @@ public class Packet51MapChunk extends Packet {
|
||||
|
||||
this.d = chunkmap.c;
|
||||
this.c = chunkmap.b;
|
||||
- org.bukkit.craftbukkit.OrebfuscatorManager.obfuscate(chunk.x, chunk.z, i, chunkmap.a, chunk.world); // Spigot (Orebfuscator)
|
||||
+ org.bukkit.craftbukkit.OrebfuscatorManager.obfuscateSync(chunk.x, chunk.z, i, chunkmap.a, chunk.world); // Spigot (Orebfuscator)
|
||||
|
||||
try {
|
||||
this.inflatedBuffer = chunkmap.a;
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java b/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java
|
||||
index 7178dfb..723fd9f 100644
|
||||
index 7178dfb..c0ee505 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/OrebfuscatorManager.java
|
||||
@@ -2,11 +2,14 @@ package org.bukkit.craftbukkit;
|
||||
@ -26,28 +40,22 @@ index 7178dfb..723fd9f 100644
|
||||
|
||||
// Default blocks
|
||||
static {
|
||||
@@ -24,10 +27,13 @@ public class OrebfuscatorManager {
|
||||
@@ -24,7 +27,15 @@ public class OrebfuscatorManager {
|
||||
}
|
||||
|
||||
public static void updateNearbyBlocks(World world, int x, int y, int z) {
|
||||
+ update.startTiming();
|
||||
updateNearbyBlocks(world, x, y, z, world.getServer().orebfuscatorUpdateRadius);
|
||||
+ update.stopTiming();
|
||||
}
|
||||
|
||||
public static void obfuscate(int chunkX, int chunkY, int bitmask, byte[] buffer, World world) {
|
||||
+ }
|
||||
+
|
||||
+ public static void obfuscateSync(int chunkX, int chunkY, int bitmask, byte[] buffer, World world) {
|
||||
+ obfuscate.startTiming();
|
||||
if (world.getServer().orebfuscatorEnabled && world.getWorld().obfuscated) {
|
||||
int initialRadius = 1;
|
||||
int index = 0;
|
||||
@@ -56,6 +62,7 @@ public class OrebfuscatorManager {
|
||||
}
|
||||
}
|
||||
}
|
||||
+ obfuscate(chunkX, chunkY, bitmask, buffer, world);
|
||||
+ obfuscate.stopTiming();
|
||||
}
|
||||
|
||||
private static void updateNearbyBlocks(World world, int x, int y, int z, int radius) {
|
||||
public static void obfuscate(int chunkX, int chunkY, int bitmask, byte[] buffer, World world) {
|
||||
--
|
||||
1.8.1-rc2
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user