2015-11-07 16:51:41 +00:00
package WayofTime.bloodmagic.registry ;
2015-12-26 15:32:53 +00:00
import net.minecraft.init.Blocks ;
import net.minecraft.init.Items ;
import net.minecraft.item.ItemStack ;
import net.minecraft.util.ResourceLocation ;
2015-12-29 22:47:12 +00:00
import net.minecraftforge.fml.common.registry.GameRegistry ;
2015-12-26 19:40:51 +00:00
import WayofTime.bloodmagic.alchemyArray.CraftingArrayEffectBinding ;
2015-11-07 16:51:41 +00:00
import WayofTime.bloodmagic.api.altar.EnumAltarTier ;
2015-12-29 22:47:12 +00:00
import WayofTime.bloodmagic.api.compress.CompressionRegistry ;
2015-12-29 23:30:36 +00:00
import WayofTime.bloodmagic.api.recipe.ShapedBloodOrbRecipe ;
import WayofTime.bloodmagic.api.recipe.ShapelessBloodOrbRecipe ;
2015-12-24 01:19:06 +00:00
import WayofTime.bloodmagic.api.registry.AlchemyArrayRecipeRegistry ;
2015-11-07 16:51:41 +00:00
import WayofTime.bloodmagic.api.registry.AltarRecipeRegistry ;
2015-11-29 02:25:46 +00:00
import WayofTime.bloodmagic.api.registry.OrbRegistry ;
2015-12-02 08:55:32 +00:00
import WayofTime.bloodmagic.api.ritual.EnumRuneType ;
2015-12-26 15:32:53 +00:00
import WayofTime.bloodmagic.client.render.alchemyArray.BindingAlchemyCircleRenderer ;
2015-12-29 22:47:12 +00:00
import WayofTime.bloodmagic.compress.AdvancedCompressionHandler ;
import WayofTime.bloodmagic.compress.BaseCompressionHandler ;
import WayofTime.bloodmagic.compress.StorageBlockCraftingManager ;
import WayofTime.bloodmagic.item.ItemComponent ;
2015-11-07 16:51:41 +00:00
public class ModRecipes {
2015-12-03 03:27:28 +00:00
2015-11-07 16:51:41 +00:00
public static void init ( ) {
2015-12-29 22:47:12 +00:00
addCraftingRecipes ( ) ;
2015-11-07 16:51:41 +00:00
addAltarRecipes ( ) ;
2015-12-24 01:19:06 +00:00
addAlchemyArrayRecipes ( ) ;
2015-11-07 16:51:41 +00:00
}
2015-12-29 22:47:12 +00:00
public static void addCraftingRecipes ( ) {
2015-12-29 23:30:36 +00:00
GameRegistry . addRecipe ( new ShapedBloodOrbRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_BINDING ) , " xox " , " oSo " , " xox " , 'S' , OrbRegistry . getOrbStack ( ModItems . orbMagician ) , 'o' , new ItemStack ( Items . redstone ) , 'x' , new ItemStack ( Items . glowstone_dust ) ) ) ;
//Added for testing
GameRegistry . addRecipe ( new ShapelessBloodOrbRecipe ( new ItemStack ( Items . gold_ingot ) , new ItemStack ( ModItems . slate , 1 , 1 ) , OrbRegistry . getOrbStack ( ModItems . orbApprentice ) ) ) ;
GameRegistry . addRecipe ( new ShapedBloodOrbRecipe ( new ItemStack ( Items . diamond ) , " " , " s " , " o " , 's' , new ItemStack ( ModItems . slate ) , 'o' , OrbRegistry . getOrbStack ( ModItems . orbWeak ) ) ) ;
2015-12-29 22:47:12 +00:00
}
2015-11-07 16:51:41 +00:00
public static void addAltarRecipes ( ) {
2015-12-02 08:55:32 +00:00
// ONE
2015-12-23 02:03:00 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( OrbRegistry . getOrbStack ( ModItems . orbWeak ) , OrbRegistry . getOrbStack ( ModItems . orbWeak ) , EnumAltarTier . ONE , 5000 , 2 , 1 , true ) ) ;
2015-12-03 03:27:28 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Items . diamond ) , OrbRegistry . getOrbStack ( ModItems . orbWeak ) , EnumAltarTier . ONE , 2000 , 2 , 1 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Blocks . stone ) , new ItemStack ( ModItems . slate ) , EnumAltarTier . ONE , 1000 , 5 , 5 , false ) ) ;
2015-12-02 08:55:32 +00:00
// TWO
2015-12-03 03:27:28 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Items . emerald ) , OrbRegistry . getOrbStack ( ModItems . orbApprentice ) , EnumAltarTier . TWO , 5000 , 2 , 1 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( ModItems . slate ) , new ItemStack ( ModItems . slate , 1 , 1 ) , EnumAltarTier . TWO , 2000 , 5 , 5 , false ) ) ;
2015-12-02 08:55:32 +00:00
// THREE
2015-12-03 03:27:28 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Blocks . gold_block ) , OrbRegistry . getOrbStack ( ModItems . orbMagician ) , EnumAltarTier . THREE , 25000 , 2 , 1 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( ModItems . slate , 1 , 1 ) , new ItemStack ( ModItems . slate , 1 , 2 ) , EnumAltarTier . THREE , 5000 , 15 , 10 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Blocks . obsidian ) , EnumRuneType . EARTH . getScribeStack ( ) , EnumAltarTier . THREE , 1000 , 5 , 5 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Blocks . lapis_block ) , EnumRuneType . WATER . getScribeStack ( ) , EnumAltarTier . THREE , 1000 , 5 , 5 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Items . magma_cream ) , EnumRuneType . FIRE . getScribeStack ( ) , EnumAltarTier . THREE , 1000 , 5 , 5 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Items . ghast_tear ) , EnumRuneType . AIR . getScribeStack ( ) , EnumAltarTier . THREE , 1000 , 5 , 5 , false ) ) ;
2015-12-02 08:55:32 +00:00
// FOUR
2015-12-03 03:27:28 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( ModItems . slate , 1 , 2 ) , new ItemStack ( ModItems . slate , 1 , 3 ) , EnumAltarTier . FOUR , 15000 , 20 , 20 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Blocks . coal_block ) , EnumRuneType . DUSK . getScribeStack ( ) , EnumAltarTier . FOUR , 2000 , 20 , 10 , false ) ) ;
2015-12-02 08:55:32 +00:00
// FIVE
2015-12-03 03:27:28 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( ModItems . slate , 1 , 3 ) , new ItemStack ( ModItems . slate , 1 , 4 ) , EnumAltarTier . FIVE , 30000 , 40 , 100 , false ) ) ;
2015-12-02 08:55:32 +00:00
// SIX
2015-12-03 03:27:28 +00:00
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( ModBlocks . crystal ) , OrbRegistry . getOrbStack ( ModItems . orbTranscendent ) , EnumAltarTier . SIX , 200000 , 100 , 200 , false ) ) ;
AltarRecipeRegistry . registerRecipe ( new AltarRecipeRegistry . AltarRecipe ( new ItemStack ( Blocks . glowstone ) , EnumRuneType . DAWN . getScribeStack ( ) , EnumAltarTier . SIX , 200000 , 100 , 200 , false ) ) ;
2015-11-07 16:51:41 +00:00
}
2015-12-24 01:19:06 +00:00
public static void addAlchemyArrayRecipes ( ) {
2015-12-29 22:47:12 +00:00
AlchemyArrayRecipeRegistry . registerRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_BINDING ) , new ItemStack ( Items . diamond_sword ) , new CraftingArrayEffectBinding ( new ItemStack ( ModItems . boundSword ) ) , new BindingAlchemyCircleRenderer ( ) ) ;
AlchemyArrayRecipeRegistry . registerRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_BINDING ) , new ItemStack ( Items . diamond_axe ) , new CraftingArrayEffectBinding ( new ItemStack ( ModItems . boundAxe ) ) ) ;
AlchemyArrayRecipeRegistry . registerRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_BINDING ) , new ItemStack ( Items . diamond_pickaxe ) , new CraftingArrayEffectBinding ( new ItemStack ( ModItems . boundPickaxe ) ) ) ;
AlchemyArrayRecipeRegistry . registerRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_BINDING ) , new ItemStack ( Items . diamond_shovel ) , new CraftingArrayEffectBinding ( new ItemStack ( ModItems . boundShovel ) ) ) ;
2015-12-28 21:50:32 +00:00
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_WATER ) , new ItemStack ( ModItems . slate ) , new ItemStack ( ModItems . sigilWater ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/WaterSigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_LAVA ) , new ItemStack ( ModItems . slate ) , new ItemStack ( ModItems . sigilLava ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/LavaSigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_AIR ) , new ItemStack ( ModItems . slate , 1 , 1 ) , new ItemStack ( ModItems . sigilAir ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/AirSigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_FASTMINER ) , new ItemStack ( ModItems . slate , 1 , 1 ) , new ItemStack ( ModItems . sigilFastMiner ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/FastMinerSigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_VOID ) , new ItemStack ( ModItems . slate , 1 , 1 ) , new ItemStack ( ModItems . sigilVoid ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/VoidSigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_GROWTH ) , new ItemStack ( ModItems . slate , 1 , 1 ) , new ItemStack ( ModItems . sigilGreenGrove ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/GrowthSigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_AFFINITY ) , new ItemStack ( ModItems . slate , 1 , 2 ) , new ItemStack ( ModItems . sigilElementalAffinity ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/ElementalAffinitySigil.png " ) ) ;
AlchemyArrayRecipeRegistry . registerCraftingRecipe ( ItemComponent . getStack ( ItemComponent . REAGENT_SIGHT ) , new ItemStack ( ModItems . slate , 1 , 1 ) , new ItemStack ( ModItems . sigilSeer ) , new ResourceLocation ( " bloodmagic " , " textures/models/AlchemyArrays/SightSigil.png " ) ) ;
2015-12-24 01:19:06 +00:00
}
2015-12-29 00:09:51 +00:00
public static void addCompressionHandlers ( ) {
StorageBlockCraftingManager . getInstance ( ) . addStorageBlockRecipes ( ) ;
CompressionRegistry . registerHandler ( new BaseCompressionHandler ( new ItemStack ( Items . glowstone_dust , 4 , 0 ) , new ItemStack ( Blocks . glowstone ) , 64 ) ) ;
CompressionRegistry . registerHandler ( new BaseCompressionHandler ( new ItemStack ( Items . snowball , 4 , 0 ) , new ItemStack ( Blocks . snow ) , 8 ) ) ;
CompressionRegistry . registerHandler ( new AdvancedCompressionHandler ( ) ) ;
CompressionRegistry . registerItemThreshold ( new ItemStack ( Blocks . cobblestone ) , 64 ) ;
}
2015-11-07 16:51:41 +00:00
}