GDRETools / gdsdecomp

Godot reverse engineering tools
MIT License
1.63k stars 151 forks source link

[Feature Request] - support for decompiling CSharp scripts #67

Open mkisX4 opened 2 years ago

mkisX4 commented 2 years ago

In a process of recovering some of my oldest projects I stumbled upon an interesting "bug" — gdsdecomp doesn't know what to do with .cs files and leaves it empty. Tried full recovery with .8 and .9, both hadn't succeded.

Would be cool if there'd be a way to restore them as well.

char-ptr commented 2 years ago

as a temporary workaround, you can decompile il bytecode with a tool like dnspy or ilspy. you can find the assemblies in /.mono/assemblies//*.dll

nikitalita commented 2 years ago

What pozm said. Ilspy, dnspy, or dotpeek are all great solutions to this. I don't have much experience with godot mono, so I'm reticent to add any C# decomp features to this, but I will welcome any PRs.

Robocraft999 commented 2 months ago

as a temporary workaround, you can decompile il bytecode with a tool like dnspy or ilspy. you can find the assemblies in /.mono/assemblies//*.dll

How would I do that with ilspy? There is no .mono folder in the folder I exported (recovered) to. In the folder with the compiled game there is also no .mono folder just a data_*_windows_x86_64. This one does contain a *.dll but this doesn't seem to be working if I open it with ilspy. i'm using Godot 4.3 (also gdre_export.log says to open with 4.3), but I can't figure out how to decompile the .cs files. The overall Project seems to be working to decompile as far as I can tell.