tModLoader (WIP) Mod coding

Was this thread... (Please be honest)

  • Great Informative?

    Votes: 1 33.3%
  • Lesser Informative?

    Votes: 1 33.3%
  • Little to no Information?

    Votes: 0 0.0%
  • Seen way better?

    Votes: 0 0.0%
  • Not Informative at all? (meaning didn't helped you at all and was a waste of time)

    Votes: 0 0.0%
  • Don't wanna be rue so I wont pic one of those.

    Votes: 1 33.3%

  • Total voters
    3
Status
Not open for further replies.

Darkninja

Spazmatism
Hey guys, so... I know a lot of Mod makers or beginner mod makers have problems with coding.
I know what you are thinking, there's already coding tutorial threads, but this is more like the IDs of mods.
For example, item.useAnimation or projectile.aiStyle, they ( I mean some of them) don't know what to put for it. I know this because i did had problems with those.

So please comment all of the IDs you guys know and i'll do my best to put it all here.

[*]If you are using some recipe from vanilla Terraria you have to use Put using Terraria.ID at the top.
[*]To add a vanilla recipe put ItemID.(RecipeName) don't put the parenthesis. example recipe.AddIngredient(ItemID.DirtBlock);
[*]To add a Mod Recipe put (null, "RecipeName", Number); only put ,number if it's more than 1. example recipe.AddIngredient(null, "Example", 2);

WIP

WIP

WIP
Delete This thread Please !!!

 
Last edited:
First of all, the ItemID's can be found here (same story for the projectile aiStyles, which can be found here).
Other than that, I don't think you actually mean 'item.useAnimation' since this will only determine how long the animation should take to complete (item.useAnimation = 20 will result in an animation that takes 1/3 of a second to complete). You'll probably want item.useStyle to be specified:

useStyles:
1. General throw/swing animation (sword, throwing items, etc.).
2. Eating (potions and the sorts).
3. Stabbing (shortswords).
4. Holding item above head (some tomes and the sorts).
5. Holding item in front (mainly spears and some other items, I'm sure).

You also stated 'To add a Mod Recipe', which isn't really the fact. It's adding a mod item TO the recipe, which is why the function is called 'AddIngredient' instead of 'AddRecipe'. You also don't have to use ItemID. You can also just put in the integral IDs of the items (which will make it more difficult to read, but just wanted to notify you that there are more ways to go about this). This means you can do 'recipe.AddIngredient(ItemID.DirtBlock);' but also 'recipe.AddIngredient(2);'.
 
First of all, the ItemID's can be found here (same story for the projectile aiStyles, which can be found here).
Other than that, I don't think you actually mean 'item.useAnimation' since this will only determine how long the animation should take to complete (item.useAnimation = 20 will result in an animation that takes 1/3 of a second to complete). You'll probably want item.useStyle to be specified:

useStyles:
1. General throw/swing animation (sword, throwing items, etc.).
2. Eating (potions and the sorts).
3. Stabbing (shortswords).
4. Holding item above head (some tomes and the sorts).
5. Holding item in front (mainly spears and some other items, I'm sure).

You also stated 'To add a Mod Recipe', which isn't really the fact. It's adding a mod item TO the recipe, which is why the function is called 'AddIngredient' instead of 'AddRecipe'. You also don't have to use ItemID. You can also just put in the integral IDs of the items (which will make it more difficult to read, but just wanted to notify you that there are more ways to go about this). This means you can do 'recipe.AddIngredient(ItemID.DirtBlock);' but also 'recipe.AddIngredient(2);'.
wow i feel stupid
[DOUBLEPOST=1449423354,1449423166][/DOUBLEPOST]Please some moderator Delete this thread
 
If you want some moderator to delete this thread, you can look at the "Staff online now" and tag a moderator that is online atm. That's how I do it.

EDIT: Or you can report the OP and say that you want this thread deleted.
 
Last edited:
Status
Not open for further replies.
Back
Top Bottom