Jump to content

DMT Modding Tool


HAL9000

Recommended Posts

Thanks a lot for the info. Looks like a really great tool. Exactly what I'm looking for.

 

The latest version has an experimental option to try running the game in debug mode so you can hit breakpoints placed in dnSpy

 

K0OJDT7.png

 

Go to About->Experimental->Enable Debugger and then click the "Debug Exe" button. It will download a modded version of dnSpy and (fingers crossed) get debugging running

 

I've had mixed results, sometimes it works and others it crashes but if you're needing extra info about something not working right it's a good place to start.

Link to comment
Share on other sites

Hey, I'm currently doing debugging just with dnSpy. Does this offer any benefit over that?

 

No, either is good. It just handles swapping to the debug dll and starts the game through dnSpy so you can hit breakpoints. Just saves a few clicks and for those that don't want to start messing with the dlls

Link to comment
Share on other sites

Nice work Hal, I finally got the chance to try out A18 tonight and so far all my A17 SDX mods are working with this without any changes. Except my custom icons don't show up anymore, was there a change to how they work?

 

Make a folder structure like this: UIAtlases/ItemIconAtlas

 

The icon atlas is generated on game start up based on its contents. 160x160 is the new standard size, although 116x80 still works.

Link to comment
Share on other sites

I remember with SDX tool to mod a Dedi, you had to install a dedi on your PC, and build that way, then copy over the dll and mods folder, im assuming its the same way for DMT?

 

Yes. With DMT, you can add multiple build locations, so you can point to both the client and dedi and have them build.

 

The files are different though. Under Managed, you are looking for Assembly-CSharp.dll, Mods.dll, 0Harmony.dll, and DMT.dll, along with the traditional Mods folder.

 

I usually sort the Managed folder by Date modified, and grab them easily.

Link to comment
Share on other sites

Yes. With DMT, you can add multiple build locations, so you can point to both the client and dedi and have them build.

 

The files are different though. Under Managed, you are looking for Assembly-CSharp.dll, Mods.dll, 0Harmony.dll, and DMT.dll, along with the traditional Mods folder.

 

I usually sort the Managed folder by Date modified, and grab them easily.

 

 

Thats what I usually do as well.

 

Thanks for the swift reply. Love your mods and all the work you do!

Link to comment
Share on other sites

Really odd bug now after several hours of playing. My server crashed while I was playing and my game seems to be very borked since.

 

Server is fine, all players connect fine, but I cannot get onto my game at all.

 

I sign in with DMT and my game Immediately open a SP game... if I quit VIA the pause menu it goes directly to desktop.

 

uninstalled 2 times and retired still same thing.

Installed in new spot same thing.

Completely wiped all traces of 7dtd same thing

wiped via game launcher same thing

Uninstalled, DIDNT use DMT, and it works. Build with DMT, doesn't work.

 

It seems once adding the rebuilt assembly dll, i get the error, deleting, and verifying clears the error. But the issue is now, I can't get on my own server and all my players can....

 

No matter what I try I can't play with DMT.. All im using is Animal Husbandry, Bandits, Traders and NPCS and its 1 dependency.

Link to comment
Share on other sites

Really odd bug now after several hours of playing. My server crashed while I was playing and my game seems to be very borked since.

 

Server is fine, all players connect fine, but I cannot get onto my game at all.

 

I sign in with DMT and my game Immediately open a SP game... if I quit VIA the pause menu it goes directly to desktop.

 

uninstalled 2 times and retired still same thing.

Installed in new spot same thing.

Completely wiped all traces of 7dtd same thing

wiped via game launcher same thing

Uninstalled, DIDNT use DMT, and it works. Build with DMT, doesn't work.

 

It seems once adding the rebuilt assembly dll, i get the error, deleting, and verifying clears the error. But the issue is now, I can't get on my own server and all my players can....

 

No matter what I try I can't play with DMT.. All im using is Animal Husbandry, Bandits, Traders and NPCS and its 1 dependency.

 

Do you have Scroll Lock on, by any chance? 0-SphereIICore has a feature where, if your scroll lock is on, it'll load up your last save game.

Link to comment
Share on other sites

Do you have Scroll Lock on, by any chance? 0-SphereIICore has a feature where, if your scroll lock is on, it'll load up your last save game.

 

Im honestly not even sure how to turn that on/off

 

EDIT: nvm duh. that scroll lock.

 

EDIT again:

 

Dude.... I love you again.. Thank you so much. Spent almost 3 hours trying to figure out what is wrong... Never knew about that scroll lock feature.

Link to comment
Share on other sites

Im honestly not even sure how to turn that on/off

 

EDIT: nvm duh. that scroll lock.

 

EDIT again:

 

Dude.... I love you again.. Thank you so much. Spent almost 3 hours trying to figure out what is wrong... Never knew about that scroll lock feature.

 

I am sorry that it caused you grief. I use it as a shortcut when I'm doing a lot of testing. That's a feature of 0-SphereIICore, not DMT though.

Link to comment
Share on other sites

Are we supposed to have to reset game files every time we want to rebuild?

 

Bc I can't ever seem to rebuild. I always get the error

 

This Assembly-CSharp.dll file has already been patched by SDX so can not be used as a backup. Reset your game files and try again.

Build failed

 

process exited with error code -1

Link to comment
Share on other sites

Are we supposed to have to reset game files every time we want to rebuild?

 

Bc I can't ever seem to rebuild. I always get the error

 

When DMT first runs, it creates a backup folder, with the DLL in it. Each time you re-run the tool, it reads from this backup folder, and not your target folder. If the back up folder does not exist, it makes a copy of the target's folders DLL.

 

I'm guessing that something is happening to your back up, which is either getting removed, or an already-modified DLL is getting there.

Link to comment
Share on other sites

Is there anything else you need when trying to decompile the dll besides dnspy and the newest net core sdk? A little new and can't seem to figure out how to open the Assembly-CSharp.dll file with dnspy. dnspy does seem to compile by itself but doesn't look like the other dnspy i have seen in videos, meaning all it says on the top is dnspy and not dnspy v6.0.5. and whenever I drag and drop Assembly-CSharp.dll file into dnspy after it doesn't open the file.

Edited by rickyralph (see edit history)
Link to comment
Share on other sites

Is there anything else you need when trying to decompile the dll besides dnspy and the newest net core sdk? A little new and can't seem to figure out how to open the Assembly-CSharp.dll file with dnspy. dnspy does seem to compile by itself but doesn't look like the other dnspy i have seen in videos, meaning all it says on the top is dnspy and not dnspy v6.0.5. and whenever I drag and drop Assembly-CSharp.dll file into dnspy after it doesn't open the file.

 

Are you compiling from the repo? If you're in debug mode then drag and drop events don't fire through visual studio. Just download the dnSpy release from the GitHub page (or click the open icon and choose the dll that way)

Link to comment
Share on other sites

Are you compiling from the repo? If you're in debug mode then drag and drop events don't fire through visual studio. Just download the dnSpy release from the GitHub page (or click the open icon and choose the dll that way)

 

I am compiling dnspy from the repo on github. Through VS2019 I cloned https://github.com/0xd4d/dnSpy.git from the dnspy github wiki section. When I run the dnspy repo and try to drag and drop the dll file it doesn't open the file but rather it opens up a folder overview with the dll filke name and a sub folder showing version.

Link to comment
Share on other sites

can I use the modlets I have in and use this? I have a lot of them and I don't wont to give them up.

 

You can. DMT Launcher reads from a mod.xml, instead of ModInfo.xml. They won't show up in DMT to copy over unless you have a mod.xml, but you can manually copy them over into your target 7 Days to Die folder and the game will find them.

Link to comment
Share on other sites

So let me get this correct you don't need the mods folder inside the game folder. I atm have a Mods folder on my desktop and in the game folder but the dmt is set to the desktop one. And it works.

 

It depends on what kind of DMT mods you are applying. However, in most cases, the DMT mods will have to have an entry in the mods folder.

 

In addition to copying over the DMT mods' files into the Mods folder, it also modifies Assembly-CSharp.dll, and adds 0-Harmony.dll and DMT.dll. Once you've built DMT against a target, then you don't need to rebuild again unless the target changes, or you want to add more DMT mods.

Link to comment
Share on other sites

  • 3 weeks later...
Guest
This topic is now closed to further replies.
×
×
  • Create New...