mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-27 13:06:02 +01:00
Update to latest upstream
This commit is contained in:
parent
bb2e36cb8d
commit
51ed9f651d
@ -1,11 +1,11 @@
|
||||
From 3f9b2f27b3535d47b22935dcec3b4c4a1a890298 Mon Sep 17 00:00:00 2001
|
||||
From d54411e01b4bc4b5e56f7d60fe24fe2b849f3ca0 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Wed, 30 Jan 2013 23:44:29 -0500
|
||||
Subject: [PATCH] Spigot POM Changes.
|
||||
|
||||
|
||||
diff --git a/pom.xml b/pom.xml
|
||||
index d73d4bf..4985143 100644
|
||||
index 9806ef8..d21978a 100644
|
||||
--- a/pom.xml
|
||||
+++ b/pom.xml
|
||||
@@ -1,43 +1,23 @@
|
||||
@ -23,7 +23,7 @@ index d73d4bf..4985143 100644
|
||||
+
|
||||
+ <groupId>org.spigotmc</groupId>
|
||||
+ <artifactId>spigot-api</artifactId>
|
||||
<version>1.5.2-R0.1-SNAPSHOT</version>
|
||||
<version>1.5.2-R0.2-SNAPSHOT</version>
|
||||
- <name>Bukkit</name>
|
||||
- <url>http://www.bukkit.org</url>
|
||||
+ <name>Spigot-API</name>
|
||||
|
@ -1,11 +1,11 @@
|
||||
From ef78745a8354083dc6747241dab14fbffb8c0102 Mon Sep 17 00:00:00 2001
|
||||
From 8edff6175591d990912fcb203e86d27c6d7aaf86 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Tue, 23 Apr 2013 11:34:54 +1000
|
||||
Subject: [PATCH] POM Changes
|
||||
|
||||
|
||||
diff --git a/pom.xml b/pom.xml
|
||||
index 01a7a89..3c6062e 100644
|
||||
index e946de6..274fd43 100644
|
||||
--- a/pom.xml
|
||||
+++ b/pom.xml
|
||||
@@ -1,12 +1,20 @@
|
||||
@ -25,7 +25,7 @@ index 01a7a89..3c6062e 100644
|
||||
+ <groupId>org.spigotmc</groupId>
|
||||
+ <artifactId>spigot</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
<version>1.5.2-R0.1-SNAPSHOT</version>
|
||||
<version>1.5.2-R0.2-SNAPSHOT</version>
|
||||
- <name>CraftBukkit</name>
|
||||
- <url>http://www.bukkit.org</url>
|
||||
+ <name>Spigot</name>
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 4515bd7b5db7b0a91eef7fb323cfea8dbec70349 Mon Sep 17 00:00:00 2001
|
||||
From f6bda668b73c66e0cfeef52dedd4d211b8f64176 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Tue, 23 Apr 2013 11:17:36 +1000
|
||||
Subject: [PATCH] Spigot Changes
|
||||
@ -259,10 +259,10 @@ index 0225f53..a8f1799 100644
|
||||
// ++this.age; // CraftBukkit - Moved up
|
||||
if (!this.world.isStatic && this.age >= 6000) {
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index 55873f5..0f6a0ae 100644
|
||||
index 5d10382..bc55a77 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -840,8 +840,20 @@ public class PlayerConnection extends Connection {
|
||||
@@ -839,8 +839,20 @@ public class PlayerConnection extends Connection {
|
||||
|
||||
this.chat(s, packet3chat.a_());
|
||||
|
||||
@ -284,7 +284,7 @@ index 55873f5..0f6a0ae 100644
|
||||
if (packet3chat.a_()) {
|
||||
Waitable waitable = new Waitable() {
|
||||
@Override
|
||||
@@ -962,7 +974,7 @@ public class PlayerConnection extends Connection {
|
||||
@@ -961,7 +973,7 @@ public class PlayerConnection extends Connection {
|
||||
}
|
||||
|
||||
try {
|
||||
@ -293,7 +293,7 @@ index 55873f5..0f6a0ae 100644
|
||||
if (this.server.dispatchCommand(event.getPlayer(), event.getMessage().substring(1))) {
|
||||
return;
|
||||
}
|
||||
@@ -1345,8 +1357,9 @@ public class PlayerConnection extends Connection {
|
||||
@@ -1340,8 +1352,9 @@ public class PlayerConnection extends Connection {
|
||||
flag = false;
|
||||
} else {
|
||||
for (i = 0; i < packet130updatesign.lines[j].length(); ++i) {
|
||||
@ -305,10 +305,10 @@ index 55873f5..0f6a0ae 100644
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index 9e574be..900b6b8 100644
|
||||
index b7e327b..169fa90 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -305,7 +305,7 @@ public abstract class PlayerList {
|
||||
@@ -307,7 +307,7 @@ public abstract class PlayerList {
|
||||
|
||||
event.disallow(PlayerLoginEvent.Result.KICK_BANNED, s1);
|
||||
} else if (!this.isWhitelisted(s)) {
|
||||
@ -317,7 +317,7 @@ index 9e574be..900b6b8 100644
|
||||
} else {
|
||||
String s2 = socketaddress.toString();
|
||||
|
||||
@@ -1046,7 +1046,13 @@ public abstract class PlayerList {
|
||||
@@ -1048,7 +1048,13 @@ public abstract class PlayerList {
|
||||
|
||||
public void r() {
|
||||
while (!this.players.isEmpty()) {
|
||||
@ -333,7 +333,7 @@ index 9e574be..900b6b8 100644
|
||||
}
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
||||
index a7de90e..9181e37 100644
|
||||
index 3a4ddea..70dd295 100644
|
||||
--- a/src/main/java/net/minecraft/server/World.java
|
||||
+++ b/src/main/java/net/minecraft/server/World.java
|
||||
@@ -66,14 +66,27 @@ public abstract class World implements IBlockAccess {
|
||||
@ -601,7 +601,7 @@ index 49360c1..8114910 100644
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index 8a079d3..e5ceed1 100644
|
||||
index 6cb50b7..12c5f81 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -145,7 +145,7 @@ public final class CraftServer implements Server {
|
||||
@ -674,7 +674,7 @@ index 8a079d3..e5ceed1 100644
|
||||
loadPlugins();
|
||||
enablePlugins(PluginLoadOrder.STARTUP);
|
||||
enablePlugins(PluginLoadOrder.POSTWORLD);
|
||||
@@ -1055,13 +1072,8 @@ public final class CraftServer implements Server {
|
||||
@@ -1058,13 +1075,8 @@ public final class CraftServer implements Server {
|
||||
return count;
|
||||
}
|
||||
|
||||
@ -689,7 +689,7 @@ index 8a079d3..e5ceed1 100644
|
||||
OfflinePlayer result = getPlayerExact(name);
|
||||
String lname = name.toLowerCase();
|
||||
|
||||
@@ -1069,17 +1081,7 @@ public final class CraftServer implements Server {
|
||||
@@ -1072,17 +1084,7 @@ public final class CraftServer implements Server {
|
||||
result = offlinePlayers.get(lname);
|
||||
|
||||
if (result == null) {
|
||||
@ -708,7 +708,7 @@ index 8a079d3..e5ceed1 100644
|
||||
result = new CraftOfflinePlayer(this, name);
|
||||
offlinePlayers.put(lname, result);
|
||||
}
|
||||
@@ -1217,7 +1219,7 @@ public final class CraftServer implements Server {
|
||||
@@ -1220,7 +1222,7 @@ public final class CraftServer implements Server {
|
||||
Set<OfflinePlayer> players = new HashSet<OfflinePlayer>();
|
||||
|
||||
for (String file : files) {
|
||||
@ -717,7 +717,7 @@ index 8a079d3..e5ceed1 100644
|
||||
}
|
||||
players.addAll(Arrays.asList(getOnlinePlayers()));
|
||||
|
||||
@@ -1323,7 +1325,7 @@ public final class CraftServer implements Server {
|
||||
@@ -1326,7 +1328,7 @@ public final class CraftServer implements Server {
|
||||
public List<String> tabCompleteCommand(Player player, String message) {
|
||||
List<String> completions = null;
|
||||
try {
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 2e912ff97691c86ff0778304e3428423b57fc266 Mon Sep 17 00:00:00 2001
|
||||
From becc64aca459c1337bc4499542847edd3921a542 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Thu, 7 Mar 2013 20:12:46 +1100
|
||||
Subject: [PATCH] Async Operation Catching
|
||||
@ -46,7 +46,7 @@ index 5c03732..5f3c780 100644
|
||||
this.trackedPlayers.remove(entityplayer);
|
||||
entityplayer.removeQueue.add(Integer.valueOf(this.tracker.id));
|
||||
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
||||
index 319170a..69ef160 100644
|
||||
index b339688..3f9c453 100644
|
||||
--- a/src/main/java/net/minecraft/server/World.java
|
||||
+++ b/src/main/java/net/minecraft/server/World.java
|
||||
@@ -918,6 +918,7 @@ public abstract class World implements IBlockAccess {
|
||||
@ -65,7 +65,7 @@ index 319170a..69ef160 100644
|
||||
entity.die();
|
||||
if (entity instanceof EntityHuman) {
|
||||
this.players.remove(entity);
|
||||
@@ -2440,6 +2442,7 @@ public abstract class World implements IBlockAccess {
|
||||
@@ -2449,6 +2451,7 @@ public abstract class World implements IBlockAccess {
|
||||
}
|
||||
|
||||
public void a(List list) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
From d1df9385f8b785885e766baf48c136c43f78cafb Mon Sep 17 00:00:00 2001
|
||||
From 2618c34301c92122133a456f41ce4649bb552f0f Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Thu, 10 Jan 2013 00:18:11 -0500
|
||||
Subject: [PATCH] Improved Timings System
|
||||
@ -213,10 +213,10 @@ index 3c80340..044db9f 100644
|
||||
this.methodProfiler.b();
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index 0f6a0ae..51cc2ab 100644
|
||||
index bc55a77..2e1246e 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -963,6 +963,7 @@ public class PlayerConnection extends Connection {
|
||||
@@ -962,6 +962,7 @@ public class PlayerConnection extends Connection {
|
||||
// CraftBukkit end
|
||||
|
||||
private void handleCommand(String s) {
|
||||
@ -224,7 +224,7 @@ index 0f6a0ae..51cc2ab 100644
|
||||
// CraftBukkit start
|
||||
CraftPlayer player = this.getPlayer();
|
||||
|
||||
@@ -970,19 +971,23 @@ public class PlayerConnection extends Connection {
|
||||
@@ -969,19 +970,23 @@ public class PlayerConnection extends Connection {
|
||||
this.server.getPluginManager().callEvent(event);
|
||||
|
||||
if (event.isCancelled()) {
|
||||
@ -266,7 +266,7 @@ index db3fc42..174546d 100644
|
||||
private static Map b = new HashMap();
|
||||
protected World world;
|
||||
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
||||
index 9a3c492..b87865d 100644
|
||||
index 6d59bc3..feb657b 100644
|
||||
--- a/src/main/java/net/minecraft/server/World.java
|
||||
+++ b/src/main/java/net/minecraft/server/World.java
|
||||
@@ -13,6 +13,7 @@ import java.util.concurrent.Callable;
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 34aed5c5ebcedb2e9f2febe7f9bca1b41088c3d7 Mon Sep 17 00:00:00 2001
|
||||
From 1f308c0c10df4f1a1533de497d1ef098bb64b348 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Tue, 23 Apr 2013 11:47:32 +1000
|
||||
Subject: [PATCH] Netty
|
||||
@ -32,7 +32,7 @@ Subject: [PATCH] Netty
|
||||
Commons Attribution-ShareAlike 3.0 Unported license.
|
||||
|
||||
diff --git a/pom.xml b/pom.xml
|
||||
index 3c6062e..db5a904 100644
|
||||
index 274fd43..b0891ff 100644
|
||||
--- a/pom.xml
|
||||
+++ b/pom.xml
|
||||
@@ -132,6 +132,11 @@
|
||||
@ -218,10 +218,10 @@ index 17cfacc..a945892 100644
|
||||
this.b = true;
|
||||
} catch (Exception exception) {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index 20d38b4..f7ec7bb 100644
|
||||
index 767f3c3..028e7dd 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -1372,4 +1372,20 @@ public final class CraftServer implements Server {
|
||||
@@ -1375,4 +1375,20 @@ public final class CraftServer implements Server {
|
||||
public CraftScoreboardManager getScoreboardManager() {
|
||||
return scoreboardManager;
|
||||
}
|
||||
@ -1049,7 +1049,7 @@ index 0000000..a3b86b8
|
||||
+}
|
||||
diff --git a/src/main/java/org/spigotmc/netty/OutboundManager.java b/src/main/java/org/spigotmc/netty/OutboundManager.java
|
||||
new file mode 100644
|
||||
index 0000000..80205ed
|
||||
index 0000000..1961e89
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/org/spigotmc/netty/OutboundManager.java
|
||||
@@ -0,0 +1,18 @@
|
||||
@ -1061,7 +1061,7 @@ index 0000000..80205ed
|
||||
+
|
||||
+public class OutboundManager extends ChannelOperationHandlerAdapter {
|
||||
+
|
||||
+ private static final int FLUSH_TIME = 10;
|
||||
+ private static final int FLUSH_TIME = 5;
|
||||
+ private long lastFlush;
|
||||
+
|
||||
+ public void flush(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception {
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 437f4f06845834005b4f6a4b29e6dfb48dc43e12 Mon Sep 17 00:00:00 2001
|
||||
From 11b3b6b9add95dce5e0cbf9073b3bdd6bf04dd86 Mon Sep 17 00:00:00 2001
|
||||
From: EdGruberman <ed@rjump.com>
|
||||
Date: Tue, 12 Feb 2013 16:17:31 -0700
|
||||
Subject: [PATCH] Remove dependency on CraftPlayer.getBedSpawnLocation; Fixes
|
||||
@ -6,10 +6,10 @@ Subject: [PATCH] Remove dependency on CraftPlayer.getBedSpawnLocation; Fixes
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index da7ad33..eaeb0bf 100644
|
||||
index 169fa90..5ccc7f0 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -493,7 +493,14 @@ public abstract class PlayerList {
|
||||
@@ -495,7 +495,14 @@ public abstract class PlayerList {
|
||||
if (exitWorld != null) {
|
||||
if ((cause == TeleportCause.END_PORTAL) && (i == 0)) {
|
||||
// THE_END -> NORMAL; use bed if available, otherwise default spawn
|
||||
|
@ -1,14 +1,14 @@
|
||||
From 6925d236670621994218b1bd034015ab791087ad Mon Sep 17 00:00:00 2001
|
||||
From e22ea3833c0e389a95337ca3ece31fc2c86a1638 Mon Sep 17 00:00:00 2001
|
||||
From: Yariv Livay <yarivlivay@gmail.com>
|
||||
Date: Mon, 25 Feb 2013 22:26:36 +0200
|
||||
Subject: [PATCH] Adds BUKKIT-3667, Faux sleepers wake up normally
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
index 3b08937..40a808d 100644
|
||||
index 7de5b48..9925d1b 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
@@ -422,7 +422,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
|
||||
@@ -429,7 +429,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
|
||||
}
|
||||
|
||||
public void a(boolean flag, boolean flag1, boolean flag2) {
|
||||
|
@ -1,23 +0,0 @@
|
||||
From c542317812b69c939334e3fd219fc21285e63138 Mon Sep 17 00:00:00 2001
|
||||
From: Yariv Livay <yarivlivay@gmail.com>
|
||||
Date: Tue, 26 Feb 2013 20:14:34 +0200
|
||||
Subject: [PATCH] BUKKIT-3668 Fix wrong block in BlockDispenseEvent when
|
||||
filling empty bucket
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/DispenseBehaviorEmptyBucket.java b/src/main/java/net/minecraft/server/DispenseBehaviorEmptyBucket.java
|
||||
index 8f7e09b..ae65526 100644
|
||||
--- a/src/main/java/net/minecraft/server/DispenseBehaviorEmptyBucket.java
|
||||
+++ b/src/main/java/net/minecraft/server/DispenseBehaviorEmptyBucket.java
|
||||
@@ -32,7 +32,7 @@ final class DispenseBehaviorEmptyBucket extends DispenseBehaviorItem {
|
||||
}
|
||||
|
||||
// CraftBukkit start
|
||||
- org.bukkit.block.Block block = world.getWorld().getBlockAt(i, j, k);
|
||||
+ org.bukkit.block.Block block = world.getWorld().getBlockAt(isourceblock.getBlockX(), j, isourceblock.getBlockZ());
|
||||
CraftItemStack craftItem = CraftItemStack.asCraftMirror(itemstack);
|
||||
|
||||
BlockDispenseEvent event = new BlockDispenseEvent(block, craftItem.clone(), new org.bukkit.util.Vector(0, 0, 0));
|
||||
--
|
||||
1.8.2.1
|
||||
|
@ -1,11 +1,11 @@
|
||||
From ce904408636bb5118204626e7d83403be27e7aa6 Mon Sep 17 00:00:00 2001
|
||||
From ef7bf26d03fd9935ed9c20fb92c4b7c914289c2b Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Mon, 4 Mar 2013 18:45:52 +1100
|
||||
Subject: [PATCH] PlayerItemDamageEvent
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
|
||||
index 7dc36a8..cd032ae 100644
|
||||
index 343b8cb..9c2fce6 100644
|
||||
--- a/src/main/java/net/minecraft/server/ItemStack.java
|
||||
+++ b/src/main/java/net/minecraft/server/ItemStack.java
|
||||
@@ -178,7 +178,13 @@ public final class ItemStack {
|
@ -1,4 +1,4 @@
|
||||
From 5e437957841f72b02e11b9c257a5ac419aa5f43e Mon Sep 17 00:00:00 2001
|
||||
From 2bfdd388dbc9e19dfc44ff035965f8a6c8dc9c44 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Sun, 17 Mar 2013 19:02:50 +1100
|
||||
Subject: [PATCH] Faster UUID for entities
|
||||
@ -6,7 +6,7 @@ Subject: [PATCH] Faster UUID for entities
|
||||
It is overkill to create a new SecureRandom on each entity create and then use it to make a new Entity ID for every entity instance created. Instead we will just use a pseudo random UUID based off the random instance we already have.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Entity.java b/src/main/java/net/minecraft/server/Entity.java
|
||||
index f5203bc..c40cf71 100644
|
||||
index 79a8329..8767950 100644
|
||||
--- a/src/main/java/net/minecraft/server/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/server/Entity.java
|
||||
@@ -153,7 +153,7 @@ public abstract class Entity {
|
@ -1,4 +1,4 @@
|
||||
From 38e8948efeb9bf5b95d30e2ccf13ee16787bf257 Mon Sep 17 00:00:00 2001
|
||||
From 197f9a0e30e92fa4ab306414b9e8b974b70e6041 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Mon, 18 Mar 2013 20:01:44 +1100
|
||||
Subject: [PATCH] Prevent NPE in CraftSign
|
@ -1,4 +1,4 @@
|
||||
From f150656dd050bd27cf973319921bd5edaeb445ef Mon Sep 17 00:00:00 2001
|
||||
From 3b20c4c199e2c820818d87f31749077060e9e821 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Thu, 21 Mar 2013 17:00:54 +1100
|
||||
Subject: [PATCH] Stage DataWatcher & WatchableObject.
|
@ -1,4 +1,4 @@
|
||||
From 97e803109d5c03dd4d13e357b576da42dac7e10d Mon Sep 17 00:00:00 2001
|
||||
From ff8a78eac7eefda8f2ede945e227b4eedcc1ab3b Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Wed, 20 Feb 2013 11:58:47 -0500
|
||||
Subject: [PATCH] Entity Tracking Ranges
|
@ -1,4 +1,4 @@
|
||||
From f5c60523ba201c375800710ab1af7a02d47297c8 Mon Sep 17 00:00:00 2001
|
||||
From df4dce8d4d2f09f2ce8645c6a10ccaaf6db57254 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Sat, 23 Mar 2013 11:15:11 +1100
|
||||
Subject: [PATCH] BungeeCord Support
|
||||
@ -6,7 +6,7 @@ Subject: [PATCH] BungeeCord Support
|
||||
- Allows BungeeCord to set the players real IP address very early in the login process, so that the BungeeCord proxy IP is never even seen by a plugin.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PendingConnection.java b/src/main/java/net/minecraft/server/PendingConnection.java
|
||||
index 836ad94..72fb172 100644
|
||||
index a945892..7ef9a6f 100644
|
||||
--- a/src/main/java/net/minecraft/server/PendingConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PendingConnection.java
|
||||
@@ -221,4 +221,17 @@ public class PendingConnection extends Connection {
|
||||
@ -28,10 +28,10 @@ index 836ad94..72fb172 100644
|
||||
+ // Spigot end
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index eaeb0bf..6a09a9a 100644
|
||||
index 5ccc7f0..cc9c3ba 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -291,7 +291,7 @@ public abstract class PlayerList {
|
||||
@@ -293,7 +293,7 @@ public abstract class PlayerList {
|
||||
// depending on the outcome.
|
||||
EntityPlayer entity = new EntityPlayer(this.server, this.server.getWorldServer(0), s, this.server.M() ? new DemoPlayerInteractManager(this.server.getWorldServer(0)) : new PlayerInteractManager(this.server.getWorldServer(0)));
|
||||
Player player = entity.getBukkitEntity();
|
||||
@ -41,7 +41,7 @@ index eaeb0bf..6a09a9a 100644
|
||||
SocketAddress socketaddress = pendingconnection.networkManager.getSocketAddress();
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/ThreadLoginVerifier.java b/src/main/java/net/minecraft/server/ThreadLoginVerifier.java
|
||||
index 9ed3db5..c6d1253 100644
|
||||
index fcd4136..fb4ec7b 100644
|
||||
--- a/src/main/java/net/minecraft/server/ThreadLoginVerifier.java
|
||||
+++ b/src/main/java/net/minecraft/server/ThreadLoginVerifier.java
|
||||
@@ -45,11 +45,11 @@ class ThreadLoginVerifier extends Thread {
|
||||
@ -59,7 +59,7 @@ index 9ed3db5..c6d1253 100644
|
||||
event.disallow(asyncEvent.getResult(), asyncEvent.getKickMessage());
|
||||
}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Spigot.java b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
index 1117309..015976b 100644
|
||||
index afa0f04..e1db1be 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
@@ -54,6 +54,7 @@ public class Spigot {
|
@ -1,4 +1,4 @@
|
||||
From 79e7558e9ded4e59921970448185b49c491eab9b Mon Sep 17 00:00:00 2001
|
||||
From 6524a3b75751f2b723d6999a2ab08374b7409dbd Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Sat, 23 Mar 2013 13:04:45 +1100
|
||||
Subject: [PATCH] Texture Pack Resolutions
|
@ -1,4 +1,4 @@
|
||||
From 2ef5eefd8a0c8d7cd62ac2e06125498151e82cf8 Mon Sep 17 00:00:00 2001
|
||||
From 6d8484689bc3524ca94f90821051cb5679c633f4 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Sat, 23 Mar 2013 19:08:41 +1100
|
||||
Subject: [PATCH] Limit Custom Map Rendering
|
@ -1,4 +1,4 @@
|
||||
From 069d9d32aa69bf222282dd892c5948394905defd Mon Sep 17 00:00:00 2001
|
||||
From 50181317d1a383df33e5ae9ddcde5fbe0fd8fcd0 Mon Sep 17 00:00:00 2001
|
||||
From: Hudson <hudson@mydomain.com>
|
||||
Date: Wed, 3 Apr 2013 02:16:56 -0500
|
||||
Subject: [PATCH] Revert "Throw exception for disabled plugin tasks. Fixes
|
||||
@ -7,7 +7,7 @@ Subject: [PATCH] Revert "Throw exception for disabled plugin tasks. Fixes
|
||||
This reverts commit 052e955ed71a30516a5e9cfd76649daaba4ae7d8.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java b/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
|
||||
index a30f217..35badf3 100644
|
||||
index 84dcfcc..0a5c61a 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/scheduler/CraftScheduler.java
|
||||
@@ -15,7 +15,6 @@ import java.util.concurrent.atomic.AtomicReference;
|
@ -1,4 +1,4 @@
|
||||
From d7e2842e4c89045f0f2eed6ac58a6326daa905d0 Mon Sep 17 00:00:00 2001
|
||||
From 0aa4fb4c7cd3c73c1bbc8234cc21d677d9505233 Mon Sep 17 00:00:00 2001
|
||||
From: Tyler Blair <hidendra@griefcraft.com>
|
||||
Date: Tue, 9 Apr 2013 17:55:15 -0300
|
||||
Subject: [PATCH] InventoryClickEvent now can return if the click was a double
|
||||
@ -7,10 +7,10 @@ Subject: [PATCH] InventoryClickEvent now can return if the click was a double
|
||||
Added in MC 1.5 you can now double click an item which brings all items of that type onto your cursor from the container. There is currently no way to distinguish this from a normal click.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index a2d95e3..a1c2442 100644
|
||||
index 2e1246e..0621625 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -1183,12 +1183,12 @@ public class PlayerConnection extends Connection {
|
||||
@@ -1178,12 +1178,12 @@ public class PlayerConnection extends Connection {
|
||||
InventoryView inventory = this.player.activeContainer.getBukkitView();
|
||||
SlotType type = CraftInventoryView.getSlotType(inventory, packet102windowclick.slot);
|
||||
|
||||
@ -25,7 +25,7 @@ index a2d95e3..a1c2442 100644
|
||||
}
|
||||
}
|
||||
server.getPluginManager().callEvent(event);
|
||||
@@ -1276,7 +1276,7 @@ public class PlayerConnection extends Connection {
|
||||
@@ -1271,7 +1271,7 @@ public class PlayerConnection extends Connection {
|
||||
slot = SlotType.OUTSIDE;
|
||||
}
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 1f5108837838e843ddb91982255bab80bc77cc1e Mon Sep 17 00:00:00 2001
|
||||
From 5317680eeb4c666e77c17c152d8ae184890c42f4 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sun, 24 Feb 2013 20:45:20 +1100
|
||||
Subject: [PATCH] Enable Improved ping sending
|
||||
@ -8,7 +8,7 @@ Subject: [PATCH] Enable Improved ping sending
|
||||
3 files changed, 18 insertions(+)
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
index 735eb8a..b23b9ce 100644
|
||||
index 9925d1b..5fa0b05 100644
|
||||
--- a/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
+++ b/src/main/java/net/minecraft/server/EntityPlayer.java
|
||||
@@ -51,6 +51,7 @@ public class EntityPlayer extends EntityHuman implements ICrafting {
|
||||
@ -20,10 +20,10 @@ index 735eb8a..b23b9ce 100644
|
||||
|
||||
public EntityPlayer(MinecraftServer minecraftserver, World world, String s, PlayerInteractManager playerinteractmanager) {
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
index eaeb0bf..f94cc54 100644
|
||||
index cc9c3ba..319974b 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerList.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerList.java
|
||||
@@ -722,7 +722,23 @@ public abstract class PlayerList {
|
||||
@@ -724,7 +724,23 @@ public abstract class PlayerList {
|
||||
this.sendAll(new Packet201PlayerInfo(entityplayer.name, true, entityplayer.ping));
|
||||
}
|
||||
// CraftBukkit end */
|
@ -1,4 +1,4 @@
|
||||
From 69c0a45a175c50a7d1dc812c4c0b978a9ba26307 Mon Sep 17 00:00:00 2001
|
||||
From 7a1b263624e29ee530bb982c6eb430b1b78cf8e0 Mon Sep 17 00:00:00 2001
|
||||
From: Benjamin James Harrison-Sims <tehrainbowguy@gmail.com>
|
||||
Date: Sun, 14 Apr 2013 21:19:57 +0500
|
||||
Subject: [PATCH] Prevent handshake spam from invalid names.
|
||||
@ -25,7 +25,7 @@ index 343af93..aa6609b 100644
|
||||
|
||||
public void a(DataOutputStream dataoutputstream) throws IOException { // CraftBukkit - throws IOException
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Spigot.java b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
index fa0b268..1f61d23 100644
|
||||
index 0e917e2..a3849b9 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
@@ -6,6 +6,7 @@ import java.net.InetAddress;
|
@ -1,4 +1,4 @@
|
||||
From 22a4dd8388a22d36b13e0a6d63c8802489647335 Mon Sep 17 00:00:00 2001
|
||||
From deaa953a5963c36f4bda603411fa6905e390869e Mon Sep 17 00:00:00 2001
|
||||
From: Ammar Askar <ammar@ammaraskar.com>
|
||||
Date: Sat, 20 Apr 2013 12:26:20 +0500
|
||||
Subject: [PATCH] Save entity counts for randomly spawned creatures to avoid
|
||||
@ -6,7 +6,7 @@ Subject: [PATCH] Save entity counts for randomly spawned creatures to avoid
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index 7f1c155..11e1a4e 100644
|
||||
index 7416edc..958b5af 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Chunk.java
|
||||
@@ -9,6 +9,7 @@ import java.util.Map;
|
||||
@ -54,7 +54,7 @@ index 7f1c155..11e1a4e 100644
|
||||
|
||||
public boolean d(int i, int j, int k) {
|
||||
diff --git a/src/main/java/net/minecraft/server/SpawnerCreature.java b/src/main/java/net/minecraft/server/SpawnerCreature.java
|
||||
index 6362a37..2c3b94d 100644
|
||||
index 3529074..25b83f7 100644
|
||||
--- a/src/main/java/net/minecraft/server/SpawnerCreature.java
|
||||
+++ b/src/main/java/net/minecraft/server/SpawnerCreature.java
|
||||
@@ -33,14 +33,8 @@ public final class SpawnerCreature {
|
@ -1,382 +0,0 @@
|
||||
From 96d4fdc902484c9a4762423c931cd53f85f500d7 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Fri, 19 Apr 2013 19:13:42 +1000
|
||||
Subject: [PATCH] Snapshot Protocol
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
|
||||
index cd032ae..14da2b9 100644
|
||||
--- a/src/main/java/net/minecraft/server/ItemStack.java
|
||||
+++ b/src/main/java/net/minecraft/server/ItemStack.java
|
||||
@@ -41,6 +41,7 @@ public final class ItemStack {
|
||||
this.id = i;
|
||||
this.count = j;
|
||||
// CraftBukkit start - Pass to setData to do filtering
|
||||
+ if (org.bukkit.craftbukkit.Spigot.snapshotSupport && this.id >= 170 && this.id <= 171) this.id = 0; // Spigot
|
||||
this.setData(k);
|
||||
//if (this.damage < 0) {
|
||||
// this.damage = 0;
|
||||
diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
index a1d77ad..ad6cc57 100644
|
||||
--- a/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/MinecraftServer.java
|
||||
@@ -753,7 +753,7 @@ public abstract class MinecraftServer implements ICommandListener, Runnable, IMo
|
||||
}
|
||||
|
||||
public String getVersion() {
|
||||
- return "1.5.1";
|
||||
+ return (org.bukkit.craftbukkit.Spigot.snapshotSupport) ? org.bukkit.craftbukkit.Spigot.snapshotVersion : "1.5.1";
|
||||
}
|
||||
|
||||
public int y() {
|
||||
diff --git a/src/main/java/net/minecraft/server/Packet19EntityAction.java b/src/main/java/net/minecraft/server/Packet19EntityAction.java
|
||||
new file mode 100644
|
||||
index 0000000..259dcbb
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/net/minecraft/server/Packet19EntityAction.java
|
||||
@@ -0,0 +1,32 @@
|
||||
+package net.minecraft.server;
|
||||
+
|
||||
+import java.io.DataInputStream;
|
||||
+import java.io.DataOutputStream;
|
||||
+import java.io.IOException;
|
||||
+
|
||||
+public class Packet19EntityAction extends Packet {
|
||||
+
|
||||
+ public int a;
|
||||
+ public int animation;
|
||||
+
|
||||
+ public Packet19EntityAction() {}
|
||||
+
|
||||
+ public void a(DataInputStream datainputstream) throws IOException {
|
||||
+ this.a = datainputstream.readInt();
|
||||
+ this.animation = datainputstream.readByte();
|
||||
+ if (org.bukkit.craftbukkit.Spigot.snapshotSupport) datainputstream.readInt(); // Spigot
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataOutputStream dataoutputstream) throws IOException {
|
||||
+ dataoutputstream.writeInt(this.a);
|
||||
+ dataoutputstream.writeByte(this.animation);
|
||||
+ }
|
||||
+
|
||||
+ public void handle(Connection connection) {
|
||||
+ connection.a(this);
|
||||
+ }
|
||||
+
|
||||
+ public int a() {
|
||||
+ return 5;
|
||||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/net/minecraft/server/Packet202Abilities.java b/src/main/java/net/minecraft/server/Packet202Abilities.java
|
||||
new file mode 100644
|
||||
index 0000000..2a2dad5
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/net/minecraft/server/Packet202Abilities.java
|
||||
@@ -0,0 +1,131 @@
|
||||
+package net.minecraft.server;
|
||||
+
|
||||
+import java.io.DataInputStream;
|
||||
+import java.io.DataOutputStream;
|
||||
+import java.io.IOException;
|
||||
+
|
||||
+public class Packet202Abilities extends Packet {
|
||||
+
|
||||
+ private boolean a = false;
|
||||
+ private boolean b = false;
|
||||
+ private boolean c = false;
|
||||
+ private boolean d = false;
|
||||
+ private float e;
|
||||
+ private float f;
|
||||
+
|
||||
+ public Packet202Abilities() {}
|
||||
+
|
||||
+ public Packet202Abilities(PlayerAbilities playerabilities) {
|
||||
+ this.a(playerabilities.isInvulnerable);
|
||||
+ this.b(playerabilities.isFlying);
|
||||
+ this.c(playerabilities.canFly);
|
||||
+ this.d(playerabilities.canInstantlyBuild);
|
||||
+ this.a(playerabilities.a());
|
||||
+ this.b(playerabilities.b());
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataInputStream datainputstream) throws IOException {
|
||||
+ byte b0 = datainputstream.readByte();
|
||||
+
|
||||
+ this.a((b0 & 1) > 0);
|
||||
+ this.b((b0 & 2) > 0);
|
||||
+ this.c((b0 & 4) > 0);
|
||||
+ this.d((b0 & 8) > 0);
|
||||
+ // Spigot start
|
||||
+ if (org.bukkit.craftbukkit.Spigot.snapshotSupport) {
|
||||
+ this.a(datainputstream.readFloat());
|
||||
+ this.b(datainputstream.readFloat());
|
||||
+ } else {
|
||||
+ this.a((float) datainputstream.readByte() / 255.0F);
|
||||
+ this.b((float) datainputstream.readByte() / 255.0F);
|
||||
+ }
|
||||
+ // Spigot end
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataOutputStream dataoutputstream) throws IOException {
|
||||
+ byte b0 = 0;
|
||||
+
|
||||
+ if (this.d()) {
|
||||
+ b0 = (byte) (b0 | 1);
|
||||
+ }
|
||||
+
|
||||
+ if (this.f()) {
|
||||
+ b0 = (byte) (b0 | 2);
|
||||
+ }
|
||||
+
|
||||
+ if (this.g()) {
|
||||
+ b0 = (byte) (b0 | 4);
|
||||
+ }
|
||||
+
|
||||
+ if (this.h()) {
|
||||
+ b0 = (byte) (b0 | 8);
|
||||
+ }
|
||||
+
|
||||
+ dataoutputstream.writeByte(b0);
|
||||
+ // Spigot start
|
||||
+ if (org.bukkit.craftbukkit.Spigot.snapshotSupport) {
|
||||
+ dataoutputstream.writeFloat(this.e);
|
||||
+ dataoutputstream.writeFloat(this.f);
|
||||
+ } else {
|
||||
+ dataoutputstream.writeByte((int) (this.e * 255.0F));
|
||||
+ dataoutputstream.writeByte((int) (this.f * 255.0F));
|
||||
+ }
|
||||
+ // Spigot end
|
||||
+ }
|
||||
+
|
||||
+ public void handle(Connection connection) {
|
||||
+ connection.a(this);
|
||||
+ }
|
||||
+
|
||||
+ public int a() {
|
||||
+ return 2;
|
||||
+ }
|
||||
+
|
||||
+ public boolean d() {
|
||||
+ return this.a;
|
||||
+ }
|
||||
+
|
||||
+ public void a(boolean flag) {
|
||||
+ this.a = flag;
|
||||
+ }
|
||||
+
|
||||
+ public boolean f() {
|
||||
+ return this.b;
|
||||
+ }
|
||||
+
|
||||
+ public void b(boolean flag) {
|
||||
+ this.b = flag;
|
||||
+ }
|
||||
+
|
||||
+ public boolean g() {
|
||||
+ return this.c;
|
||||
+ }
|
||||
+
|
||||
+ public void c(boolean flag) {
|
||||
+ this.c = flag;
|
||||
+ }
|
||||
+
|
||||
+ public boolean h() {
|
||||
+ return this.d;
|
||||
+ }
|
||||
+
|
||||
+ public void d(boolean flag) {
|
||||
+ this.d = flag;
|
||||
+ }
|
||||
+
|
||||
+ public void a(float f) {
|
||||
+ this.e = f;
|
||||
+ }
|
||||
+
|
||||
+ public void b(float f) {
|
||||
+ this.f = f;
|
||||
+ }
|
||||
+
|
||||
+ public boolean e() {
|
||||
+ return true;
|
||||
+ }
|
||||
+
|
||||
+ public boolean a(Packet packet) {
|
||||
+ return true;
|
||||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/net/minecraft/server/Packet39AttachEntity.java b/src/main/java/net/minecraft/server/Packet39AttachEntity.java
|
||||
new file mode 100644
|
||||
index 0000000..a728ace
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/net/minecraft/server/Packet39AttachEntity.java
|
||||
@@ -0,0 +1,47 @@
|
||||
+package net.minecraft.server;
|
||||
+
|
||||
+import java.io.DataInputStream;
|
||||
+import java.io.DataOutputStream;
|
||||
+import java.io.IOException;
|
||||
+
|
||||
+public class Packet39AttachEntity extends Packet {
|
||||
+
|
||||
+ public int a;
|
||||
+ public int b;
|
||||
+
|
||||
+ public Packet39AttachEntity() {}
|
||||
+
|
||||
+ public Packet39AttachEntity(Entity entity, Entity entity1) {
|
||||
+ this.a = entity.id;
|
||||
+ this.b = entity1 != null ? entity1.id : -1;
|
||||
+ }
|
||||
+
|
||||
+ public int a() {
|
||||
+ return 8;
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataInputStream datainputstream) throws IOException {
|
||||
+ this.a = datainputstream.readInt();
|
||||
+ this.b = datainputstream.readInt();
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataOutputStream dataoutputstream) throws IOException {
|
||||
+ dataoutputstream.writeInt(this.a);
|
||||
+ dataoutputstream.writeInt(this.b);
|
||||
+ if (org.bukkit.craftbukkit.Spigot.snapshotSupport) dataoutputstream.writeBoolean(false); // Spigot
|
||||
+ }
|
||||
+
|
||||
+ public void handle(Connection connection) {
|
||||
+ connection.a(this);
|
||||
+ }
|
||||
+
|
||||
+ public boolean e() {
|
||||
+ return true;
|
||||
+ }
|
||||
+
|
||||
+ public boolean a(Packet packet) {
|
||||
+ Packet39AttachEntity packet39attachentity = (Packet39AttachEntity) packet;
|
||||
+
|
||||
+ return packet39attachentity.a == this.a;
|
||||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/net/minecraft/server/Packet8UpdateHealth.java b/src/main/java/net/minecraft/server/Packet8UpdateHealth.java
|
||||
new file mode 100644
|
||||
index 0000000..bbfbb88
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/net/minecraft/server/Packet8UpdateHealth.java
|
||||
@@ -0,0 +1,52 @@
|
||||
+package net.minecraft.server;
|
||||
+
|
||||
+import java.io.DataInputStream;
|
||||
+import java.io.DataOutputStream;
|
||||
+import java.io.IOException;
|
||||
+
|
||||
+public class Packet8UpdateHealth extends Packet {
|
||||
+
|
||||
+ public float a;
|
||||
+ public int b;
|
||||
+ public float c;
|
||||
+
|
||||
+ public Packet8UpdateHealth() {}
|
||||
+
|
||||
+ public Packet8UpdateHealth(int i, int j, float f) {
|
||||
+ this.a = i;
|
||||
+ this.b = j;
|
||||
+ this.c = f;
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataInputStream datainputstream) throws IOException {
|
||||
+ this.a = datainputstream.readShort();
|
||||
+ this.b = datainputstream.readShort();
|
||||
+ this.c = datainputstream.readFloat();
|
||||
+ }
|
||||
+
|
||||
+ public void a(DataOutputStream dataoutputstream) throws IOException {
|
||||
+ if (org.bukkit.craftbukkit.Spigot.snapshotSupport) {
|
||||
+ dataoutputstream.writeFloat(this.a);
|
||||
+ } else {
|
||||
+ dataoutputstream.writeShort((short) this.a);
|
||||
+ }
|
||||
+ dataoutputstream.writeShort(this.b);
|
||||
+ dataoutputstream.writeFloat(this.c);
|
||||
+ }
|
||||
+
|
||||
+ public void handle(Connection connection) {
|
||||
+ connection.a(this);
|
||||
+ }
|
||||
+
|
||||
+ public int a() {
|
||||
+ return 8;
|
||||
+ }
|
||||
+
|
||||
+ public boolean e() {
|
||||
+ return true;
|
||||
+ }
|
||||
+
|
||||
+ public boolean a(Packet packet) {
|
||||
+ return true;
|
||||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/net/minecraft/server/PendingConnection.java b/src/main/java/net/minecraft/server/PendingConnection.java
|
||||
index 72fb172..9e5035a 100644
|
||||
--- a/src/main/java/net/minecraft/server/PendingConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PendingConnection.java
|
||||
@@ -77,8 +77,8 @@ public class PendingConnection extends Connection {
|
||||
} else {
|
||||
PublicKey publickey = this.server.F().getPublic();
|
||||
|
||||
- if (packet2handshake.d() != 60) {
|
||||
- if (packet2handshake.d() > 60) {
|
||||
+ if (packet2handshake.d() != ((org.bukkit.craftbukkit.Spigot.snapshotSupport) ? org.bukkit.craftbukkit.Spigot.snapshotProtocolVersion : 60)) {
|
||||
+ if (packet2handshake.d() > ((org.bukkit.craftbukkit.Spigot.snapshotSupport) ? org.bukkit.craftbukkit.Spigot.snapshotProtocolVersion : 60)) {
|
||||
this.disconnect("Outdated server!");
|
||||
} else {
|
||||
this.disconnect("Outdated client!");
|
||||
@@ -153,7 +153,7 @@ public class PendingConnection extends Connection {
|
||||
|
||||
if (true) {
|
||||
// CraftBukkit start - Fix decompile issues, don't create a list from an array
|
||||
- Object[] list = new Object[] { 1, 60, this.server.getVersion(), pingEvent.getMotd(), playerlist.getPlayerCount(), pingEvent.getMaxPlayers() };
|
||||
+ Object[] list = new Object[]{1, ((org.bukkit.craftbukkit.Spigot.snapshotSupport) ? org.bukkit.craftbukkit.Spigot.snapshotProtocolVersion : 60), this.server.getVersion(), pingEvent.getMotd(), playerlist.getPlayerCount(), pingEvent.getMaxPlayers()};
|
||||
|
||||
for (Object object : list) {
|
||||
if (s == null) {
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/Spigot.java b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
index 1f61d23..fcdad66 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/Spigot.java
|
||||
@@ -58,6 +58,9 @@ public class Spigot {
|
||||
public static List<String> bungeeIPs;
|
||||
public static int textureResolution = 16;
|
||||
public static final Pattern validName = Pattern.compile("^[a-zA-Z0-9_-]{2,16}$");
|
||||
+ public static boolean snapshotSupport;
|
||||
+ public static int snapshotProtocolVersion = 62;
|
||||
+ public static String snapshotVersion = "13w16a";
|
||||
|
||||
public static void initialize(CraftServer server, SimpleCommandMap commandMap, YamlConfiguration configuration) {
|
||||
commandMap.register("bukkit", new org.bukkit.craftbukkit.command.TicksPerSecondCommand("tps"));
|
||||
@@ -97,6 +100,10 @@ public class Spigot {
|
||||
tabPing = configuration.getBoolean("settings.tab-ping", tabPing);
|
||||
bungeeIPs = configuration.getStringList("settings.bungee-proxies");
|
||||
textureResolution = configuration.getInt("settings.texture-resolution", textureResolution);
|
||||
+ snapshotSupport = configuration.getBoolean("settings.snapshot-protocol", snapshotSupport);
|
||||
+ if (snapshotSupport) {
|
||||
+ server.getLogger().log(Level.INFO, "Enabled support for pre release / snapshot version {0}", snapshotVersion);
|
||||
+ }
|
||||
|
||||
if (metrics == null) {
|
||||
try {
|
||||
diff --git a/src/main/resources/configurations/bukkit.yml b/src/main/resources/configurations/bukkit.yml
|
||||
index 871b984..e1ec284 100644
|
||||
--- a/src/main/resources/configurations/bukkit.yml
|
||||
+++ b/src/main/resources/configurations/bukkit.yml
|
||||
@@ -41,6 +41,8 @@ settings:
|
||||
bungee-proxies:
|
||||
- 127.0.0.1
|
||||
texture-resolution: 16
|
||||
+ # fakes the latest pre release / snapshot
|
||||
+ snapshot-protocol: false
|
||||
world-settings:
|
||||
default:
|
||||
growth-chunks-per-tick: 650
|
||||
--
|
||||
1.8.2.1
|
||||
|
@ -1,4 +1,4 @@
|
||||
From 26d813326fc2c7c59b2037a2b1de8b3d3db0b660 Mon Sep 17 00:00:00 2001
|
||||
From 357aaae4276ecb50801aa79a62049399d9f160c7 Mon Sep 17 00:00:00 2001
|
||||
From: md_5 <md_5@live.com.au>
|
||||
Date: Tue, 23 Apr 2013 11:50:27 +1000
|
||||
Subject: [PATCH] Thread Naming and Tweaks
|
||||
@ -6,7 +6,7 @@ Subject: [PATCH] Thread Naming and Tweaks
|
||||
Removes the sleep forever thread and adds useful names for debugging to all staged thread files.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/DedicatedServer.java b/src/main/java/net/minecraft/server/DedicatedServer.java
|
||||
index b04d8a1..a271510 100644
|
||||
index 097be65..f37c784 100644
|
||||
--- a/src/main/java/net/minecraft/server/DedicatedServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/DedicatedServer.java
|
||||
@@ -34,7 +34,7 @@ public class DedicatedServer extends MinecraftServer implements IMinecraftServer
|
@ -1,4 +1,4 @@
|
||||
From b9d09022528f4e43799bc85e44e915256585d004 Mon Sep 17 00:00:00 2001
|
||||
From eba4a4425c443769e26a64640532f43d2bee04cc Mon Sep 17 00:00:00 2001
|
||||
From: Antony Riley <antony@cyberiantiger.org>
|
||||
Date: Wed, 27 Mar 2013 01:41:54 +0200
|
||||
Subject: [PATCH] Fixes BUKKIT-3893 - Close world save files when world is
|
||||
@ -19,7 +19,7 @@ index 900ed68..829f4a3 100644
|
||||
public static synchronized RegionFile a(File file1, int i, int j) {
|
||||
File file2 = new File(file1, "region");
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
index f7ec7bb..f19c600 100644
|
||||
index 028e7dd..94d6728 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||||
@@ -37,6 +37,8 @@ import net.minecraft.server.MinecraftServer;
|
Loading…
Reference in New Issue
Block a user