Posted January 2, 201510 yr Hey guys, so I am trying to make a block players can walk through but I am having a few issues. 1) If inside the block, the player takes suffocation damage 2) When walking through a single block at feet level, no issues, but when trying to walk through at head level, either momentum is needed, or some sides don't seem work. Anything you could suggest, here is an example of of the blocks: public class secretDirt extends Block { public secretDirt(){ super(Material.grass); setBlockName("secretDirt"); setCreativeTab(JordTab.JordTab); RegisterHelper.registerBlock(this); } @Override public AxisAlignedBB getCollisionBoundingBoxFromPool(World world, int x, int y, int z) { return null; } @Override @SideOnly(Side.CLIENT) public void registerBlockIcons(IIconRegister iconRegister) { blockIcon = iconRegister.registerIcon("minecraft:dirt"); } } Why bother?
January 2, 201510 yr Try Material.plants instead. Or you can make your own material. The key part is the isSolid method. private static Material myMaterial = new Material(MapColor.grassColor) { @Override public boolean isSolid() { return false; } @Override public boolean blocksLight() { return true; } @Override public boolean blocksMovement() { return false; } }; GitHub|Recipe API Proposal
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.