Standalone [1.3] tModLoader - A Modding API

It's ok now I figured it out :happy: but still thanks
I have the sam probablem and i cannot fix it please tell me how u fixed it
[doublepost=1466523971,1466523802][/doublepost]
can you show the code?

{ using Terraria;
using System;
using Terraria.ID;
using Microsoft.Xna.Framework;
using Terraria.tModloader;

namespace YourModName.Items.Weapons
{

public class YoyoName : ModItem
{
public override void SetDefaults()
{
item.CloneDefaults(ItemID.WoodYoyo);
item.name - "NikIsSick's Yoyo";
item.damage - 290;
item.value - 500;
item.rare - 9;
item.knockback - 15;
item.channel - true;
item.useStyle - 5;
item.useAnimation - 25;
item.useTime - 10;
item.shoot - mod.ProjectileType("YoyoPName");
}

public override void AddRecipes()
{
ModRecipe recipe - new ModRecipe(mod);
recipe.AddIngredient(null, "Dirt Block" 1);
recipe.SetResult(this);
recipe.AddRecipe();
}


}}
[doublepost=1466524532][/doublepost]
It's ok now I figured it out :happy: but still thanks
how did you fix it i have the same problem
 
I have the sam probablem and i cannot fix it please tell me how u fixed it
[doublepost=1466523971,1466523802][/doublepost]

{ using Terraria;
using System;
using Terraria.ID;
using Microsoft.Xna.Framework;
using Terraria.tModloader;

namespace YourModName.Items.Weapons
{

public class YoyoName : ModItem
{
public override void SetDefaults()
{
item.CloneDefaults(ItemID.WoodYoyo);
item.name - "NikIsSick's Yoyo";
item.damage - 290;
item.value - 500;
item.rare - 9;
item.knockback - 15;
item.channel - true;
item.useStyle - 5;
item.useAnimation - 25;
item.useTime - 10;
item.shoot - mod.ProjectileType("YoyoPName");
}

public override void AddRecipes()
{
ModRecipe recipe - new ModRecipe(mod);
recipe.AddIngredient(null, "Dirt Block" 1);
recipe.SetResult(this);
recipe.AddRecipe();
}


}}
[doublepost=1466524532][/doublepost]
how did you fix it i have the same problem
Your recipe is off. This:
Code:
recipe.AddIngredient(null, "Dirt Block" 1);
should be this:
Code:
recipe.AddIngredient(ItemID.DirtBlock);
Do make sure to add using Terraria.ID; to the top of you file if you do this.
 
What exactly would you do (in tile sheet sprites) to make the tile mesh together with another custom tile?
I'm really, really confused.
EDIT: For more clarification, it's like how the Example Block meshes with the dirt block on the tile sheet.
Well, for anything but dirt, I'm not sure, but if you look at iron ore for example, you'll see that there are extra sprites for it when it is next to dirt, I think for custom blocks, you have to do the same, but change the code in some way so the game merges it.
 
my projectile is now homing
Whenever the projectile goes off screen, the game lags really hard until either the projectile ends or it returns to the screen :(
is there a way to fix this, or is my computer just bad.

I usually don't have lag problems

if all else fails, is there a way to make it only home on things on screen?
 
what is the max number of items a recipe can have

i am not saying like 1000000 dirt

i mean like

dirt
stone
wood
iron
lead
...

so on what is the max
 
what is the max number of items a recipe can have

i am not saying like 1000000 dirt

i mean like

dirt
stone
wood
iron
lead
...

so on what is the max
I think the max was either 6 or 8.
I'm not quite sure, but you can debug it very easily and see when the recipe breaks.
 
I think the max was either 6 or 8.
I'm not quite sure, but you can debug it very easily and see when the recipe breaks.

i get like 15 but thats not many for what i do also i get something that makes no sense

i tryed this and it gave fail of recipe overflow but it did not say it where the 40 items are but
at the first "pack10" in the first recipe but in another one with the same recipe items
it gave the error at the "card196" in the 3rd recipe with the 40 items in it



public override void AddRecipes()
{
ModRecipe recipe = new ModRecipe(mod);
recipe.AddIngredient(null, "pack10", 1);
recipe.AddIngredient(null, "pack20", 1);
recipe.AddIngredient(null, "pack30", 1);
recipe.AddIngredient(null, "pack40", 1);
recipe.SetResult(this);
recipe.AddRecipe();
recipe = new ModRecipe(mod);
recipe.AddIngredient(null, "utype91", 1);
recipe.AddIngredient(null, "utype92", 1);
recipe.AddIngredient(null, "utype93", 1);
recipe.AddIngredient(null, "utype94", 1);
recipe.AddIngredient(null, "utype95", 1);
recipe.AddIngredient(null, "utype96", 1);
recipe.AddIngredient(null, "utype97", 1);
recipe.AddIngredient(null, "utype98", 1);
recipe.AddIngredient(null, "utype99", 1);
recipe.AddIngredient(null, "utype100", 1);
recipe.SetResult(this);
recipe.AddRecipe();
recipe = new ModRecipe(mod);
recipe.AddIngredient(null, "card91", 1);
recipe.AddIngredient(null, "card92", 1);
recipe.AddIngredient(null, "card93", 1);
recipe.AddIngredient(null, "card94", 1);
recipe.AddIngredient(null, "card95", 1);
recipe.AddIngredient(null, "card96", 1);
recipe.AddIngredient(null, "card97", 1);
recipe.AddIngredient(null, "card98", 1);
recipe.AddIngredient(null, "card99", 1);
recipe.AddIngredient(null, "card100", 1);
recipe.AddIngredient(null, "card191", 1);
recipe.AddIngredient(null, "card192", 1);
recipe.AddIngredient(null, "card193", 1);
recipe.AddIngredient(null, "card194", 1);
recipe.AddIngredient(null, "card195", 1);
recipe.AddIngredient(null, "card196", 1);
recipe.AddIngredient(null, "card197", 1);
recipe.AddIngredient(null, "card198", 1);
recipe.AddIngredient(null, "card199", 1);
recipe.AddIngredient(null, "card200", 1);
recipe.AddIngredient(null, "card291", 1);
recipe.AddIngredient(null, "card292", 1);
recipe.AddIngredient(null, "card293", 1);
recipe.AddIngredient(null, "card294", 1);
recipe.AddIngredient(null, "card295", 1);
recipe.AddIngredient(null, "card296", 1);
recipe.AddIngredient(null, "card297", 1);
recipe.AddIngredient(null, "card298", 1);
recipe.AddIngredient(null, "card299", 1);
recipe.AddIngredient(null, "card300", 1);
recipe.AddIngredient(null, "card391", 1);
recipe.AddIngredient(null, "card392", 1);
recipe.AddIngredient(null, "card393", 1);
recipe.AddIngredient(null, "card394", 1);
recipe.AddIngredient(null, "card395", 1);
recipe.AddIngredient(null, "card396", 1);
recipe.AddIngredient(null, "card397", 1);
recipe.AddIngredient(null, "card398", 1);
recipe.AddIngredient(null, "card399", 1);
recipe.AddIngredient(null, "card400", 1);
recipe.SetResult(this);
recipe.AddRecipe();
}

after i drop 25 of the items that worked for the 2nd file where it fail at "card196" in 3rd recipe

but it did not work on the first one it still gives error at "pack10" after i drop the item count to 15
[doublepost=1466580423,1466580386][/doublepost]
you can do more than 6 i know that

i am useing 10 items alot its the main number in all these and that never failed
[doublepost=1466580795][/doublepost]so after i remove the 3rd recipe like all of it it now still fails "pack10"

this is how it looked befor i added extra and this has worked for weeks
but now after i had that extra recipe in it now wont go back
for some reason it still fails at the top item "pack10"

public override void AddRecipes()
{
ModRecipe recipe = new ModRecipe(mod);
recipe.AddIngredient(null, "pack10", 1);
recipe.AddIngredient(null, "pack20", 1);
recipe.AddIngredient(null, "pack30", 1);
recipe.AddIngredient(null, "pack40", 1);
recipe.SetResult(this);
recipe.AddRecipe();
recipe = new ModRecipe(mod);
recipe.AddIngredient(null, "utype91", 1);
recipe.AddIngredient(null, "utype92", 1);
recipe.AddIngredient(null, "utype93", 1);
recipe.AddIngredient(null, "utype94", 1);
recipe.AddIngredient(null, "utype95", 1);
recipe.AddIngredient(null, "utype96", 1);
recipe.AddIngredient(null, "utype97", 1);
recipe.AddIngredient(null, "utype98", 1);
recipe.AddIngredient(null, "utype99", 1);
recipe.AddIngredient(null, "utype100", 1);
recipe.SetResult(this);
recipe.AddRecipe();
recipe = new ModRecipe(mod);
}
 
Whenever the projectile goes off screen, the game lags really hard until either the projectile ends or it returns to the screen :(
is there a way to fix this, or is my computer just bad.

I usually don't have lag problems

if all else fails, is there a way to make it only home on things on screen?
I'm afraid I don't have a clue why that would happen. I'd suggest that you try disabling portions of code with // until the frame issue doesn't happen anymore. Then you should see where the problem is.
 
I got an idea what you could add to Tmodloader
why not adding an Password Feature?
I mean it so,that you can give the Uploaded File,an Password,so that only People with the Password can download the mod?
that whould be making Mod Sharing in an Dev Team easier
 
I got an idea what you could add to Tmodloader
why not adding an Password Feature?
I mean it so,that you can give the Uploaded File,an Password,so that only People with the Password can download the mod?
that whould be making Mod Sharing in an Dev Team easier

Good in concept, but kinda useless in the end when there are already so many ways to share things.
 
Back
Top Bottom