public override void AddRecipes()
        {
            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(ItemID.Keybrand);
            foreach (Recipe recipe in finder.SearchRecipes())
            {
                RecipeEditor editor = new RecipeEditor(recipe);
                editor.DeleteIngredient(ItemID.Keybrand);
                editor.AddIngredient(ModContent.ItemType <Items.Weapons.Keybrand>());
            }
            finder = new RecipeFinder();
            finder.SetResult(ItemID.Keybrand);
            foreach (Recipe recipe in finder.SearchRecipes())
            {
                RecipeEditor editor = new RecipeEditor(recipe);
                editor.SetResult(ModContent.ItemType <Items.Materials.RustedKeybrand>());
            }
            ModRecipe r = new ModRecipe(this);

            r.AddIngredient(ItemID.HellstoneBar, 15);
            r.AddTile(TileID.Anvils);
            r.SetResult(ItemID.Flamarang);
            r.AddRecipe();
        }
Exemplo n.º 2
0
        public static void RecipeEditing(Mod mod)
        {
            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(ItemID.MechanicalGlove, 1);
            finder.AddIngredient(ItemID.MagmaStone, 1);
            finder.SetResult(ItemID.FireGauntlet, 1);
            //.AddTile(TileID.Workshop);

            foreach (Recipe recipe in finder.SearchRecipes())

            {
                RecipeEditor editor = new RecipeEditor(recipe);
                editor.AddIngredient(2766, 15);
            }

            RecipeFinder finder2 = new RecipeFinder();

            finder2.AddIngredient(2431, 14);
            finder2.AddTile(TileID.Anvils);
            finder2.SetResult(ItemID.HornetStaff);
            Recipe exactRecipe2 = finder2.FindExactRecipe();

            bool isFound2 = exactRecipe2 != null;

            if (isFound2)
            {
                RecipeEditor editor2 = new RecipeEditor(exactRecipe2);
                editor2.DeleteIngredient(2431);
                editor2.AddIngredient(1134, 1);
                editor2.AddIngredient(1124, 20);
                editor2.AddIngredient(209, 15);
                editor2.SetResult(ItemID.HornetStaff);
            }
        }
Exemplo n.º 3
0
        public static void ModifyRecipes()
        {
            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(ItemID.RedBrick, 5);
            finder.AddTile(TileID.Anvils);
            finder.SetResult(ModContent.ItemType <ThrowingBrick>(), 15);

            if (finder.TryFindExactRecipe(out RecipeEditor throwingBrick))
            {
                throwingBrick.DeleteTile(TileID.Anvils);
                throwingBrick.AddTile(TileID.WorkBenches);
            }

            finder = new RecipeFinder();
            finder.AddIngredient(ModContent.ItemType <Lumenite>(), 6);
            finder.AddIngredient(ModContent.ItemType <RuinousSoul>(), 4);
            finder.AddIngredient(ModContent.ItemType <ExodiumClusterOre>(), 12);
            finder.AddIngredient(ItemID.SniperScope);
            finder.AddTile(TileID.LunarCraftingStation);
            finder.SetResult(ModContent.ItemType <HalleysInferno>());

            if (finder.TryFindExactRecipe(out RecipeEditor halleysInferno))
            {
                halleysInferno.DeleteIngredient(ItemID.SniperScope);
                halleysInferno.AddIngredient(ItemID.RifleScope);
            }
        }
Exemplo n.º 4
0
 private static void RemoveNightsEdgeRecipe()
 {
     RecipeFinder finder = new RecipeFinder();
     {
         finder.AddIngredient(ItemID.BloodButcherer, 1);
         finder.AddIngredient(ItemID.FieryGreatsword, 1);
         finder.AddIngredient(ItemID.BladeofGrass, 1);
         finder.AddIngredient(ItemID.Muramasa, 1);
         finder.AddTile(TileID.DemonAltar);
         finder.SetResult(ItemID.NightsEdge, 1);
         Recipe recipe2 = finder.FindExactRecipe();
         if (recipe2 != null)
         {
             RecipeEditor editor = new RecipeEditor(recipe2);
             editor.DeleteRecipe();
         }
     }
 }
Exemplo n.º 5
0
        public static void EditVanillaRecipes()
        {
            if (Config.MolotovCraft > 0)
            {
                var recipe = new ModRecipe(VanillaTweaks.Instance);
                recipe.AddIngredient(ItemID.Ale, 5);
                recipe.AddIngredient(ItemID.Torch, 1);
                recipe.AddIngredient(ItemID.Silk, 1);
                recipe.AddIngredient(ItemID.Gel, Config.MolotovCraft);
                recipe.SetResult(ItemID.MolotovCocktail, 5);
                recipe.AddRecipe();
            }
            if (Config.BoneBlockFix)
            {
                var finder = new RecipeFinder();
                finder.AddIngredient(ItemID.BoneBlockWall, 4);
                finder.AddTile(TileID.BoneWelder);
                finder.SetResult(ItemID.BoneBlock, 1);
                var recipe = finder.FindExactRecipe();
                if (recipe != null)
                {
                    recipe.createItem.SetDefaults(ItemID.Bone);
                }
            }
            var foundRecipes = new List <Recipe>();

            if (Config.JestersArrowCraft == 0)
            {
                foreach (var recipe in Main.recipe)
                {
                    if (recipe != null && recipe.createItem != null && recipe.createItem.type == ItemID.JestersArrow)
                    {
                        foundRecipes.Add(recipe);
                    }
                }

                foreach (var recipe in foundRecipes)
                {
                    var editor = new RecipeEditor(recipe);
                    editor.DeleteRecipe();
                }
                foundRecipes.Clear();
            }
            else
            {
                foreach (var recipe in Main.recipe)
                {
                    if (recipe != null && recipe.createItem != null && recipe.createItem.type == ItemID.JestersArrow)
                    {
                        var editor = new RecipeEditor(recipe);
                        editor.SetIngredientStack(ItemID.WoodenArrow, Config.JestersArrowCraft);
                        editor.SetResult(ItemID.JestersArrow, Config.JestersArrowCraft);
                    }
                }
            }
        }
Exemplo n.º 6
0
        public static void PostAddRecipes()
        {
            if (ModContent.GetInstance <ServerConfig>().AncientMuramasa)
            {
                var finder = new RecipeFinder();
                finder.AddIngredient(ItemID.Muramasa);
                var foundRecipes = finder.SearchRecipes();
                foreach (var foundRecipe in foundRecipes)
                {
                    var editor = new RecipeEditor(foundRecipe);
                    editor.AcceptRecipeGroup("GoldensMisc:Muramasa");
                }
            }
            if (ModContent.GetInstance <ServerConfig>().AncientForges)
            {
                var finder = new RecipeFinder();
                finder.AddIngredient(ItemID.Hellforge);
                var foundRecipes = finder.SearchRecipes();
                foreach (var foundRecipe in foundRecipes)
                {
                    var editor = new RecipeEditor(foundRecipe);
                    editor.AcceptRecipeGroup("GoldensMisc:Hellforge");
                }
            }
            if (ModContent.GetInstance <ServerConfig>().NinjaGear)
            {
                var finder = new RecipeFinder();
                finder.AddIngredient(ItemID.TigerClimbingGear);
                finder.AddIngredient(ItemID.Tabi);
                finder.AddIngredient(ItemID.BlackBelt);
                finder.SetResult(ItemID.MasterNinjaGear);

                var foundRecipes = finder.SearchRecipes();
                foreach (var foundRecipe in foundRecipes)
                {
                    var editor = new RecipeEditor(foundRecipe);
                    editor.DeleteIngredient(ItemID.Tabi);
                    editor.DeleteIngredient(ItemID.BlackBelt);
                    editor.AddIngredient(ModContent.ItemType <NinjaGear>());
                }
            }
        }
Exemplo n.º 7
0
        public static void ExactRecipeRemover2Ingredients(int Ingredient1, int Ingredient1Amount, int Ingredient2, int Ingredient2Amount, int CraftingStation, int RecipeResult)
        {
            //this method is for when there's an item whose recipe needs to be removed, but we can't use RecipeRemover
            //that usually means we're giving it a custom recipe somewhere else, since RecipeRemover runs on any recipe that results in that item
            //using exact recipes is thus required. not sure if we need to do this again, but if we do, now theres a method
            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(Ingredient1, Ingredient1Amount);
            finder.AddIngredient(Ingredient2, Ingredient2Amount);
            finder.AddTile(CraftingStation);
            finder.SetResult(RecipeResult);
            Recipe locateRecipe = finder.FindExactRecipe();

            bool recipeFound = locateRecipe != null;

            if (recipeFound)
            {
                RecipeEditor editor = new RecipeEditor(locateRecipe);
                editor.DeleteRecipe();
            }
        }
        public override void PostAddRecipes()
        {
            Mod tremor = ModLoader.GetMod("Tremor");

            if (tremor != null && Config.DommhammerjackhammerSettings == 2)
            {
                RecipeFinder finder = new RecipeFinder(); // make a new RecipeFinder
                finder.AddIngredient(ItemID.Pwnhammer);   // add a new recipe group, in this case the vanilla one for iron or lead bars.
                finder.AddIngredient(tremor.ItemType("DarkBulb"), 15);
                finder.AddIngredient(ItemID.Bone, 100);
                finder.AddTile(TileID.MythrilAnvil);                     // add a required tile, any anvil
                finder.SetResult(tremor.ItemType("Squasher"));           // set the result to be 10 chains
                Recipe exactRecipe = finder.FindExactRecipe();           // try to find the exact recipe matching our criteria

                bool isRecipeFound = exactRecipe != null;                // if our recipe is not null, it means we found the exact recipe
                if (isRecipeFound)                                       // since our recipe is found, we can continue
                {
                    RecipeEditor editor = new RecipeEditor(exactRecipe); // for our recipe, make a new RecipeEditor
                    editor.DeleteRecipe();                               // delete the recipe
                }
            }
        }
Exemplo n.º 9
0
        public override void PostSetupContent()
        {
            base.PostSetupContent();
            RecipeFinder recipeFinder = new RecipeFinder();

            recipeFinder.SetResult(ItemID.BeetleScaleMail);
            recipeFinder.AddIngredient(ItemID.TurtleScaleMail);
            foreach (Recipe recip in recipeFinder.SearchRecipes())
            {
                RecipeEditor recipeEditor = new RecipeEditor(recip);
                recipeEditor.DeleteRecipe();
            }
            ModRecipe recipe = new ModRecipe(this);

            recipe.AddIngredient(ItemID.Gel, 10);
            recipe.AddIngredient(ItemID.Wood, 10);
            recipe.AddIngredient(ItemID.ManaCrystal, 1);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.SlimeStaff);
            recipe.AddRecipe();
            recipe = new ModRecipe(this);
            recipe.AddIngredient(ItemID.ChlorophyteBar, 14);
            recipe.AddIngredient(ItemID.BeetleHusk, 5);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.BeetleHelmet);
            recipe.AddRecipe();
            recipe = new ModRecipe(this);
            recipe.AddIngredient(ItemID.ChlorophyteBar, 27);
            recipe.AddIngredient(ItemID.BeetleHusk, 10);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.BeetleScaleMail);
            recipe.AddRecipe();
            recipe = new ModRecipe(this);
            recipe.AddIngredient(ItemID.ChlorophyteBar, 21);
            recipe.AddIngredient(ItemID.BeetleHusk, 8);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.BeetleLeggings);
            recipe.AddRecipe();
            AlchemistRecipe crecipe = new AlchemistRecipe(this);

            crecipe.AddIngredient(ItemID.Bottle, 15);
            crecipe.AddIngredient(ItemID.Deathweed, 1);
            crecipe.AddIngredient(ItemID.VialofVenom, 1);
            crecipe.AddIngredient(ItemID.Fireblossom, 1);
            crecipe.AddIngredient(ItemID.ExplosivePowder, 1);
            crecipe.AddTile(TileID.AlchemyTable);
            crecipe.SetResult(ItemID.ToxicFlask, 15);
            crecipe.AddRecipe();
            ModMethods.PostSetupContent();
        }
Exemplo n.º 10
0
        public override void AddRecipes()
        {
            RecipeFinder HBR = new RecipeFinder();

            HBR = new RecipeFinder();
            HBR.AddIngredient(ItemID.Hellstone, 3);
            HBR.AddIngredient(ItemID.Obsidian);
            HBR.AddTile(TileID.Hellforge);
            HBR.SetResult(ItemID.HellstoneBar);
            Recipe HBRR = HBR.FindExactRecipe();

            if (HBR != null)
            {
                RecipeEditor HBE = new RecipeEditor(HBRR);
                HBE.DeleteRecipe();
            }

            ModRecipe HSB = new ModRecipe(this);

            HSB.AddIngredient(ItemID.Hellstone, 5);
            HSB.AddTile(TileID.Hellforge);
            HSB.SetResult(ItemID.HellstoneBar);
            HSB.AddRecipe();
        }
        private bool ItemIsDerivativeOfShoeSpikes(Item item)
        {
            if (item.type == ItemID.ShoeSpikes || item.type == ItemID.ClimbingClaws || item.type == ItemID.MasterNinjaGear)
            {
                return(true);
            }

            // TODO: This is an attempt at mod compatibility, but to work properly this would likely require a few layers of recursive searching for items with huge crafting trees.
            RecipeFinder finder = new RecipeFinder();

            finder.SetResult(item.type);
            finder.AddIngredient(ItemID.ShoeSpikes);

            return(finder.SearchRecipes().Count > 0);
        }
        public void PostLoad()
        {
            RecipeFinder finder = new RecipeFinder();

            for (int k = Main.maxItemTypes; k < ItemLoader.ItemCount; k++)
            {
                finder.SetResult(k);
                finder.AddIngredient(ItemID.ShoeSpikes);

                if (finder.SearchRecipes().Count > 0)
                {
                    ShoeSpikeAccessories.Add(k);
                }
            }
        }
Exemplo n.º 13
0
 public static bool AttemptDelete(DeletionRecipe recipe, bool exact)
 {
     Finder = new RecipeFinder();
     Finder.SetResult(recipe.Result.Type, recipe.Result.Stack);
     foreach (DeletionItem ingredient in recipe.Ingredients)
     {
         Finder.AddIngredient(ingredient.Type, ingredient.Stack);
     }
     foreach (short tile in recipe.RequiredTiles)
     {
         Finder.AddTile(tile);
     }
     return(exact
                             ? DeleteExact()
                             : DeleteAlike());
 }
Exemplo n.º 14
0
        // Adapt certain vanilla recipes to our own 'pillar recipes'
        // For Night's Edge there is Blood Carnage, for Mechanical Worm there is Mechanical Brain
        public static void AdaptToNovaRecipes(Mod mod)
        {
            //Night's Edge can't be crafted with Blood Butcherer
            //Mechanical Worm can't be crafted with Vertebrae

            // Search night's edge
            var rFinder = new RecipeFinder();

            rFinder.SetResult(ItemID.NightsEdge);
            rFinder.AddIngredient(ItemID.BloodButcherer);
            // Add to found recipes
            var foundRecipes = rFinder.SearchRecipes();

            // Search mech worm
            rFinder = new RecipeFinder();
            rFinder.SetResult(ItemID.MechanicalWorm);
            rFinder.AddIngredient(ItemID.Vertebrae);
            // Add to found recipes
            foundRecipes = foundRecipes.Concat(rFinder.SearchRecipes()).ToList();

            // For all found recipes, delete them
            foundRecipes.ForEach(recipe =>
            {
                var rEditor = new RecipeEditor(recipe);
                rEditor.DeleteRecipe();
            });

            //The following recipes (with result of this type) require Nova Fragments for crafting
            foreach (short resultType in new short[]
            {
                ItemID.SuperHealingPotion,
                ItemID.CelestialSigil,
                ItemID.FragmentVortex,
                ItemID.FragmentNebula,
                ItemID.FragmentSolar,
                ItemID.FragmentStardust
            })
            {
                rFinder = new RecipeFinder();
                rFinder.SetResult(resultType);
                rFinder.SearchRecipes().ForEach(recipe =>
                {
                    var rEditor = new RecipeEditor(recipe);
                    rEditor.AddIngredient(mod.ItemType <NovaFragment>(), resultType == ItemID.CelestialSigil ? 20 : 1);                    // 20 frags for sigil, 1 for others
                });
            }
        }
Exemplo n.º 15
0
        internal static void AddRecipes(Mod mod)
        {
            RecipeFinder rf = new RecipeFinder();

            rf.SetResult(ItemID.Torch, 3);
            rf.AddIngredient(ItemID.Gel);

            new RecipeEditor(rf.SearchRecipes()[0]).DeleteRecipe();

            ModRecipe r           = new ModRecipe(mod);
            bool      overhaulMod = ModLoader.GetMod("TerrariaOverhaul") != null;

            foreach (Tuple <string, short, int> rc in GelMakeTorchesCount)
            {
                if (rc.Item1 == "Blue" && overhaulMod)
                {
                    continue;
                }
                r.AddGelIngredient(rc.Item1);
                r.AddRecipeGroup(RecipeGroupID.Wood);
                r.SetResult(rc.Item2, Math.Max(overhaulMod? rc.Item3 / 2 : rc.Item3, 1));
                r.AddRecipe();
                r = new ModRecipe(mod);
            }

            foreach (Tuple <short, string, int> rc in ItemRecipesAddGel)
            {
                RecipeFinder finder = new RecipeFinder();
                finder.SetResult(rc.Item1);
                foreach (Recipe recipe in finder.SearchRecipes())
                {
                    recipe.AddIngredient(ColorfulGel.GetGelItem(rc.Item2, rc.Item3));
                }
            }

            r.AddGelIngredient("Ice");
            r.AddRecipeGroup("Wood");
            r.SetResult(ItemID.IceTorch, 3);
            r.AddRecipe();
        }
Exemplo n.º 16
0
        public static void GetAllRecipeByIngredientAndReplace(int ingredientToReplace, int replacingIngredient)
        {
            RecipeFinder rf = new RecipeFinder();

            rf.AddIngredient(ingredientToReplace);

            List <Recipe> list = rf.SearchRecipes();

            for (int i = 0; i < list.Count; i++)
            {
                Recipe       r      = list[i];
                Recipe       recipe = r;
                RecipeEditor re     = new RecipeEditor(recipe);

                if (re.DeleteIngredient(ingredientToReplace))
                {
                    re.AddIngredient(replacingIngredient);
                    Main.recipe[Recipe.numRecipes] = r;
                    Recipe.numRecipes++;
                }
            }
        }
Exemplo n.º 17
0
        public override void AddRecipes()
        {
            ModRecipe newLeather = new ModRecipe(this);

            newLeather.AddRecipeGroup("ExtraGunGear:EvilChunk", 3);
            newLeather.AddTile(TileID.WorkBenches);
            newLeather.SetResult(ItemID.Leather);
            newLeather.AddRecipe();

            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(ItemID.RottenChunk, 5);
            finder.AddTile(TileID.WorkBenches);
            finder.SetResult(ItemID.Leather);
            Recipe recipe2 = finder.FindExactRecipe();

            if (recipe2 != null)
            {
                RecipeEditor editor = new RecipeEditor(recipe2);
                editor.DeleteRecipe();
            }
        }
Exemplo n.º 18
0
        public override void ProcessTriggers(TriggersSet triggersSet)
        {
            if (JustEnoughRecipes.ItemRecipeKey.JustPressed)
            {
                Item selected = Main.mouseItem.netID != 0 ? Main.mouseItem : Main.HoverItem;
                if (selected.netID != 0)
                {
                    Logger.Log(selected.ToString());
                    JustEnoughRecipes.instance.recipeUI.panelTitle.UpdateItem(selected);

                    RecipeFinder finder = new RecipeFinder();
                    finder.SetResult(selected.netID);
                    var result = finder.SearchRecipes();
                    JustEnoughRecipes.instance.recipeUI.SetRecipes(result);
                    JustEnoughRecipes.instance.recipeUI.pageNavigator.SetTotal(result.Count);

                    JustEnoughRecipes.instance.recipeUI.Visible = true;
                }
                else
                {
                    JustEnoughRecipes.instance.recipeUI.Visible = false;
                }
            }
            else if (JustEnoughRecipes.ItemUsageKey.JustPressed)
            {
                // TODO: Usage page
                Item selected = Main.mouseItem.netID != 0 ? Main.mouseItem : Main.HoverItem;
                if (selected.netID != 0)
                {
                    RecipeFinder finder = new RecipeFinder();
                    finder.AddIngredient(selected.netID);
                    foreach (var r in finder.SearchRecipes())
                    {
                        Logger.Log(r.createItem.Name);
                    }
                }
            }
        }
        public static void TestRecipeEditor(Mod mod)
        {
            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(ItemID.Chain);
            foreach (Recipe recipe in finder.SearchRecipes())
            {
                RecipeEditor editor = new RecipeEditor(recipe);
                editor.DeleteIngredient(ItemID.Chain);
            }

            finder = new RecipeFinder();
            finder.AddRecipeGroup("IronBar");
            finder.AddTile(TileID.Anvils);
            finder.SetResult(ItemID.Chain, 10);
            Recipe recipe2 = finder.FindExactRecipe();

            if (recipe2 != null)
            {
                RecipeEditor editor = new RecipeEditor(recipe2);
                editor.DeleteRecipe();
            }
        }
        public override void AddRecipes()
        {
            //-------------------------------------Existing Recipes-------------------------------------\\

            RecipeFinder finder = new RecipeFinder();

            finder.SetResult(151);              //Necro Helmet
            foreach (Recipe r in finder.SearchRecipes())
            {
                RecipeEditor editor = new RecipeEditor(r);
                editor.DeleteTile(18);          //Workbench
                editor.AddTile(300);            //Bone Welder
            }

            finder = new RecipeFinder();
            finder.SetResult(152);              //Necro Breastplate
            foreach (Recipe r in finder.SearchRecipes())
            {
                RecipeEditor editor = new RecipeEditor(r);
                editor.DeleteTile(18);          //Workbench
                editor.AddTile(300);            //Bone Welder
            }

            finder = new RecipeFinder();
            finder.SetResult(153);              //Necro Greaves
            foreach (Recipe r in finder.SearchRecipes())
            {
                RecipeEditor editor = new RecipeEditor(r);
                editor.DeleteTile(18);          //Workbench
                editor.AddTile(300);            //Bone Welder
            }

            finder = new RecipeFinder();
            finder.AddIngredient(795);          //Blood Butcherer
            finder.AddIngredient(155);          //Muramasa
            finder.AddIngredient(190);          //Blade of Grass
            finder.AddIngredient(121);          //Fiery Greatsword
            finder.AddTile(26);                 //Altar
            finder.SetResult(273);              //Night's Edge
            Recipe exactRecipe = finder.FindExactRecipe();

            bool isRecipeFound = exactRecipe != null;

            if (isRecipeFound)
            {
                RecipeEditor editor = new RecipeEditor(exactRecipe);
                editor.DeleteRecipe();
            }

            //-------------------------------------New Recipes-------------------------------------\\

            /*
             * recipe = new ModRecipe(this);
             * recipe.AddIngredient(000);
             * recipe.AddTile(114);                //Tinkerer's Workshop
             * recipe.SetResult(000);
             * recipe.AddRecipe();
             */

            ModRecipe recipe = new ModRecipe(this);

            recipe.AddIngredient(null, "TrueNightsEdgeB");
            recipe.AddIngredient(674);          //True Excalibur
            recipe.AddTile(134);                //Hardmode Anvil
            recipe.SetResult(757);              //Terra Blade
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(null, "Obfuscator");
            recipe.AddIngredient(null, "CursedNaginata");
            recipe.AddIngredient(null, "BoOfGrass");
            recipe.AddIngredient(null, "HellHalberd");
            recipe.AddTile(26);                 //Altar
            recipe.SetResult(274);              //Dark Lance
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(706, 3);       //Platinum Bar
            recipe.AddIngredient(381, 12);      //Cobalt Bar
            recipe.AddIngredient(327);          //Golden Key
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(156);              //Cobalt Shield
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(147, 10);      //Spike
            recipe.AddIngredient(259, 6);       //Leather
            recipe.AddIngredient(225, 2);       //Silk
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(953);              //Climbing Claws
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(147, 10);      //Spike
            recipe.AddIngredient(259, 6);       //Leather
            recipe.AddIngredient(225, 2);       //Silk
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(975);              //Shoe Spikes
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(765, 90);      //Rain Cloud
            recipe.AddIngredient(575, 5);       //Soul of Flight
            recipe.AddIngredient(19, 15);       //Gold Bar
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(158);              //Lucky Horseshoe
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(3756, 90);     //Snow Cloud
            recipe.AddIngredient(575, 5);       //Soul of Flight
            recipe.AddIngredient(3306);         //White String
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(159);              //Shiny Red Balloon
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(751, 90);      //Cloud Block
            recipe.AddIngredient(575, 5);       //Soul of Flight
            recipe.AddIngredient(31);           //Bottle
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(53);               //Cloud in a Bottle
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(169, 90);      //Sand Block
            recipe.AddIngredient(575, 5);       //Soul of Flight
            recipe.AddIngredient(31);           //Bottle
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(857);              //Sandstorm in a Bottle
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(593, 90);      //Snow Block
            recipe.AddIngredient(575, 5);       //Soul of Flight
            recipe.AddIngredient(31);           //Bottle
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(987);              //Blizzard in a Bottle
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(2435, 90);     //Coralstone Block
            recipe.AddIngredient(575, 5);       //Soul of Flight
            recipe.AddIngredient(31);           //Bottle
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(3201);             //Tsunami in a Bottle
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(318);          //Fireblossom
            recipe.AddIngredient(172, 100);     //Ash
            recipe.AddIngredient(173, 100);     //Obsidian
            recipe.AddIngredient(207, 3);       //Lava Bucket
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(1323);             //Obsidian Rose
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(275);          //Coral
            recipe.AddTile(18);                 //Workbench
            recipe.SetResult(2435);             //Coralstone Block
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(2435);         //Coralstone Block
            recipe.AddTile(18);                 //Workbench
            recipe.SetResult(275);              //Coral
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddRecipeGroup("AdvancedTinkering:AnimalSkin");
            recipe.AddTile(18);                 //Workbench
            recipe.SetResult(259, 12);          //Leather
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(225, 20);      //Silk
            recipe.AddIngredient(259, 20);      //Leather
            recipe.AddIngredient(254, 3);       //Black Thread
            recipe.AddTile(86);                 //Loom
            recipe.SetResult(410);              //Miner's Shirt
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(225, 15);      //Silk
            recipe.AddIngredient(259, 25);      //Leather
            recipe.AddIngredient(254, 3);       //Black Thread
            recipe.AddTile(86);                 //Loom
            recipe.SetResult(411);              //Miner's Pants
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(null, "RetinazerMask");
            recipe.AddIngredient(null, "SpazmatismMask");
            recipe.AddTile(18);                 //Workbench
            recipe.SetResult(2106);             //The Twins Mask
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(3111, 30);     //Pink Gel
            recipe.AddIngredient(23, 100);      //Gel
            recipe.AddIngredient(9, 7);         //Purity Wood
            recipe.AddTile(220);                //Solidifier
            recipe.SetResult(1309);             //Slime Staff
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(545, 999);     //Cursed Arrow
            recipe.AddIngredient(1334, 999);    //Ichor Arrow
            recipe.AddIngredient(47, 999);      //Unholy Arrow
            recipe.AddIngredient(516, 999);     //Holy Arrow
            recipe.AddIngredient(265, 999);     //Hellfire Arrow
            recipe.AddIngredient(3003, 999);    //Bone Arrow
            recipe.AddIngredient(259, 25);      //Leather
            recipe.AddTile(114);                //Tinkerer's Workshop
            recipe.SetResult(1321);             //Magic Quiver
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(210);          //Vine
            recipe.SetResult(2996, 6);          //Vine Rope
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddRecipeGroup("Wood", 3);
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(1922);             //Coal
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(2339);         //Tin Can
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(703);              //Tin Bar
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(766);          //Bone Block
            recipe.AddTile(300);                //Bone Welder
            recipe.SetResult(154);              //Bone
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(154, 5);       //Bone
            recipe.AddTile(300);                //Bone Welder
            recipe.SetResult(3003, 5);          //Bone Arrow
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(154);          //Bone
            recipe.AddIngredient(8, 3);         //Torch
            recipe.AddTile(300);                //Bone Welder
            recipe.SetResult(3004, 3);          //Bone Torch
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(19);           //Gold Bar
            recipe.SetResult(1348, 2);          //Gold Dust
            recipe.AddTile(247);                //Autohammer
            recipe.SetResult(327);              //Golden Key
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(1101, 8);      //Lihzahrd Brick
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(303);                //Lihzahrd Furnace
            recipe.SetResult(1142);             //Lihzahrd Chest
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(9, 8);         //Purity Wood
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(304);                //Living Loom
            recipe.SetResult(831);              //Living Wood Chest
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(824, 8);       //Sunplate Block
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(305);                //Sky Mill
            recipe.SetResult(838);              //Skyware Chest
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(3272);         //Hardened Sand Block
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(607, 2);           //Sandstone Brick
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(3271);         //Sandstone Block
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(607, 3);           //Sandstone Brick
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(586, 22);      //Candy Cane Block
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(1909);             //Candy Cane Sword
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(586, 24);      //Candy Cane Block
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(1917);             //Candy Cane Pickaxe
            recipe.AddRecipe();

            recipe = new ModRecipe(this);
            recipe.AddIngredient(586, 20);      //Candy Cane Block
            recipe.AddTile(17);                 //Furnace
            recipe.SetResult(1915);             //Candy Cane Hook
            recipe.AddRecipe();
        }
Exemplo n.º 21
0
        public override void AddRecipes()
        {
            RecipeFinder finder = new RecipeFinder();

            finder.AddIngredient(ItemID.Pumpkin, 20);
            finder.AddTile(TileID.WorkBenches);
            finder.SetResult(ItemID.PumpkinHelmet);
            Recipe recipe1 = finder.FindExactRecipe();

            if (recipe1 != null)
            {
                RecipeEditor editor = new RecipeEditor(recipe1);
                editor.DeleteRecipe();
            }

            finder = new RecipeFinder();
            finder.AddIngredient(ItemID.Pumpkin, 30);
            finder.AddTile(TileID.WorkBenches);
            finder.SetResult(ItemID.PumpkinBreastplate);
            Recipe recipe2 = finder.FindExactRecipe();

            if (recipe2 != null)
            {
                RecipeEditor editor = new RecipeEditor(recipe2);
                editor.DeleteRecipe();
            }

            finder = new RecipeFinder();
            finder.AddIngredient(ItemID.Pumpkin, 25);
            finder.AddTile(TileID.WorkBenches);
            finder.SetResult(ItemID.PumpkinLeggings);
            Recipe recipe3 = finder.FindExactRecipe();

            if (recipe3 != null)
            {
                RecipeEditor editor = new RecipeEditor(recipe3);
                editor.DeleteRecipe();
            }

            ModRecipe recipe = new ModRecipe(mod);

            recipe.AddIngredient(ItemID.Pumpkin, 20);
            recipe.AddRecipeGroup("EvilBar", 5);
            recipe.AddTile(TileID.Anvils);
            recipe.SetResult(ItemID.PumpkinHelmet);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Pumpkin, 30);
            recipe.AddRecipeGroup("EvilBar", 12);
            recipe.AddTile(TileID.Anvils);
            recipe.SetResult(ItemID.PumpkinBreastplate);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Pumpkin, 25);
            recipe.AddRecipeGroup("EvilBar", 8);
            recipe.AddTile(TileID.Anvils);
            recipe.SetResult(ItemID.PumpkinLeggings);
            recipe.AddRecipe();
        }
Exemplo n.º 22
0
        public void CheckRecipesForItem(int type)
        {
            ((ResearchFrom14)mod).ui.recipes.changedToList = true;
            if (ModContent.GetInstance <Config>().researchRecipes)
            {
                Item itm = new Item();
                itm.SetDefaults(type);

                if (itm.createTile >= 0)
                {
                    List <int> tiles = AdjTiles(itm.createTile);
                    foreach (int t in tiles)
                    {
                        RecipeFinder rf = new RecipeFinder();
                        rf.AddTile(t);
                        List <Recipe> res = rf.SearchRecipes();
                        // Main.NewText("Found " + res.Count + "recipes with tile.");
                        foreach (Recipe r in res)
                        {
                            validateAndResearchRecipe(r);
                        }
                    }
                }
                RecipeFinder rf2 = new RecipeFinder();
                rf2.AddIngredient(itm.type);
                List <Recipe> res2 = rf2.SearchRecipes();
                // Main.NewText("Found " + res2.Count + "recipes with item.");
                foreach (Recipe r in res2)
                {
                    validateAndResearchRecipe(r);
                }
            }
            Mod rare = ModLoader.GetMod("ARareItemSwapJPANs");

            if (rare != null && ModContent.GetInstance <Config>().PartsCompat)
            {
                List <string> parts = rare.Call("GetPartList") as List <string>;
                if (parts == null)
                {
                    return;
                }
                parts.RemoveAll((x) => !IsResearched(x));
                if (parts.Count > 0)
                {
                    bool allPartsResearched = true;
                    foreach (string part in parts)
                    {
                        allPartsResearched = allPartsResearched && researchedParts.Contains(part);
                    }
                    if (!allPartsResearched)
                    {
                        List <Item> results = rare.Call("GetMaxPurchasesAvailable", parts) as List <Item>;

                        if (results == null)
                        {
                            return;
                        }
                        foreach (string part in parts)
                        {
                            if (!researchedParts.Contains(part))
                            {
                                researchedParts.Add(part);
                            }
                        }
                        foreach (Item result in results)
                        {
                            if (!IsResearched(result))
                            {
                                AddResearchedAmount(result.type, Int32.MaxValue - 1000);
                                researchedCache.Add(result.type);
                                CheckRecipesForItem(result.type);
                            }
                        }
                    }
                }
            }
        }
Exemplo n.º 23
0
        //public override bool PreKill(double damage, int hitDirection, bool pvp, ref bool playSound, ref bool genGore,
        //    ref PlayerDeathReason damageSource)
        //{
        //    position = Main.LocalPlayer.position;
        //    return true;
        //}

        public override void ProcessTriggers(TriggersSet triggersSet)
        {
            if (Error666Wings)
            {
                if (MoTools.DevSpeedHotKey.Current)
                {
                    //Error666Wings.HorizontalWingSpeeds(player, ref speed, ref acceleration).speed = 50f;
                    //Error666Wings.HorizontalWingSpeeds(player, ref speed, ref acceleration).acceleration *= 30.0f;

                    player.runAcceleration *= 30.0f;
                    player.accRunSpeed      = 50f;
                }
            }

            if (MoTools.SecretHotKey.Current)
            {
                /*if (!SecretRecipe)
                 * {
                 *  ModRecipe recipe = new ModRecipe(mod);
                 *  recipe.AddIngredient(ItemID.DirtBlock);
                 *  recipe.SetResult(ItemType<Error666Wings>());
                 *  recipe.AddRecipe();
                 *
                 *  SecretRecipe = true;
                 * }*/
                /*else
                 * {
                 *  RecipeFinder finder = new RecipeFinder(); // make a new RecipeFinder
                 *
                 *  finder = new RecipeFinder(); // make a new RecipeFinder
                 *  finder.AddIngredient(ItemID.DirtBlock); // add a required tile, any anvil
                 *  finder.SetResult(ItemType<Error666Wings>()); // set the result to be 10 chains
                 *  Recipe exactRecipe = finder.FindExactRecipe(); // try to find the exact recipe matching our criteria
                 *
                 *  bool isRecipeFound = exactRecipe != null; // if our recipe is not null, it means we found the exact recipe
                 *  if (isRecipeFound) // since our recipe is found, we can continue
                 *  {
                 *      RecipeEditor editor = new RecipeEditor(exactRecipe); // for our recipe, make a new RecipeEditor
                 *      editor.DeleteRecipe(); // delete the recipe
                 *  }
                 *
                 *  SecretRecipe = false;
                 * }*/
            }
            else
            {
                RecipeFinder finder = new RecipeFinder();                // make a new RecipeFinder

                finder = new RecipeFinder();                             // make a new RecipeFinder
                finder.AddIngredient(ItemID.DirtBlock);                  // add a required tile, any anvil
                finder.SetResult(ItemType <Error666Wings>());            // set the result to be 10 chains
                Recipe exactRecipe = finder.FindExactRecipe();           // try to find the exact recipe matching our criteria

                bool isRecipeFound = exactRecipe != null;                // if our recipe is not null, it means we found the exact recipe
                if (isRecipeFound)                                       // since our recipe is found, we can continue
                {
                    RecipeEditor editor = new RecipeEditor(exactRecipe); // for our recipe, make a new RecipeEditor
                    editor.DeleteRecipe();                               // delete the recipe
                }

                SecretRecipe = false;
            }
        }
Exemplo n.º 24
0
        public override void AddRecipes()
        {
            ModRecipe recipe = new ModRecipe(mod);

            recipe.AddRecipeGroup("Wood", 5);
            recipe.AddRecipeGroup("TenebraeMod:GoldBar", 3);
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.GoldChest);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddRecipeGroup("TenebraeMod:DemoniteBrick", 8);
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(TileID.Anvils);
            recipe.SetResult(ItemID.ShadowChest);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddRecipeGroup("Wood", 5);
            recipe.AddIngredient(ItemID.JungleSpores, 2);
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.IvyChest);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Coral, 8);
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.WaterChest);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Chest);
            recipe.AddIngredient(ItemID.Cobweb, 8);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.WebCoveredChest);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Chest, 5);
            recipe.AddIngredient(ItemID.SnowBlock, 25);
            recipe.AddIngredient(ItemID.IceBlock, 25);
            recipe.AddIngredient(ItemID.TempleKey);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.FrozenChest, 5);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Chest, 5);
            recipe.AddIngredient(ItemID.MudBlock, 25);
            recipe.AddIngredient(ItemID.JungleGrassSeeds, 25);
            recipe.AddIngredient(ItemID.TempleKey);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.JungleChest, 5);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Chest, 5);
            recipe.AddIngredient(ItemID.PearlstoneBlock, 50);
            recipe.AddIngredient(ItemID.TempleKey);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.HallowedChest, 5);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Chest, 5);
            recipe.AddIngredient(ItemID.EbonstoneBlock, 50);
            recipe.AddIngredient(ItemID.TempleKey);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.CorruptionChest, 5);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Chest, 5);
            recipe.AddIngredient(ItemID.CrimstoneBlock, 50);
            recipe.AddIngredient(ItemID.TempleKey);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.CrimsonChest, 5);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Frog, 5);
            recipe.AddTile(TileID.Sawmill);
            recipe.SetResult(ItemID.FrogLeg);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Cloud, 50);
            recipe.AddIngredient(ItemID.Bottle);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.CloudinaBottle);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Cloud, 25);
            recipe.AddIngredient(ItemID.SnowBlock, 25);
            recipe.AddIngredient(ItemID.Bottle);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.BlizzardinaBottle);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Cloud, 25);
            recipe.AddIngredient(ItemID.SandBlock, 25);
            recipe.AddIngredient(ItemID.Bottle);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.SandstorminaBottle);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Cloud, 20);
            recipe.AddIngredient(ItemID.WhiteString, 2);
            recipe.AddIngredient(ItemID.Feather, 10);
            recipe.AddTile(TileID.SkyMill);
            recipe.SetResult(ItemID.ShinyRedBalloon);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.OldShoe);
            recipe.AddIngredient(ItemID.Silk, 5);
            recipe.AddIngredient(ItemID.Feather, 10);
            recipe.AddTile(TileID.Loom);
            recipe.SetResult(ItemID.HermesBoots);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.OldShoe);
            recipe.AddIngredient(ItemID.Coral, 5);
            recipe.AddIngredient(ItemID.WaterWalkingPotion, 5);
            recipe.AddTile(TileID.Loom);
            recipe.SetResult(ItemID.WaterWalkingBoots);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.OldShoe);
            recipe.AddIngredient(ItemID.IceBlock, 25);
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(TileID.Loom);
            recipe.SetResult(ItemID.IceSkates);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Silk, 3);
            recipe.AddRecipeGroup("IronBar", 2);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.Aglet);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "TatteredBand");
            recipe.AddIngredient(ItemID.JungleSpores, 10);
            recipe.AddIngredient(ItemID.Cloud, 5);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.AnkletoftheWind);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Leather, 5);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.OldShoe);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "TatteredBand");
            recipe.AddIngredient(ItemID.RegenerationPotion, 3);
            recipe.AddIngredient(ItemID.LifeCrystal, 1);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.BandofRegeneration);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "TatteredBand");
            recipe.AddIngredient(ItemID.ManaRegenerationPotion, 3);
            recipe.AddIngredient(ItemID.ManaCrystal, 1);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.BandofStarpower);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.Vine, 10);
            recipe.AddIngredient(ItemID.Leather, 5);
            recipe.AddTile(TileID.Loom);
            recipe.SetResult(ItemID.FeralClaws);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.FeralClaws);
            recipe.AddIngredient(ItemID.Spike, 10);
            recipe.AddTile(TileID.Anvils);
            recipe.SetResult(ItemID.ClimbingClaws);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.OldShoe);
            recipe.AddIngredient(ItemID.Spike, 10);
            recipe.AddTile(TileID.Anvils);
            recipe.SetResult(ItemID.ShoeSpikes);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.OldShoe);
            recipe.AddIngredient(ItemID.DayBloomPlanterBox, 25);
            recipe.AddIngredient(ItemID.JungleGrassSeeds, 10);
            recipe.AddTile(TileID.Loom);
            recipe.SetResult(ItemID.FlowerBoots);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddRecipeGroup("TenebraeMod:GoldBar", 3);
            recipe.AddIngredient(ItemID.Cloud, 50);
            recipe.AddIngredient(ItemID.Feather, 5);
            recipe.AddTile(TileID.SkyMill);
            recipe.SetResult(ItemID.LuckyHorseshoe);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "Paper", 3);
            recipe.AddIngredient(ItemID.Leather);
            recipe.AddTile(TileID.WorkBenches);
            recipe.SetResult(ItemID.Book, 3);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.SpellTome);
            recipe.AddIngredient(ItemID.WaterCandle, 3);
            recipe.AddIngredient(ItemID.Bone, 20);
            recipe.AddTile(TileID.Bookcases);
            recipe.SetResult(ItemID.WaterBolt);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.SpellTome);
            recipe.AddIngredient(ItemID.LivingDemonFireBlock, 20);
            recipe.AddIngredient(ItemID.SoulofNight, 15);
            recipe.AddTile(TileID.Bookcases);
            recipe.SetResult(ItemID.DemonScythe);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.SpellTome);
            recipe.AddIngredient(ItemID.CelestialMagnet);
            recipe.AddIngredient(ItemID.Ectoplasm, 15);
            recipe.AddTile(TileID.Bookcases);
            recipe.SetResult(ItemID.MagnetSphere);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "WornCloth", 15);
            recipe.AddIngredient(ItemID.SoulofNight, 6);
            recipe.AddIngredient(ItemID.DarkShard, 2);
            recipe.AddTile(TileID.MythrilAnvil);
            recipe.SetResult(ItemID.Blindfold);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "WornCloth", 10);
            recipe.AddIngredient(ItemID.SandBlock, 50);
            recipe.AddIngredient(ItemID.Sandstone, 25);
            recipe.AddTile(TileID.Loom);
            recipe.SetResult(ItemID.FlyingCarpet);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "TatteredBand", 1);
            recipe.AddIngredient(ItemID.LavaBucket, 3);
            recipe.AddIngredient(ItemID.AshBlock, 25);
            recipe.AddTile(TileID.Hellforge);
            recipe.SetResult(ItemID.LavaCharm);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.ArmorBracing);
            recipe.AddIngredient(ItemID.MedicatedBandage);
            recipe.AddIngredient(ItemID.ThePlan);
            recipe.AddIngredient(ItemID.CountercurseMantra);
            recipe.AddIngredient(ItemID.Blindfold);
            recipe.AddIngredient(null, "ReflectiveGlove");
            recipe.AddTile(TileID.TinkerersWorkbench);
            recipe.SetResult(ItemID.AnkhCharm);
            recipe.AddRecipe();

            recipe = new ModRecipe(mod);
            recipe.AddIngredient(null, "MoldyHerosTome");
            recipe.AddTile(TileID.DemonAltar);
            recipe.SetResult(ItemID.BrokenHeroSword);
            recipe.AddRecipe();


            finder = new RecipeFinder();
            finder.AddIngredient(ItemID.Blindfold);
            finder.AddIngredient(ItemID.ArmorBracing);
            finder.AddIngredient(ItemID.MedicatedBandage);
            finder.AddIngredient(ItemID.ThePlan);
            finder.AddIngredient(ItemID.CountercurseMantra);
            finder.AddTile(TileID.TinkerersWorkbench);
            finder.SetResult(ItemID.AnkhCharm);
            Recipe recipe2 = finder.FindExactRecipe();

            if (recipe2 != null)
            {
                RecipeEditor editor = new RecipeEditor(recipe2);
                editor.DeleteRecipe();
            }
        }