package common.init;

import common.block.Block;

public abstract class FlammabilityRegistry {
	private static void setFlammable(Block blockIn, int encouragement, int flammability) {
		Blocks.fire.setFireInfo(blockIn, encouragement, flammability);
	}

	static void register() {
//	    setFlammable(Blocks.planks, 5, 20);
	    for(WoodType wood : WoodType.values()) {
    		setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_planks"), 5, 20);
    		setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_slab"), 5, 20);
		    setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_stairs"), 5, 20);
		    setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_fence"), 5, 20);
	    	setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_fence_gate"), 5, 20);
		    setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_log"), 5, 5);
		    setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_leaves"), 30, 60);
		    setFlammable(BlockRegistry.getRegisteredBlock(wood.getName() + "_sapling"), 15, 100);
	    }
	    setFlammable(Blocks.bookshelf, 30, 20);
	    setFlammable(Blocks.tnt, 15, 100);
	    setFlammable(Blocks.tallgrass, 60, 100);
	    setFlammable(Blocks.double_plant, 60, 100);
	    setFlammable(Blocks.flower, 60, 100);
	    setFlammable(Blocks.deadbush, 60, 100);
	    setFlammable(Blocks.dry_leaves, 60, 100);
	    setFlammable(Blocks.wool, 30, 60);
	    setFlammable(Blocks.vine, 15, 100);
	    setFlammable(Blocks.coal_block, 5, 5);
	    setFlammable(Blocks.hay_block, 60, 20);
	    setFlammable(Blocks.carpet, 60, 20);

//	    setFlammable(Blocks.double_wooden_slab, 5, 20);
//	    setFlammable(Blocks.wooden_slab, 5, 20);
//	    setFlammable(Blocks.oak_fence_gate, 5, 20);
//	    setFlammable(Blocks.spruce_fence_gate, 5, 20);
//	    setFlammable(Blocks.birch_fence_gate, 5, 20);
//	    setFlammable(Blocks.jungle_fence_gate, 5, 20);
//	    setFlammable(Blocks.dark_oak_fence_gate, 5, 20);
//	    setFlammable(Blocks.acacia_fence_gate, 5, 20);
//	    setFlammable(Blocks.oak_fence, 5, 20);
//	    setFlammable(Blocks.spruce_fence, 5, 20);
//	    setFlammable(Blocks.birch_fence, 5, 20);
//	    setFlammable(Blocks.jungle_fence, 5, 20);
//	    setFlammable(Blocks.dark_oak_fence, 5, 20);
//	    setFlammable(Blocks.acacia_fence, 5, 20);
//	    setFlammable(Blocks.oak_stairs, 5, 20);
//	    setFlammable(Blocks.birch_stairs, 5, 20);
//	    setFlammable(Blocks.spruce_stairs, 5, 20);
//	    setFlammable(Blocks.jungle_stairs, 5, 20);
//	    setFlammable(Blocks.log, 5, 5);
//	    setFlammable(Blocks.log2, 5, 5);
//	    for(BlockLeaves leaves : BlockLeaves.LEAVES) {
//		    setFlammable(leaves, 30, 60);
////		    setFlammable(Blocks.leaves2, 30, 60);
//	    }
//	    setFlammable(Blocks.red_flower, 60, 100);
//	    setFlammable(Blocks.cherry_leaves, 30, 60);
//	    setFlammable(Blocks.maple_leaves, 30, 60);
//	    setFlammable(Blocks.cherry_fence_gate, 5, 20);
//	    setFlammable(Blocks.maple_fence_gate, 5, 20);
//	    setFlammable(Blocks.cherry_fence, 5, 20);
//	    setFlammable(Blocks.maple_fence, 5, 20);
//	    setFlammable(Blocks.cherry_stairs, 5, 20);
//	    setFlammable(Blocks.maple_stairs, 5, 20);
//	    setFlammable(Blocks.wooden_vslab, 5, 20);
//	    setFlammable(Blocks.wooden_vslab2, 5, 20);
//	    for(BlockSlab slab : BlockSlab.SLABS) {
//	    	if(slab.getMaterial() == Material.wood)
//	    		setFlammable(slab, 5, 20);
//	    }
	}
}
