Loosen TileEntity's default hasCapability implementation. Modders should specifically opt in.
This commit is contained in:
parent
7a0a801740
commit
b71b963301
1 changed files with 1 additions and 3 deletions
|
@ -65,7 +65,7 @@
|
||||||
public double func_145835_a(double p_145835_1_, double p_145835_3_, double p_145835_5_)
|
public double func_145835_a(double p_145835_1_, double p_145835_3_, double p_145835_5_)
|
||||||
{
|
{
|
||||||
double d0 = (double)this.field_174879_c.func_177958_n() + 0.5D - p_145835_1_;
|
double d0 = (double)this.field_174879_c.func_177958_n() + 0.5D - p_145835_1_;
|
||||||
@@ -279,4 +293,185 @@
|
@@ -279,4 +293,183 @@
|
||||||
func_145826_a(TileEntityFlowerPot.class, "FlowerPot");
|
func_145826_a(TileEntityFlowerPot.class, "FlowerPot");
|
||||||
func_145826_a(TileEntityBanner.class, "Banner");
|
func_145826_a(TileEntityBanner.class, "Banner");
|
||||||
}
|
}
|
||||||
|
@ -229,8 +229,6 @@
|
||||||
+
|
+
|
||||||
+ public boolean hasCapability(net.minecraftforge.common.capabilities.Capability<?> capability, net.minecraft.util.EnumFacing facing)
|
+ public boolean hasCapability(net.minecraftforge.common.capabilities.Capability<?> capability, net.minecraft.util.EnumFacing facing)
|
||||||
+ {
|
+ {
|
||||||
+ if (getCapability(capability, facing) != null)
|
|
||||||
+ return true;
|
|
||||||
+ return capabilities == null ? false : capabilities.hasCapability(capability, facing);
|
+ return capabilities == null ? false : capabilities.hasCapability(capability, facing);
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
||||||
|
|
Loading…
Reference in a new issue