Posted April 19, 201411 yr How do you get a block update from one of the blocks you have made. What is the method called: Example public class blockStuff extends Block { public void BlockUpdateMethod() { //My Code } } Author of the unreleased mod Factory Craft I'm usually known as MnomisC IGN MnomisC
April 19, 201411 yr Add this in your class constructor. .setTickRandomly(true); Then add this - runs per tick. public void updateTick(World par1World, int par2, int par3, int par4, Random par5Random)
April 20, 201411 yr You could use world.scheduleBlockUpdate(), use the onNeighborChanged if you want to update the block while the neighbor blocks are updated (added, removed). If you want a constant tick, I suggest using a tileentity and inside the TileEntity class, add the updateEntity() method. That updates once every tick and is used to make furnaces and other machine update their progress bars and cooking. My mod for futher awesomeness: http://www.minecraftforum.net/topic/1714396-the-decopack-collection-v010-wip-made-a-signature-new-snapshot-1-screenshots-are-up-small-snapshot-1-is-out-for-147/#entry21250399
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.