NOTE: Please don't copy other people's code unless you have permission. Respect other people's wishes about distributing code. Copying code is plagiarism. This tutorial is only to teach you how to do it.
This is a bite-sized tutorial on how to decompile Terraria mods. If you want to replicate a certain effect that you saw in a mod of your own, you can decompile that mod. Here's how you can do it:
To obtain the .dll
file, we have to use a TML.Patcher, a 3rd party tool for decompiling mods. Here's how you can install and use it:
- Open Command Prompt.
- Run
dotnet tool install -g Tomat.TML.Patcher
to install it. - Run
tmlpatcher extract "Path/To/The/Mod.tmod"
to extract the mod file atPath/To/The/Mod.tmod
.