mirror of
https://github.com/MinecraftForge/MinecraftForge.git
synced 2026-11-20 20:22:28 +00:00
Fix mobs spawning on inverted slabs/stairs.
This commit is contained in:
1 parent
081ec4b70a
commit
46440588fe
2 files changed
+4
-17
No files matched your search
@@ -33,6 +33,7 @@ public class MinecraftForge
|
||||
public static final EventBus EVENT_BUS = new EventBus();
|
||||
public static final EventBus TERRAIN_GEN_BUS = new EventBus();
|
||||
public static final EventBus ORE_GEN_BUS = new EventBus();
|
||||
@Deprecated //Vanilla feature now
|
||||
public static boolean SPAWNER_ALLOW_ON_INVERTED = false;
|
||||
private static final ForgeInternalHandler INTERNAL_HANDLER = new ForgeInternalHandler();
|
||||
|
||||
|
||||
@@ -141,7 +141,7 @@
|
||||
{
|
||||
ItemStack var8 = this.createStackedBlock(par6);
|
||||
|
||||
@@ -1356,4 +1372,849 @@
|
||||
@@ -1356,4 +1372,835 @@
|
||||
canBlockGrass[0] = true;
|
||||
StatList.initBreakableStats();
|
||||
}
|
||||
@@ -511,25 +511,11 @@
|
||||
+ int meta = world.getBlockMetadata(x, y, z);
|
||||
+ if (this instanceof BlockStep)
|
||||
+ {
|
||||
+ if (MinecraftForge.SPAWNER_ALLOW_ON_INVERTED)
|
||||
+ {
|
||||
+ return (((meta & 8) == 8) || isOpaqueCube());
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ return isNormalCube(this.blockID);
|
||||
+ }
|
||||
+ return (((meta & 8) == 8) || isOpaqueCube());
|
||||
+ }
|
||||
+ else if (this instanceof BlockStairs)
|
||||
+ {
|
||||
+ if (MinecraftForge.SPAWNER_ALLOW_ON_INVERTED)
|
||||
+ {
|
||||
+ return ((meta & 4) != 0);
|
||||
+ }
|
||||
+ else
|
||||
+ {
|
||||
+ return isNormalCube(this.blockID);
|
||||
+ }
|
||||
+ return ((meta & 4) != 0);
|
||||
+ }
|
||||
+ return isBlockSolidOnSide(world, x, y, z, UP);
|
||||
+ }
|
||||
|
||||
Reference in new issue
Block a user