Page 1 of 1

WL2 csharp.dll play around

Posted: June 12th, 2018, 9:39 pm
by W2_player
A few simple hacks like increasing weight stats, increasing run speed, fast skill use, barter multiplier and unlock of level cap are funny and not need not profound skills. Al these are already discussed here few years before and easily done via justdecompile+reflexil.
Like Matthias said "Ive so many plans, so many..." So i had stuck the same at "I.." statement and.. but Cochise is not loading and showing a progress bar :twisted:
With reflexil i am unable to declare variables and by changing static arrays' size get private offsets ruined.
Tried to decompile a project and push it to VS 2015.
Alas, building results in a 10 thousand errors, and my baby steps are not enough for that. Why so many, what is missing, while the dll itself is running and ok ?
So maybe it is easier to use ildasm and ilasm to write directly in IL and be free to declare some simple thing like arrays, variables, access file, try to use available methods and code to do at least something ?
Also found some modifying guides on the net, but those are the same reflexil level cheat-hack.
Should i lean to ildasm and try to beat this dumb stack virtual machine or beat the VS and get the dll compiled back ?
I got that feeling of why no mods available. It is plain hard to do.

Re: WL2 csharp.dll play around

Posted: June 13th, 2018, 5:38 am
by Executor_
I used Reflexil initially too, but it had so many issues that I switched to dnSpy. I stopped using that too eventually as it had its own share of problems, particularly with nested types (although they might be fixed by now). Editing IL by hand is far too time-consuming.

Recompiling the DLL via Visual Studio is the only way to truly be productive. The trouble with all the various IL decompilers is that they tend to make a lot of mistakes, which need to be corrected meticulously. Particular sources of issues is code containing lambdas, LINQ, or delegates. Also, switch statements that involve strings, as those usually end up getting compiled into Dictionarys.

But it is possible. I managed to recompile the Assembly-CSharp.dll for BattleTech a mere handful of days after release, and that's a very recent game with WAY more decompile errors than WL2. I didn't actually intend to mod it, as it's in active development. It was just to see if I could. :ugeek:

Re: WL2 csharp.dll play around

Posted: June 13th, 2018, 7:32 pm
by W2_player
Found that dnspy's generated project bring more errors at VS2015 than JD+R, that still give 10K errors in build mode, and more in debug.
Had some fun witn ildasm and ilasm, these are able to decompile and compile back flawlessly, .il file have everything and looks sensible much closer to hardware and what is going on.