Java Code Examples for net.minecraft.init.Blocks#UNPOWERED_REPEATER

The following examples show how to use net.minecraft.init.Blocks#UNPOWERED_REPEATER . These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may want to check out the right sidebar which shows the related API usage.
Example 1
public static void generate(IWorldEditor editor, Random rand, Cardinal dir, int delay, boolean powered, Coord pos){
	
	MetaBlock repeater = powered ? new MetaBlock(Blocks.POWERED_REPEATER) : new MetaBlock(Blocks.UNPOWERED_REPEATER);
	repeater.withProperty(BlockRedstoneRepeater.FACING, Cardinal.facing(dir));
	if (delay > 0 && delay <= 4) repeater.withProperty(BlockRedstoneRepeater.DELAY, delay);
	repeater.set(editor, pos);
}