Standalone [1.3] tModLoader - A Modding API

Everybody

Terrarian
player. refers to the "player" file in terraria. since GlobalPlayer is not player it is refered to as "GlobalPlayer.".
however, you don't need to(you still can) say file name inside itself:
public override void Hurt (bool pvp, bool quiet, double damage, int hitDirection, bool crit)
{
for (int index1 = 3; index1 < 8 + player.extraAccessorySlots; ++index1)
{
if (player.reviveAngel = true)
{
if(player.reviveDebuff = false)
{
return false;
player.statLife += (player.statLifeMax * 0.3);
Main.NewText(player.name + " lives!", 0, 155, 55);
player.AddBuff(mod.BuffType("ReviveDebuff"), 18000);
}
}
}
}

to:

public override void Hurt (bool pvp, bool quiet, double damage, int hitDirection, bool crit)
{
for (int index1 = 3; index1 < 8 + player.extraAccessorySlots; ++index1)
{
if (reviveAngel = true)
{
if(reviveDebuff = false)
{
return false;
player.statLife += (player.statLifeMax * 0.3);
Main.NewText(player.name + " lives!", 0, 155, 55);
player.AddBuff(mod.BuffType("ReviveDebuff"), 18000);
}
}
}
}

also I asked for the line number because sometimes there are multiple errors, when one is fixed another may show up, that seemed likely here.
:( now a NEW error shows up. CS0266 line (60,27).
 

Pendromeda

Terrarian
? Most mod authors including me update their mods with tmodloader/terraria?
And I'm thankful for that. However, many mod makers have since moved on or stopped updating, like this RPG classes mod I enjoy. It will more than likely not survive the transition. Same with the Spirit mod, which I think the devs are having a hard time deciding whether to scrap it or not. it'd be hard to see these high quality mods be lost in the transition.
 

Quethed

Terrarian
And I'm thankful for that. However, many mod makers have since moved on or stopped updating, like this RPG classes mod I enjoy. It will more than likely not survive the transition. Same with the Spirit mod, which I think the devs are having a hard time deciding whether to scrap it or not. it'd be hard to see these high quality mods be lost in the transition.
oh, I thought it was just tremer...
 

Quethed

Terrarian
(I know I didn't do frames yet) help! it removes 2 from the inventory instead of 1
also, incase of possible confusion, how do you set it to only work while in reach
also I cant just use createTile because this will cover multiple items

for(int s=0;s<50;s++){
if(player.inventory.type==28){
if(WorldGen.PlaceTile(Player.tileTargetX, Player.tileTargetY, 13)){
player.inventory.stack--;
return true;
}
}
}

Got amount working by accedent
still need help with range
 
Last edited:

Maxoxpower

Terrarian
? Most mod authors including me update their mods with tmodloader/terraria?
is it hard to update a mod? :O

what happen if a mod autor won't update? i know thorium/antiaris/calamity and big major content will but ( i really want dead spirit mod to be updated and some smaller like wireless / gamble npc ) can't play without it :p )
 

Quethed

Terrarian
is it hard to update a mod? :O

what happen if a mod autor won't update? i know thorium/antiaris/calamity and big major content will but ( i really want dead spirit mod to be updated and some smaller like wireless / gamble npc ) can't play without it :p )
It is not hard, but it can be time consuming. mod authors discontinue their mods for:
gave up,
working on other mod (like the author of tremer),
quit terraria (most likely what happened to crystilium),
considers mod complete,
considers coding hard,
says they will come back but they don't,
physicly unable to continue,
quit terraria community,
author dead (in theory),
lack of time,
possibly other reasons.

You can even fall under multiple things on this list.
 
Last edited:
I've got a strange problem that keeps happening. After about 2-3 days, I'll load up the game and it will present me with the language select page again. After that my mods load and then my character is there but when I load up the world, it says something about world not loading (forgot what it says) then it lets me load the backup and then it just gives me the message
Index was outside the bounds of the array.
at Terraria.Player.Spawn()
at Terraria.WorldGen.do_playWorldCallBack(Object threadContext)
at Terraria.WorldGen.playWorldCallBack(Object threadContext)
What is happening? And how can I fix it?
 

Maxoxpower

Terrarian
It is not hard, but it can be time consuming. mod authors discontinue their mods for:
gave up,
working on other mod (like the author of tremer),
quit terraria (most likely what happened to crystilium),
considers mod complete,
considers coding hard,
says they will come back but they don't,
physicly unable to continue,
quit terraria community,
author dead (in theory),
lack of time,
possibly other reasons.

You can even fall under multiple things on this list.
i supose big mod like crystilium could came back just to update their mod and nothing else.... well..i guess...i hope :O
 

Quethed

Terrarian
i supose big mod like crystilium could came back just to update their mod and nothing else.... well..i guess...i hope :O
Graydee
Made Crystalium and Spirit mods.
I cant see when she was on last, but recent activity is blank.
because of the disappearance, crystalium and spirit took the blow. sure both have other devs but a big one for both is gone.
 

Maxoxpower

Terrarian
Graydee
Made Crystalium and Spirit mods.
I cant see when she was on last, but recent activity is blank.
because of the disappearance, crystalium and spirit took the blow. sure both have other devs but a big one for both is gone.
i just tell her about it and she just answer me with : potential yes about updating . they are hope i guess!
:)
 

Quethed

Terrarian
on discord of course!
???I have no idea what that is???
The answer is still good enough.
I would like to trade with the parent mod of slime biome. worldgen for textures.
(A big reason why I made slime biome is because I liked crystalium, and wanted my own biome mod)
(I am also trying to say that the world gen of crystalium is the most buggy and unstable ever)
 
Top Bottom