How to edit Assembly-CSharp.dll/Make a hack
Requirements:
1. DotNetResolver (Google it)
2. Unturned
1. DotNetResolver (Google it)
2. Unturned
Theory:
So we'll be editing Assembly-CSharp that contains most of the Unturned Game info. We'll first use DotNetResolver to decompile Assembly-CSharp and then change all kinds of information inside of it. After that we'll recompile it again and launch the game!We'll be making No Recoil!
All the other hacks are almost the same to make but just in other location inside the dll. I can always expand this tutorial.
Sounds easy right?
Well, it is easy ;D
Tutorial
1. Open up DotNetResolver and press File and then press Open. Navigate to the Unturned Game File Location.
DotNetResolver->File->Open
"C:\Program Files (x86)\Steam\SteamApps\common\Unturned\Unturned_Dat a\Managed"

2. Open Assembly-CSharp.dll and Open Assembly-CSharp "DropDown" Box. Then click on the {} Icon and then go to GunStats. Then open up Gunstats and Navigate to getRecoil_Y.


3.Change The top DropDown box to Visual Basic in order to make the decompiler source way easier to read. Then click on the MSIL Editor Tab on the right of the splitter.


4. If the operand show Hexidecimals and not just normal decimals go to Tools->Settings->Decompiler and uncheck Use Hex Numbers. Then Select everything in the MSIL Editor from the first line to the third of last line. and right click and click on NOP Instructions.



5. Go back to Decompiler and take a look at the source. It should look like this

if it does then go to File->Save and save it in the same location Assembly-CSharp.dll is being located in right now and overwrite it.

Now start up Unturned and voíla. You've got yourself a No Recoil Hack!
A Thanks is appriciated!
Last edited by xCyberxx; 07-17-2014 at 07:45 PM.


Looking at god mode/inf food etc in the hacked assembly's, the IL_0000 offsets are different from each other, and I have no clue how to change them to make the hack on the default IL_0000 offsets. E.G default offset I need to change (IL_0002) to the one thats from the hacked one (IL_0006)