mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-14 22:55:43 +01:00
Update from upstream SpigotMC
Included Commits: Update IRC channel to irc.spi.gt SpigotMC/Spigot@a791c555e7 Remove inv close patch for now SpigotMC/Spigot@a3abb3bea9 Limit TNT Detonations per tick SpigotMC/Spigot@8f9c601aed Use sane default config values SpigotMC/Spigot@1cbbb9b62e These commits were not included as they were quickly reverted: Only close if we are actually placing a block SpigotMC/Spigot@ea0b1b2d67 Revert for the above SpigotMC/Spigot@28faa0bd20 Add isUnbreakable and setUnbreakable to ItemMeta. Also fixes a bug wh... SpigotMC/Spigot@32e6d74a5f Revert for the above SpigotMC/Spigot@4b5a26b11c
This commit is contained in:
parent
825584d02f
commit
f7bb4ad8a3
@ -1,4 +1,4 @@
|
|||||||
From d86f6761992a8b01d66ef6ab05cf8f860e95281b Mon Sep 17 00:00:00 2001
|
From b0b019f1d567c0c730eff3b2ee36d5a39577caa2 Mon Sep 17 00:00:00 2001
|
||||||
From: md_5 <md_5@live.com.au>
|
From: md_5 <md_5@live.com.au>
|
||||||
Date: Sun, 7 Jul 2013 09:32:53 +1000
|
Date: Sun, 7 Jul 2013 09:32:53 +1000
|
||||||
Subject: [PATCH] Spigot Configuration
|
Subject: [PATCH] Spigot Configuration
|
||||||
@ -96,7 +96,7 @@ index eb0b342..d997b48 100644
|
|||||||
int pollCount = 0;
|
int pollCount = 0;
|
||||||
diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java
|
diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java
|
||||||
new file mode 100644
|
new file mode 100644
|
||||||
index 0000000..f662b81
|
index 0000000..14c1ab1
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/src/main/java/org/spigotmc/SpigotConfig.java
|
+++ b/src/main/java/org/spigotmc/SpigotConfig.java
|
||||||
@@ -0,0 +1,138 @@
|
@@ -0,0 +1,138 @@
|
||||||
@ -131,8 +131,8 @@ index 0000000..f662b81
|
|||||||
+ + "If you need help with the configuration or have any questions related to Spigot,\n"
|
+ + "If you need help with the configuration or have any questions related to Spigot,\n"
|
||||||
+ + "join us at the IRC or drop by our forums and leave a post.\n"
|
+ + "join us at the IRC or drop by our forums and leave a post.\n"
|
||||||
+ + "\n"
|
+ + "\n"
|
||||||
+ + "IRC: #spigot @ irc.esper.net ( http://webchat.esper.net/?channel=spigot )\n"
|
+ + "IRC: #spigot @ irc.spi.gt ( http://www.spigotmc.org/pages/irc/ )\n"
|
||||||
+ + "Forums: http://www.spigotmc.org/forum/\n";
|
+ + "Forums: http://www.spigotmc.org/\n";
|
||||||
+ /*========================================================================*/
|
+ /*========================================================================*/
|
||||||
+ static YamlConfiguration config;
|
+ static YamlConfiguration config;
|
||||||
+ static int version;
|
+ static int version;
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
From 8cc0ac9b426998dcb6684d0dc0bbb1c5193dc428 Mon Sep 17 00:00:00 2001
|
From 42fa34d21062c6f5194272318d7bf2047642e4b7 Mon Sep 17 00:00:00 2001
|
||||||
From: Aikar <aikar@aikar.co>
|
From: Aikar <aikar@aikar.co>
|
||||||
Date: Fri, 15 Aug 2014 00:56:41 -0400
|
Date: Fri, 15 Aug 2014 00:56:41 -0400
|
||||||
Subject: [PATCH] Fix Corrupted Trapped Chest
|
Subject: [PATCH] Fix Corrupted Trapped Chest
|
@ -1,52 +0,0 @@
|
|||||||
From 8b5cf125f23b9f8d8910283e4f6dd484442aaec1 Mon Sep 17 00:00:00 2001
|
|
||||||
From: md_5 <git@md-5.net>
|
|
||||||
Date: Sun, 10 Aug 2014 11:01:02 +1000
|
|
||||||
Subject: [PATCH] Force Close Inventory On Move
|
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
|
||||||
index 188393c..5aea702 100644
|
|
||||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
|
||||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
|
||||||
@@ -489,6 +489,12 @@ public class PlayerConnection implements PacketPlayInListener {
|
|
||||||
|
|
||||||
public void a(PacketPlayInBlockDig packetplayinblockdig) {
|
|
||||||
if (this.player.dead) return; // CraftBukkit
|
|
||||||
+ // Spigot start
|
|
||||||
+ if ( player.activeContainer != player.defaultContainer )
|
|
||||||
+ {
|
|
||||||
+ getPlayer().closeInventory();
|
|
||||||
+ }
|
|
||||||
+ // Spigot end
|
|
||||||
WorldServer worldserver = this.minecraftServer.getWorldServer(this.player.dimension);
|
|
||||||
|
|
||||||
this.player.v();
|
|
||||||
@@ -615,6 +621,12 @@ public class PlayerConnection implements PacketPlayInListener {
|
|
||||||
// a notch bug where the item doesn't update correctly.
|
|
||||||
boolean always = false;
|
|
||||||
// CraftBukkit end
|
|
||||||
+ // Spigot start
|
|
||||||
+ if ( player.activeContainer != player.defaultContainer )
|
|
||||||
+ {
|
|
||||||
+ getPlayer().closeInventory();
|
|
||||||
+ }
|
|
||||||
+ // Spigot end
|
|
||||||
|
|
||||||
ItemStack itemstack = this.player.inventory.getItemInHand();
|
|
||||||
boolean flag = false;
|
|
||||||
@@ -1118,6 +1130,12 @@ public class PlayerConnection implements PacketPlayInListener {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
// Spigot End
|
|
||||||
+ // Spigot start
|
|
||||||
+ if ( player.activeContainer != player.defaultContainer )
|
|
||||||
+ {
|
|
||||||
+ getPlayer().closeInventory();
|
|
||||||
+ }
|
|
||||||
+ // Spigot end
|
|
||||||
|
|
||||||
this.player.v();
|
|
||||||
if (entity != null) {
|
|
||||||
--
|
|
||||||
1.9.1
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
From e7e76aa6d06aabea125cc9a9fb0664f4f0020765 Mon Sep 17 00:00:00 2001
|
From a401f5a0a27c9beaebfd02a1bc214fa50118c2f9 Mon Sep 17 00:00:00 2001
|
||||||
From: drXor <mcyoung@mit.edu>
|
From: drXor <mcyoung@mit.edu>
|
||||||
Date: Fri, 15 Aug 2014 18:11:09 -0400
|
Date: Fri, 15 Aug 2014 18:11:09 -0400
|
||||||
Subject: [PATCH] Remove uneeded validation
|
Subject: [PATCH] Remove uneeded validation
|
@ -1,4 +1,4 @@
|
|||||||
From 928c29946c3fcbf3f4433f6c3f3f92ea60433cf1 Mon Sep 17 00:00:00 2001
|
From 6e3b4b38ab18024ef13fef6e237196a531d1e963 Mon Sep 17 00:00:00 2001
|
||||||
From: lazertester <austin.techhead@gmail.com>
|
From: lazertester <austin.techhead@gmail.com>
|
||||||
Date: Sun, 17 Aug 2014 19:56:17 +1000
|
Date: Sun, 17 Aug 2014 19:56:17 +1000
|
||||||
Subject: [PATCH] Add Hunger Config Values
|
Subject: [PATCH] Add Hunger Config Values
|
@ -1,11 +1,11 @@
|
|||||||
From c71d321e676a2c349ad719f7f09e391813a40ce6 Mon Sep 17 00:00:00 2001
|
From 4644c2624b3fc482658e05be0307ae37a3419127 Mon Sep 17 00:00:00 2001
|
||||||
From: Minecrell <dev@minecrell.net>
|
From: Minecrell <dev@minecrell.net>
|
||||||
Date: Sun, 17 Aug 2014 12:42:53 +0200
|
Date: Sun, 17 Aug 2014 12:42:53 +0200
|
||||||
Subject: [PATCH] Make debug logging togglable.
|
Subject: [PATCH] Make debug logging togglable.
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java
|
diff --git a/src/main/java/org/spigotmc/SpigotConfig.java b/src/main/java/org/spigotmc/SpigotConfig.java
|
||||||
index 9d2dfe9..fdc64d3 100644
|
index f3630ec..919c83c 100644
|
||||||
--- a/src/main/java/org/spigotmc/SpigotConfig.java
|
--- a/src/main/java/org/spigotmc/SpigotConfig.java
|
||||||
+++ b/src/main/java/org/spigotmc/SpigotConfig.java
|
+++ b/src/main/java/org/spigotmc/SpigotConfig.java
|
||||||
@@ -18,6 +18,9 @@ import net.minecraft.server.AttributeRanged;
|
@@ -18,6 +18,9 @@ import net.minecraft.server.AttributeRanged;
|
@ -1,4 +1,4 @@
|
|||||||
From 191d3976ce28c03bad044b14dc96ab11d232e1eb Mon Sep 17 00:00:00 2001
|
From 967631ae5ea4e690ffc14ead5f365c4ab60c8c93 Mon Sep 17 00:00:00 2001
|
||||||
From: Thinkofdeath <thinkofdeath@spigotmc.org>
|
From: Thinkofdeath <thinkofdeath@spigotmc.org>
|
||||||
Date: Tue, 19 Aug 2014 11:04:21 +0100
|
Date: Tue, 19 Aug 2014 11:04:21 +0100
|
||||||
Subject: [PATCH] Skip invalid enchants in CraftMetaItem
|
Subject: [PATCH] Skip invalid enchants in CraftMetaItem
|
@ -0,0 +1,55 @@
|
|||||||
|
From c9626773c1837d038d971c4016e14f1feb7b9d8e Mon Sep 17 00:00:00 2001
|
||||||
|
From: Aikar <aikar@aikar.co>
|
||||||
|
Date: Wed, 20 Aug 2014 18:12:32 -0400
|
||||||
|
Subject: [PATCH] Limit TNT Detonations per tick
|
||||||
|
|
||||||
|
This gives a per-world control on how much TNT will be processed per-tick,
|
||||||
|
preventing a massive TNT detonation from lagging out the server.
|
||||||
|
|
||||||
|
diff --git a/src/main/java/net/minecraft/server/EntityTNTPrimed.java b/src/main/java/net/minecraft/server/EntityTNTPrimed.java
|
||||||
|
index 13cbc79..2214660 100644
|
||||||
|
--- a/src/main/java/net/minecraft/server/EntityTNTPrimed.java
|
||||||
|
+++ b/src/main/java/net/minecraft/server/EntityTNTPrimed.java
|
||||||
|
@@ -42,6 +42,7 @@ public class EntityTNTPrimed extends Entity {
|
||||||
|
}
|
||||||
|
|
||||||
|
public void h() {
|
||||||
|
+ if (world.spigotConfig.currentPrimedTnt++ > world.spigotConfig.maxTntTicksPerTick) { return; } // Spigot
|
||||||
|
this.lastX = this.locX;
|
||||||
|
this.lastY = this.locY;
|
||||||
|
this.lastZ = this.locZ;
|
||||||
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
|
index f9dc0fc..91f036b 100644
|
||||||
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
|
@@ -514,6 +514,7 @@ public class WorldServer extends World {
|
||||||
|
}
|
||||||
|
|
||||||
|
super.tickEntities();
|
||||||
|
+ spigotConfig.currentPrimedTnt = 0; // Spigot
|
||||||
|
}
|
||||||
|
|
||||||
|
public void i() {
|
||||||
|
diff --git a/src/main/java/org/spigotmc/SpigotWorldConfig.java b/src/main/java/org/spigotmc/SpigotWorldConfig.java
|
||||||
|
index 3500931..5e3dbf9 100644
|
||||||
|
--- a/src/main/java/org/spigotmc/SpigotWorldConfig.java
|
||||||
|
+++ b/src/main/java/org/spigotmc/SpigotWorldConfig.java
|
||||||
|
@@ -338,4 +338,15 @@ public class SpigotWorldConfig
|
||||||
|
combatExhaustion = (float) getDouble( "hunger.combat-exhaustion", 0.3 );
|
||||||
|
regenExhaustion = (float) getDouble( "hunger.regen-exhaustion", 3 );
|
||||||
|
}
|
||||||
|
+
|
||||||
|
+ public int currentPrimedTnt = 0;
|
||||||
|
+ public int maxTntTicksPerTick;
|
||||||
|
+ private void maxTntPerTick() {
|
||||||
|
+ if ( SpigotConfig.version < 7 )
|
||||||
|
+ {
|
||||||
|
+ set( "max-tnt-per-tick", 100 );
|
||||||
|
+ }
|
||||||
|
+ maxTntTicksPerTick = getInt( "max-tnt-per-tick", 100 );
|
||||||
|
+ log( "Max TNT Explosions: " + maxTntTicksPerTick );
|
||||||
|
+ }
|
||||||
|
}
|
||||||
|
--
|
||||||
|
1.9.1
|
||||||
|
|
@ -1,14 +1,14 @@
|
|||||||
From 8f949ae7d13ce3aefdd0f4cedcf3cecfd1966314 Mon Sep 17 00:00:00 2001
|
From e1365873f29fd564719f3edda9818253495dd854 Mon Sep 17 00:00:00 2001
|
||||||
From: Iceee <andrew@opticgaming.tv>
|
From: Iceee <andrew@opticgaming.tv>
|
||||||
Date: Thu, 12 Jun 2014 13:37:35 -0500
|
Date: Thu, 12 Jun 2014 13:37:35 -0500
|
||||||
Subject: [PATCH] Fix redstone lag issues
|
Subject: [PATCH] Fix redstone lag issues
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
diff --git a/src/main/java/net/minecraft/server/WorldServer.java b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
index d93eb8b..1dd9fa7 100644
|
index 91f036b..e98d282 100644
|
||||||
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
--- a/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
+++ b/src/main/java/net/minecraft/server/WorldServer.java
|
||||||
@@ -526,6 +526,7 @@ public class WorldServer extends World {
|
@@ -527,6 +527,7 @@ public class WorldServer extends World {
|
||||||
if (i != this.M.size()) {
|
if (i != this.M.size()) {
|
||||||
throw new IllegalStateException("TickNextTick list out of synch");
|
throw new IllegalStateException("TickNextTick list out of synch");
|
||||||
} else {
|
} else {
|
||||||
@ -16,7 +16,7 @@ index d93eb8b..1dd9fa7 100644
|
|||||||
if (i > 1000) {
|
if (i > 1000) {
|
||||||
// CraftBukkit start - If the server has too much to process over time, try to alleviate that
|
// CraftBukkit start - If the server has too much to process over time, try to alleviate that
|
||||||
if (i > 20 * 1000) {
|
if (i > 20 * 1000) {
|
||||||
@@ -534,7 +535,12 @@ public class WorldServer extends World {
|
@@ -535,7 +536,12 @@ public class WorldServer extends World {
|
||||||
i = 1000;
|
i = 1000;
|
||||||
}
|
}
|
||||||
// CraftBukkit end
|
// CraftBukkit end
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
From 2e6771696e929e2f7ed3005f221c2145fe356546 Mon Sep 17 00:00:00 2001
|
From 834a42d90501c4711a915d35b1a5df45212296dc Mon Sep 17 00:00:00 2001
|
||||||
From: Zach Brown <Zbob750@live.com>
|
From: Zach Brown <Zbob750@live.com>
|
||||||
Date: Tue, 5 Aug 2014 17:56:02 -0500
|
Date: Tue, 5 Aug 2014 17:56:02 -0500
|
||||||
Subject: [PATCH] Toggle for player interact limiter
|
Subject: [PATCH] Toggle for player interact limiter
|
||||||
|
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||||
index e8bfc41..7f7cc13 100644
|
index 188393c..0987b90 100644
|
||||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||||
@@ -587,7 +587,8 @@ public class PlayerConnection implements PacketPlayInListener {
|
@@ -581,7 +581,8 @@ public class PlayerConnection implements PacketPlayInListener {
|
||||||
|
|
||||||
public void a(PacketPlayInBlockPlace packetplayinblockplace) {
|
public void a(PacketPlayInBlockPlace packetplayinblockplace) {
|
||||||
boolean throttled = false;
|
boolean throttled = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user