Standalone [1.3] tModLoader - A Modding API

-Added clientClone, SyncPlayer, and SendClientChanges hooks for ModPlayer
Hello, does someone have a good example of how to use these hooks? The example mod doesn't have one, and I can't figure it out by myself. I just want to synchronize a pair of bools between clients.
 
I got this error. I have never seen it before. All I did was try to generate a world.

upload_2017-3-30_23-56-21.png
 
If I want my weapon to fire projectiles like Star Wrath, but instead all projectiles will be travelling in a straight line, what code should I use?
 
If I want my weapon to fire projectiles like Star Wrath, but instead all projectiles will be travelling in a straight line, what code should I use?
It'd be the same as the Star Wrath, but without the random spread code in it.

EDIT: Go to the discord @fanofsiN. It's easier to talk there.
 
Last edited:
Also, a reminder to those asking more involved questions, please come to the Discord channel, it's hard to talk you through hard things in forum posts.
Oop! Sorry about that. Didn't even know that was a thing. Thank you so much for all the help. I'll be on the discord (hopefully) from now on.

My server's named 'Fortune Mod'.
 
Last edited:
c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(12,14) : error CS1597: Semicolon after method or accessor block is not valid

c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(15,1) : error CS1022: Type or namespace definition, or end-of-file expected

c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(16,4) : error CS0116: A namespace cannot directly contain members such as fields or methods

c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(30,3) : error CS1022: Type or namespace definition, or end-of-file expected
 
Yeah, I tried again and it worked.
I honestly wanna know what caused the error
I dunno. It's the runtime error log, and it says another process had the file open. Maybe it was trying to log 2 things at the same time and it couldn't. I'd check that log file and see if you can figure out if a mod is having problems.
 
c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(12,14) : error CS1597: Semicolon after method or accessor block is not valid

c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(15,1) : error CS1022: Type or namespace definition, or end-of-file expected

c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(16,4) : error CS0116: A namespace cannot directly contain members such as fields or methods

c:\Users\Owner\Documents\My Games\Terraria\ModLoader\Mod Sources\TestMod\Items\BasicKnife.cs(30,3) : error CS1022: Type or namespace definition, or end-of-file expected
These are all syntax errors. Also providing just error logs without your code isn't any useful. Anyhow, inspect lines: 12,15,16 and 30.
[doublepost=1490951532,1490951485][/doublepost]
so appperently this is giving me a virus. PLEASE fix this!
AV programs have caused false positives before. You have my word that tML itself does not contain a virus.
 
Say Jofairden, which one is the random spread code in the projectile codes of Star Wrath? Because I want them to go straight.
BTW I don't know how to make the weapon have the sound effect when using the Terra Blade, so what's the code for that?
 
Last edited:
Say Jofairden, which one is the random spread code in the projectile codes of Star Wrath? Because I want them to go straight.
I don't really understand your question. If you want Star Wrath's code you'll need to decompile Terraria and look in its respective AI code.
 
I don't really understand your question. If you want Star Wrath's code you'll need to decompile Terraria and look in its respective AI code.
Well what I mean is, I'm making weapon that shoots projectiles like Star Wrath, but I want the projectiles to be in one straight lines raining down from above and can go through blocks.
 
Last edited:
These are all syntax errors. Also providing just error logs without your code isn't any useful. Anyhow, inspect lines: 12,15,16 and 30.
[doublepost=1490951532,1490951485][/doublepost]
AV programs have caused false positives before. You have my word that tML itself does not contain a virus.
how do I fix this? can I turn off my anti-virus?
 
Back
Top Bottom