Standalone [1.3] tModLoader - A Modding API

May i ask. Does anyone know what the Accessory slots are?

I know theres boots, Shield, gloves i believe but what are they.. not really sure where to look to find out
 
May i ask. Does anyone know what the Accessory slots are?

I know theres boots, Shield, gloves i believe but what are they.. not really sure where to look to find out
there's also: belt, balloon, head (I don't remember if that is the correct slot name but think of the blindfold''s location when it is equipped)
 
Ok so, since the format has been slightly changed in the way things are loaded, my items wont show up as recipes. I've been trying to make them show up for a bit now, Here's the code, any insight would be greatly appreciated.
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using WyvernCore.Items;
using WyvernCore.NPCs;
using WyvernCore.Items.Armor;

namespace WyvernCore {
public class WyvernCore : Mod
{
public override void SetModInfo(out string name, ref ModProperties properties)
{
name = "WyvernCore";
properties.Version = "v1.2.3";
properties.Author = "WyvernHunter";
properties.Autoload = true;
}

public override void Load()
{
AddItem("FeatherBlade", new FeatherBlade();
//AddItem("CloudBar", new CloudBar(), "WyvernCore/Items/CloudBar");
//AddItem("WyvernScale", new WyvernScale(), "WyvernCore/Items/WyvernScale");
//AddItem("SkyBlade", new SkyBlade(), "WyvernCore/Items/SkyBlade");
//AddItem("WyvernScaleMailBreastPlate"), new WyvernScaleMail(), "WyvernCore/Items/Armor/");


}

/* public override void AddRecipes();
{
RecipeHelper.AddVanillaRecipes(this);
} */
}
}
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore.Items {
public class FeatherBlade : ModItem
{
public override void SetDefaults()
{
item.name = "Feathery Blade";
item.damage = 42;
item.melee = true;
item.width = 40;
item.height = 40;
item.toolTip = "Doesn't seem very sharp...";
item.useTime = 18;
item.useAnimation = 18;
item.useStyle = 1;
item.knockBack = 8;
item.value = 20000;
item.rare = 2;
item.useSound = 1;
item.autoReuse = true;
}
public override void AddRecipes() {
ModRecipe recipe = new ModRecipe(mod);
recipe.AddIngredient(ItemID.DirtBlock,2);
// recipe.AddIngredient(ItemID.Feather,15);
// recipe.AddIngredient(ItemID.GiantHarpyFeather);
recipe.SetResult(this);
//recipe.AddTile(134);
recipe.AddRecipe();
}
}
}
/SPOILER]
using System;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore {
public static class RecipeHelper
{
public static void AddVanillaRecipes(Mod mod)
{
ModRecipe recipe = new ModRecipe(mod);

}

}
}
 
Ok so, since the format has been slightly changed in the way things are loaded, my items wont show up as recipes. I've been trying to make them show up for a bit now, Here's the code, any insight would be greatly appreciated.
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using WyvernCore.Items;
using WyvernCore.NPCs;
using WyvernCore.Items.Armor;

namespace WyvernCore {
public class WyvernCore : Mod
{
public override void SetModInfo(out string name, ref ModProperties properties)
{
name = "WyvernCore";
properties.Version = "v1.2.3";
properties.Author = "WyvernHunter";
properties.Autoload = true;
}

public override void Load()
{
AddItem("FeatherBlade", new FeatherBlade();
//AddItem("CloudBar", new CloudBar(), "WyvernCore/Items/CloudBar");
//AddItem("WyvernScale", new WyvernScale(), "WyvernCore/Items/WyvernScale");
//AddItem("SkyBlade", new SkyBlade(), "WyvernCore/Items/SkyBlade");
//AddItem("WyvernScaleMailBreastPlate"), new WyvernScaleMail(), "WyvernCore/Items/Armor/");


}

/* public override void AddRecipes();
{
RecipeHelper.AddVanillaRecipes(this);
} */
}
}
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore.Items {
public class FeatherBlade : ModItem
{
public override void SetDefaults()
{
item.name = "Feathery Blade";
item.damage = 42;
item.melee = true;
item.width = 40;
item.height = 40;
item.toolTip = "Doesn't seem very sharp...";
item.useTime = 18;
item.useAnimation = 18;
item.useStyle = 1;
item.knockBack = 8;
item.value = 20000;
item.rare = 2;
item.useSound = 1;
item.autoReuse = true;
}
public override void AddRecipes() {
ModRecipe recipe = new ModRecipe(mod);
recipe.AddIngredient(ItemID.DirtBlock,2);
// recipe.AddIngredient(ItemID.Feather,15);
// recipe.AddIngredient(ItemID.GiantHarpyFeather);
recipe.SetResult(this);
//recipe.AddTile(134);
recipe.AddRecipe();
}
}
}
/SPOILER]
using System;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore {
public static class RecipeHelper
{
public static void AddVanillaRecipes(Mod mod)
{
ModRecipe recipe = new ModRecipe(mod);

}

}
}
First of all, properties.Version and properties.Author no longer exist; you put them in build.txt instead (see the example mod for an example).
Next of all, this line: AddItem("FeatherBlade", new FeatherBlade();
is complete. My guess is that your mod just isn't building.
 
First of all, properties.Version and properties.Author no longer exist; you put them in build.txt instead (see the example mod for an example).
Next of all, this line: AddItem("FeatherBlade", new FeatherBlade();
is complete. My guess is that your mod just isn't building.
Oh ok, I guess i need to look at the example mod again, thanks for the help.
 
Progress has been made, ive cleaned up mostly everything(hopefully) but im getting an odd error with AddItem
c:\Users\Lisa\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(21,3) : error CS1501: No overload for method 'AddItem' takes 2 arguments

c:\Users\Lisa\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(22,3) : error CS1501: No overload for method 'AddItem' takes 2 arguments

c:\Users\Lisa\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(23,3) : error CS1501: No overload for method 'AddItem' takes 2 arguments
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using WyvernCore.Items;
using WyvernCore.Items.Armor;
using WyvernCore.NPCs;

namespace WyvernCore {
public class WyvernCore : Mod
{
public override void SetModInfo(out string name, ref ModProperties properties)
{
name = "WyvernCore";
properties.Autoload = true;
}

public override void Load()
{
AddItem("FeatherBlade", new FeatherBlade());
AddItem("CloudBar", new CloudBar());
AddItem("WyvernScaleMailBreastPlate", new WyvernScaleMailBreastPlate());
//AddItem("WyvernScale", new WyvernScale()
//AddItem("SkyBlade", new SkyBlade()



}

/* public override void AddRecipes();
{
RecipeHelper.AddVanillaRecipes(this);
} */
}
}
 
Progress has been made, ive cleaned up mostly everything(hopefully) but im getting an odd error with AddItem
c:\Users\Lisa\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(21,3) : error CS1501: No overload for method 'AddItem' takes 2 arguments

c:\Users\Lisa\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(22,3) : error CS1501: No overload for method 'AddItem' takes 2 arguments

c:\Users\Lisa\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(23,3) : error CS1501: No overload for method 'AddItem' takes 2 arguments
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using WyvernCore.Items;
using WyvernCore.Items.Armor;
using WyvernCore.NPCs;

namespace WyvernCore {
public class WyvernCore : Mod
{
public override void SetModInfo(out string name, ref ModProperties properties)
{
name = "WyvernCore";
properties.Autoload = true;
}

public override void Load()
{
AddItem("FeatherBlade", new FeatherBlade());
AddItem("CloudBar", new CloudBar());
AddItem("WyvernScaleMailBreastPlate", new WyvernScaleMailBreastPlate());
//AddItem("WyvernScale", new WyvernScale()
//AddItem("SkyBlade", new SkyBlade()



}

/* public override void AddRecipes();
{
RecipeHelper.AddVanillaRecipes(this);
} */
}
}
I just realized something; if you're autoloading the items, then why are you calling AddItem?
 
I just realized something; if you're autoloading the items, then why are you calling AddItem?
So....what else would i do? i assumed my items were not appearing as recipes because they werent being added. I believe i have done the recipe adding part correct, so what else is preventing the recipes?
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore.Items {
public class FeatherBlade : ModItem
{
public override void SetDefaults()
{
item.name = "Feathery Blade";
item.damage = 42;
item.melee = true;
item.width = 40;
item.height = 40;
item.toolTip = "Doesn't seem very sharp...";
item.useTime = 18;
item.useAnimation = 18;
item.useStyle = 1;
item.knockBack = 8;
item.value = 20000;
item.rare = 2;
item.useSound = 1;
item.autoReuse = true;
}
public override void AddRecipes() {
ModRecipe recipe = new ModRecipe(mod);
recipe.AddIngredient(ItemID.DirtBlock,2);
//recipe.AddIngredient(ItemID.Feather,15);
//recipe.AddIngredient(ItemID.GiantHarpyFeather);
recipe.SetResult(this);
//recipe.AddTile(134);
recipe.AddRecipe();
}
}
}
 
So....what else would i do? i assumed my items were not appearing as recipes because they werent being added. I believe i have done the recipe adding part correct, so what else is preventing the recipes?
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore.Items {
public class FeatherBlade : ModItem
{
public override void SetDefaults()
{
item.name = "Feathery Blade";
item.damage = 42;
item.melee = true;
item.width = 40;
item.height = 40;
item.toolTip = "Doesn't seem very sharp...";
item.useTime = 18;
item.useAnimation = 18;
item.useStyle = 1;
item.knockBack = 8;
item.value = 20000;
item.rare = 2;
item.useSound = 1;
item.autoReuse = true;
}
public override void AddRecipes() {
ModRecipe recipe = new ModRecipe(mod);
recipe.AddIngredient(ItemID.DirtBlock,2);
//recipe.AddIngredient(ItemID.Feather,15);
//recipe.AddIngredient(ItemID.GiantHarpyFeather);
recipe.SetResult(this);
//recipe.AddTile(134);
recipe.AddRecipe();
}
}
}
I'm not entirely sure what's happening. Your mod is building perfectly fine with the recent v0.3 version, and there's no loading errors?
 
I'm not entirely sure what's happening. Your mod is building perfectly fine with the recent v0.3 version, and there's no loading errors?
There are no errors right now, im ingame holding dirt and wood seeing if i can craft the sword, and i can't. so no errors, the only errors that i have gotten so far have been involved with the including the recipe helper in WyvernCore, but that doesn't affect recipes that are loaded in from the items does it? *There are no errors when i comment out the AddItem lines and keep autoload set to true*
 
I'm not entirely sure what's happening. Your mod is building perfectly fine with the recent v0.3 version, and there's no loading errors?
Seems to be something from the update, my recipes doesnt have ingredients either: see?
joeqt.jpg

They had the last update.
 
Seems to be something from the update, my recipes doesnt have ingredients either: see?
joeqt.jpg

They had the last update.
I believe that to be something else WhiteWolf, my recipes wont show up at all :p but that is odd as well.
I've got no idea what's happening, since the Example Mod recipes all work perfectly fine. Can I see the code for your mod and items files again? (And preferably indented.)
 
I've got no idea what's happening, since the Example Mod recipes all work perfectly fine. Can I see the code for your mod and items files again? (And preferably indented.)
Nvm, for some reason i commented the recipe and i forgot.
Vanilla seems to work at least:
Code:
public override void AddRecipes()
        {
            ModRecipe recipe = new ModRecipe(mod);
            recipe.AddIngredient(ItemID.DirtBlock);
            recipe.SetResult(this, 1);
            recipe.AddRecipe();
        }
 
I've got no idea what's happening, since the Example Mod recipes all work perfectly fine. Can I see the code for your mod and items files again? (And preferably indented.)
Sure, would that be using the Code BB thing instead? The AddRecipes part is being weird so its commented out, and i commented out all the AddItems since AutoLoad is set to True.
Code:
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using WyvernCore.Items;
using WyvernCore.Items.Armor;
using WyvernCore.NPCs;

namespace WyvernCore {
public class WyvernCore : Mod
{
    public override void SetModInfo(out string name, ref ModProperties properties)
    {
        name = "WyvernCore";
        properties.Autoload = true;
    }

    public override void Load()
    {
        //AddItem("FeatherBlade", new FeatherBlade());
        //AddItem("CloudBar", new CloudBar());
        //AddItem("WyvernScaleMailBreastPlate", new WyvernScaleMailBreastPlate());
        //AddItem("WyvernScale", new WyvernScale()
        //AddItem("SkyBlade", new SkyBlade()

    
    
    }

  /*  public override void AddRecipes();
    {
    RecipeHelper.AddVanillaRecipes(this);
    } */
}
}

Code:
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore.Items {
public class FeatherBlade : ModItem
{
    public override void SetDefaults()
    {
        item.name = "Feathery Blade";
        item.damage = 42;
        item.melee = true;
        item.width = 40;
        item.height = 40;
        item.toolTip = "Doesn't seem very sharp...";
        item.useTime = 18;
        item.useAnimation = 18;
        item.useStyle = 1;
        item.knockBack = 8;
        item.value = 20000;
        item.rare = 2;
        item.useSound = 1;
        item.autoReuse = true;
    }
    public override void AddRecipes() {
       ModRecipe recipe = new ModRecipe(mod);
        recipe.AddIngredient(ItemID.DirtBlock,2);
        //recipe.AddIngredient(ItemID.Feather,15);
        //recipe.AddIngredient(ItemID.GiantHarpyFeather);
        recipe.SetResult(this);
        //recipe.AddTile(134);
        recipe.AddRecipe();
}
}
}

Code:
using System;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore {
public static class RecipeHelper
{
    public static void AddVanillaRecipes(Mod mod)
    {
        ModRecipe recipe = new ModRecipe(mod);

    }

}
}
 
Sure, would that be using the Code BB thing instead? The AddRecipes part is being weird so its commented out, and i commented out all the AddItems since AutoLoad is set to True.
Code:
using System;
using Microsoft.Xna.Framework;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;
using WyvernCore.Items;
using WyvernCore.Items.Armor;
using WyvernCore.NPCs;

namespace WyvernCore {
public class WyvernCore : Mod
{
    public override void SetModInfo(out string name, ref ModProperties properties)
    {
        name = "WyvernCore";
        properties.Autoload = true;
    }

    public override void Load()
    {
        //AddItem("FeatherBlade", new FeatherBlade());
        //AddItem("CloudBar", new CloudBar());
        //AddItem("WyvernScaleMailBreastPlate", new WyvernScaleMailBreastPlate());
        //AddItem("WyvernScale", new WyvernScale()
        //AddItem("SkyBlade", new SkyBlade()

      
      
    }

  /*  public override void AddRecipes();
    {
    RecipeHelper.AddVanillaRecipes(this);
    } */
}
}

Code:
using System;
using Terraria;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore.Items {
public class FeatherBlade : ModItem
{
    public override void SetDefaults()
    {
        item.name = "Feathery Blade";
        item.damage = 42;
        item.melee = true;
        item.width = 40;
        item.height = 40;
        item.toolTip = "Doesn't seem very sharp...";
        item.useTime = 18;
        item.useAnimation = 18;
        item.useStyle = 1;
        item.knockBack = 8;
        item.value = 20000;
        item.rare = 2;
        item.useSound = 1;
        item.autoReuse = true;
    }
    public override void AddRecipes() {
       ModRecipe recipe = new ModRecipe(mod);
        recipe.AddIngredient(ItemID.DirtBlock,2);
        //recipe.AddIngredient(ItemID.Feather,15);
        //recipe.AddIngredient(ItemID.GiantHarpyFeather);
        recipe.SetResult(this);
        //recipe.AddTile(134);
        recipe.AddRecipe();
}
}
}

Code:
using System;
using Terraria.ID;
using Terraria.ModLoader;

namespace WyvernCore {
public static class RecipeHelper
{
    public static void AddVanillaRecipes(Mod mod)
    {
        ModRecipe recipe = new ModRecipe(mod);

    }

}
}
Alright, it's time to diagnose the problem. At the end of SetDefaults, add ErrorLogger.Log("test"); and at the end of your item's AddRecipes add ErrorLogger.Log("test2");
Then after you rebuild then reload your mod, check the Logs file and tell me what you see.
 
Alright, it's time to diagnose the problem. At the end of SetDefaults, add ErrorLogger.Log("test"); and at the end of your item's AddRecipes add ErrorLogger.Log("test2");
Then after you rebuild then reload your mod, check the Logs file and tell me what you see.
Exception of type 'System.OutOfMemoryException' was thrown.
at System.IO.BinaryReader.ReadBytes(Int32 count)
at Terraria.ModLoader.ModLoader.LoadMod(String modFile)
at Terraria.ModLoader.ModLoader.LoadMods()
and here's the compile errors from when i un-comment the AddRecipe piece in WyvernCore
c:\Users\\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(32,5) : error CS1519: Invalid token '{' in class, struct, or interface member declaration

c:\Users\\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(33,32) : error CS1519: Invalid token '(' in class, struct, or interface member declaration

c:\Users\\Documents\My Games\Terraria\ModLoader\Mod Sources\WyvernCore\WyvernCore.cs(36,1) : error CS1022: Type or namespace definition, or end-of-file expected
 
Back
Top Bottom