Skip to content

Commit

Permalink
Fix DoublePlant placement, closes #921
Browse files Browse the repository at this point in the history
  • Loading branch information
LexManos committed Jan 4, 2014
1 parent a1b68d9 commit 0da954c
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions patches/minecraft/net/minecraft/block/BlockDoublePlant.java.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
--- ../src-base/minecraft/net/minecraft/block/BlockDoublePlant.java
+++ ../src-work/minecraft/net/minecraft/block/BlockDoublePlant.java
@@ -81,6 +81,7 @@

public boolean func_149718_j(World p_149718_1_, int p_149718_2_, int p_149718_3_, int p_149718_4_)
{
+ if (p_149718_1_.func_147439_a(p_149718_2_, p_149718_3_, p_149718_4_) != this) return super.func_149718_j(p_149718_1_, p_149718_2_, p_149718_3_, p_149718_4_); //Forge: This function is called during world gen and placement, before this block is set, so if we are not 'here' then assume it's the pre-check.
int l = p_149718_1_.getBlockMetadata(p_149718_2_, p_149718_3_, p_149718_4_);
return func_149887_c(l) ? p_149718_1_.func_147439_a(p_149718_2_, p_149718_3_ - 1, p_149718_4_) == this : p_149718_1_.func_147439_a(p_149718_2_, p_149718_3_ + 1, p_149718_4_) == this && super.func_149718_j(p_149718_1_, p_149718_2_, p_149718_3_, p_149718_4_);
}

0 comments on commit 0da954c

Please sign in to comment.