Remove landmark's levitation. It's broken physics.
This commit is contained in:
parent
cf2e67c071
commit
69a09c9ac0
2 changed files with 6 additions and 28 deletions
|
@ -36,6 +36,11 @@ public class BlockMarker extends BlockContainer {
|
|||
setCreativeTab(CreativeTabBuildCraft.ITEMS.get());
|
||||
}
|
||||
|
||||
public static boolean canPlaceTorch(World world, int x, int y, int z, ForgeDirection side) {
|
||||
Block block = world.getBlock(x, y, z);
|
||||
return block != null && (block.renderAsNormalBlock() && block.isOpaqueCube() || block.isSideSolid(world, x, y, z, side));
|
||||
}
|
||||
|
||||
private AxisAlignedBB getBoundingBox(int meta) {
|
||||
double w = 0.15;
|
||||
double h = 0.65;
|
||||
|
@ -128,7 +133,7 @@ public class BlockMarker extends BlockContainer {
|
|||
@Override
|
||||
public boolean canPlaceBlockOnSide(World world, int x, int y, int z, int side) {
|
||||
ForgeDirection dir = ForgeDirection.getOrientation(side);
|
||||
return BuildersProxy.canPlaceTorch(world, x - dir.offsetX, y - dir.offsetY, z - dir.offsetZ);
|
||||
return canPlaceTorch(world, x - dir.offsetX, y - dir.offsetY, z - dir.offsetZ, dir);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -1,27 +0,0 @@
|
|||
/**
|
||||
* Copyright (c) 2011-2014, SpaceToad and the BuildCraft Team
|
||||
* http://www.mod-buildcraft.com
|
||||
*
|
||||
* BuildCraft is distributed under the terms of the Minecraft Mod Public
|
||||
* License 1.0, or MMPL. Please check the contents of the license located in
|
||||
* http://www.mod-buildcraft.com/MMPL-1.0.txt
|
||||
*/
|
||||
package buildcraft.builders;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public final class BuildersProxy {
|
||||
|
||||
/**
|
||||
* Forbid contruction of this class
|
||||
*/
|
||||
private BuildersProxy() {
|
||||
}
|
||||
|
||||
public static boolean canPlaceTorch(World world, int i, int j, int k) {
|
||||
Block block = world.getBlock(i, j, k);
|
||||
|
||||
return !(block == null || !block.renderAsNormalBlock());
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue