Moved client side Block.onBlockDestroyed to after Item.onBlockDestroyed to match server order.

This commit is contained in:
Lex Manos 2015-11-17 04:47:43 -08:00
parent a3a16d6593
commit 904a30123d

View file

@ -13,16 +13,35 @@
if (this.field_78779_k.func_77145_d() && this.field_78776_a.field_71439_g.func_70694_bm() != null && this.field_78776_a.field_71439_g.func_70694_bm().func_77973_b() instanceof ItemSword)
{
return false;
@@ -130,7 +136,7 @@
@@ -130,13 +136,7 @@
else
{
worldclient.func_175718_b(2001, p_178888_1_, Block.func_176210_f(iblockstate));
- boolean flag = worldclient.func_175698_g(p_178888_1_);
+ boolean flag = block1.removedByPlayer(worldclient, p_178888_1_, field_78776_a.field_71439_g, false);
if (flag)
{
@@ -360,11 +366,19 @@
- if (flag)
- {
- block1.func_176206_d(worldclient, p_178888_1_, iblockstate);
- }
-
this.field_178895_c = new BlockPos(this.field_178895_c.func_177958_n(), -1, this.field_178895_c.func_177952_p());
if (!this.field_78779_k.func_77145_d())
@@ -154,6 +154,13 @@
}
}
+ boolean flag = block1.removedByPlayer(worldclient, p_178888_1_, field_78776_a.field_71439_g, false);
+
+ if (flag)
+ {
+ block1.func_176206_d(worldclient, p_178888_1_, iblockstate);
+ }
+
return flag;
}
}
@@ -360,11 +367,19 @@
{
if (this.field_78779_k != WorldSettings.GameType.SPECTATOR)
{
@ -44,7 +63,7 @@
}
if (!flag && p_178890_3_ != null && p_178890_3_.func_77973_b() instanceof ItemBlock)
@@ -397,7 +411,9 @@
@@ -397,7 +412,9 @@
}
else
{
@ -55,7 +74,7 @@
}
}
else
@@ -428,9 +444,10 @@
@@ -428,9 +445,10 @@
{
p_78769_1_.field_71071_by.field_70462_a[p_78769_1_.field_71071_by.field_70461_c] = itemstack1;