Upstream merge

This commit is contained in:
Thinkofdeath 2014-06-02 15:38:03 +01:00
parent b572a59936
commit 27cb8a7e6d
8 changed files with 17 additions and 87 deletions

2
Bukkit

@ -1 +1 @@
Subproject commit 91410848816e1c9824207d0f9a93e379bb9f02e4 Subproject commit fc7109d4d1a867162961f07b711e1d6157ecd3e2

View File

@ -1,11 +1,11 @@
From 08a077bcb805a326ab9197a5814d2a9a54762c90 Mon Sep 17 00:00:00 2001 From 34f763cc0aea978efc5e76c9c3df06df012bafa1 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, 2 Jun 2013 10:36:24 +1000 Date: Sun, 2 Jun 2013 10:36:24 +1000
Subject: [PATCH] POM Changes Subject: [PATCH] POM Changes
diff --git a/pom.xml b/pom.xml diff --git a/pom.xml b/pom.xml
index 23b7cc3..b394a33 100644 index dcf7ed3..f7d100a 100644
--- a/pom.xml --- a/pom.xml
+++ b/pom.xml +++ b/pom.xml
@@ -1,42 +1,21 @@ @@ -1,42 +1,21 @@
@ -15,7 +15,7 @@ index 23b7cc3..b394a33 100644
- <artifactId>bukkit</artifactId> - <artifactId>bukkit</artifactId>
+ <groupId>org.spigotmc</groupId> + <groupId>org.spigotmc</groupId>
+ <artifactId>spigot-api</artifactId> + <artifactId>spigot-api</artifactId>
<version>1.7.9-R0.2-SNAPSHOT</version> <version>1.7.9-R0.3-SNAPSHOT</version>
- <name>Bukkit</name> - <name>Bukkit</name>
- <url>http://www.bukkit.org</url> - <url>http://www.bukkit.org</url>
+ <name>Spigot-API</name> + <name>Spigot-API</name>

@ -1 +1 @@
Subproject commit 4d832c39f320f7745a210a9d9a0accc665bd49dd Subproject commit a6e0bfd1982470a64afae7bd2d265b3302f053ac

View File

@ -1,11 +1,11 @@
From a7344d5de1c9952cf0e2c9e27a3a5f3283289a53 Mon Sep 17 00:00:00 2001 From ae912a83567434a436fad96553d8f1ff5114db6a Mon Sep 17 00:00:00 2001
From: md_5 <md_5@live.com.au> From: md_5 <md_5@live.com.au>
Date: Tue, 2 Jul 2013 13:07:39 +1000 Date: Tue, 2 Jul 2013 13:07:39 +1000
Subject: [PATCH] POM Changes Subject: [PATCH] POM Changes
diff --git a/pom.xml b/pom.xml diff --git a/pom.xml b/pom.xml
index b4b7ae0..006d26b 100644 index b2e2002..c1073e5 100644
--- a/pom.xml --- a/pom.xml
+++ b/pom.xml +++ b/pom.xml
@@ -1,12 +1,12 @@ @@ -1,12 +1,12 @@
@ -17,7 +17,7 @@ index b4b7ae0..006d26b 100644
+ <groupId>org.spigotmc</groupId> + <groupId>org.spigotmc</groupId>
+ <artifactId>spigot</artifactId> + <artifactId>spigot</artifactId>
<packaging>jar</packaging> <packaging>jar</packaging>
<version>1.7.9-R0.2-SNAPSHOT</version> <version>1.7.9-R0.3-SNAPSHOT</version>
- <name>CraftBukkit</name> - <name>CraftBukkit</name>
- <url>http://www.bukkit.org</url> - <url>http://www.bukkit.org</url>
+ <name>Spigot</name> + <name>Spigot</name>

View File

@ -1,14 +1,14 @@
From 9bc96791db6467b0721810dba820374aa6c46065 Mon Sep 17 00:00:00 2001 From 6d1e63d8c59ecc36efdbd54880bb0ca1af9bda2c Mon Sep 17 00:00:00 2001
From: md_5 <md_5@live.com.au> From: md_5 <md_5@live.com.au>
Date: Mon, 4 Mar 2013 18:45:52 +1100 Date: Mon, 4 Mar 2013 18:45:52 +1100
Subject: [PATCH] PlayerItemDamageEvent Subject: [PATCH] PlayerItemDamageEvent
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
index 7342848..5138eec 100644 index f9aaf4a..f32f40d 100644
--- a/src/main/java/net/minecraft/server/ItemStack.java --- a/src/main/java/net/minecraft/server/ItemStack.java
+++ b/src/main/java/net/minecraft/server/ItemStack.java +++ b/src/main/java/net/minecraft/server/ItemStack.java
@@ -270,7 +270,13 @@ public final class ItemStack { @@ -279,7 +279,13 @@ public final class ItemStack {
return this.item.getMaxDurability(); return this.item.getMaxDurability();
} }
@ -22,7 +22,7 @@ index 7342848..5138eec 100644
if (!this.g()) { if (!this.g()) {
return false; return false;
} else { } else {
@@ -285,7 +291,16 @@ public final class ItemStack { @@ -294,7 +300,16 @@ public final class ItemStack {
} }
i -= k; i -= k;
@ -40,7 +40,7 @@ index 7342848..5138eec 100644
return false; return false;
} }
} }
@@ -298,7 +313,7 @@ public final class ItemStack { @@ -307,7 +322,7 @@ public final class ItemStack {
public void damage(int i, EntityLiving entityliving) { public void damage(int i, EntityLiving entityliving) {
if (!(entityliving instanceof EntityHuman) || !((EntityHuman) entityliving).abilities.canInstantlyBuild) { if (!(entityliving instanceof EntityHuman) || !((EntityHuman) entityliving).abilities.canInstantlyBuild) {
if (this.g()) { if (this.g()) {

View File

@ -1,14 +1,14 @@
From de4027c312d39d2ab4824c5de2c0f43a79ce091d Mon Sep 17 00:00:00 2001 From 5048ab570df46e50d433d0de6d88c1cc29977ed6 Mon Sep 17 00:00:00 2001
From: md_5 <git@md-5.net> From: md_5 <git@md-5.net>
Date: Fri, 10 Jan 2014 15:15:50 +1100 Date: Fri, 10 Jan 2014 15:15:50 +1100
Subject: [PATCH] Fix ItemStack Unbreakable Code Subject: [PATCH] Fix ItemStack Unbreakable Code
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
index 5138eec..3a18002 100644 index f32f40d..d1bbb05 100644
--- a/src/main/java/net/minecraft/server/ItemStack.java --- a/src/main/java/net/minecraft/server/ItemStack.java
+++ b/src/main/java/net/minecraft/server/ItemStack.java +++ b/src/main/java/net/minecraft/server/ItemStack.java
@@ -224,7 +224,13 @@ public final class ItemStack { @@ -228,7 +228,13 @@ public final class ItemStack {
} }
public boolean g() { public boolean g() {

View File

@ -1,4 +1,4 @@
From 2a693183d7eef1e420940b89477c31b4589e6dea Mon Sep 17 00:00:00 2001 From d2464ff0ee510c4d7eae1439b190f8438583a285 Mon Sep 17 00:00:00 2001
From: Thinkofdeath <thethinkofdeath@gmail.com> From: Thinkofdeath <thethinkofdeath@gmail.com>
Date: Wed, 15 Jan 2014 21:52:47 +0000 Date: Wed, 15 Jan 2014 21:52:47 +0000
Subject: [PATCH] Block data values that crash the client Subject: [PATCH] Block data values that crash the client
@ -56,45 +56,6 @@ index 874a089..088ee42 100644
TileEntity tileentity = this.e(i, j, k); TileEntity tileentity = this.e(i, j, k);
if (tileentity != null) { if (tileentity != null) {
diff --git a/src/main/java/net/minecraft/server/ItemStack.java b/src/main/java/net/minecraft/server/ItemStack.java
index 3a18002..2ab3b9b 100644
--- a/src/main/java/net/minecraft/server/ItemStack.java
+++ b/src/main/java/net/minecraft/server/ItemStack.java
@@ -204,10 +204,7 @@ public final class ItemStack {
public void c(NBTTagCompound nbttagcompound) {
this.item = Item.d(nbttagcompound.getShort("id"));
this.count = nbttagcompound.getByte("Count");
- this.damage = nbttagcompound.getShort("Damage");
- if (this.damage < 0) {
- this.damage = 0;
- }
+ setData( nbttagcompound.getShort("Damage") ); // Spigot
if (nbttagcompound.hasKeyOfType("tag", 10)) {
// CraftBukkit - make defensive copy as this data may be coming from the save thread
@@ -258,11 +255,21 @@ public final class ItemStack {
}
// Is this a block?
- if (CraftMagicNumbers.getBlock(CraftMagicNumbers.getId(this.getItem())) != Blocks.AIR) {
+ // Spigot start - filter
+ Block block = CraftMagicNumbers.getBlock(CraftMagicNumbers.getId(this.getItem()));
+ if (block != Blocks.AIR) {
// If vanilla doesn't use data on it don't allow any
if (!(this.usesData() || this.getItem().usesDurability())) {
i = 0;
}
+ if ( block == Blocks.DOUBLE_PLANT )
+ {
+ if ( i >= 6 && i != 8 )
+ {
+ i = 0;
+ }
+ }
+ // Spigot end
}
// CraftBukkit end
-- --
1.9.1 1.9.1

View File

@ -1,31 +0,0 @@
From d69b3ad28f5941dfdfa8a31213ffe41c0cd7bacd Mon Sep 17 00:00:00 2001
From: prplz <tmtgr@hotmail.com>
Date: Tue, 27 May 2014 17:39:41 +1000
Subject: [PATCH] Fix Max Stack Size Tracking
diff --git a/src/main/java/net/minecraft/server/Container.java b/src/main/java/net/minecraft/server/Container.java
index 7358645..12e48d4 100644
--- a/src/main/java/net/minecraft/server/Container.java
+++ b/src/main/java/net/minecraft/server/Container.java
@@ -504,7 +504,7 @@ public abstract class Container {
itemstack.count -= maxStack - itemstack1.count;
itemstack1.count = maxStack;
slot.f();
- flag1 = itemstack.count == 0; // Don't give a success return if we have leftovers
+ flag1 = true; // Don't give a success return if we have leftovers
}
// CraftBukkit end
}
@@ -532,7 +532,7 @@ public abstract class Container {
slot.f();
// CraftBukkit start - Don't assume entire stack went in
itemstack.count -= slot.getItem().count;
- flag1 = itemstack.count == 0;
+ flag1 = true;
// CraftBukkit end
break;
}
--
1.9.1