Jump to content
The Dark Mod Forums

is it possible to use unpacked pk4 content?


Recommended Posts

It used to be possible (at least up to some 4 years ago, last time I was around here), but now it doesn't seem to work. I keep having to pack stuff into the pk4s every time I change a custom texture or model or else DR and TDM don't see the changes, and that's quite a bit annoying and unwieldy. More so because it forces me to shut down the game and DR before packing, because they seem to lock the pk4s while running and 7z goes kaput if I try to use them while locked.

 

Is it still possible to do?

Edited by Skaruts

My FMs: By The Cookbook

Link to comment
Share on other sites

Are you trying to modify the existing core PK4's? I haven't tried to alter them directly but if you're working out of your own FM project directory you wont need to compress it. However I'd imagine altering the official PK4 would be very problematic. Mainly considering that they will be overwritten with any update that comes later.

Modeler galore & co-authors literally everything

 

 

Link to comment
Share on other sites

Its possible only if you use the same filestructure like in the pk4.

Move the content from the pk4, outside the pk4.

Or copy the files from the pk4 and delete the pk4.

Its not wise to edit files "inside" the pk4. move it outside the pk4, edit the file and move it to the pk4.

 

Tip:

use totalcommander.

Also when you quickedit files "inside" the pk4.

Edited by freyk

Info: My portfolio and darkmod graphical installer
Amnesty for Bikerdude!

Link to comment
Share on other sites

If I delete the pk4 and just keep the folder with its content it doesn't work. DR doesn't detect any of it.

 

I'm keeping the folder (in this case tdm_models01) in my darkmod folder, right next to the prefabs folder. Also tried renaming the folder to have the .pk4 extension itself, but also didn't work. Same results for the tdm_textures_base01 folder.

 

I'm not trying to change any of the game's files, I'm doing a custom texture/material and a custom model, but the only way DR and TDM seem to recognize that they exist is if I pack them into the pk4...

 

 

Or maybe I don't have to put them in a folder with the name of the pk4? Hmm.. gonna try that.

Edited by Skaruts

My FMs: By The Cookbook

Link to comment
Share on other sites

Or maybe I don't have to put them in a folder with the name of the pk4? Hmm.. gonna try that.

Well, that worked. So that was my mistake, I was unpacking everything into folders with the name of the pk4s, but it's the folders inside them that have to be in the darkmod folder.

 

No need to delete the pk4 though. Whatever is in the folders seems to override them.

 

Tip:

use totalcommander.

Also when you quickedit files "inside" the pk4.

Thanks. That'll be useful indeed. Edited by Skaruts

My FMs: By The Cookbook

Link to comment
Share on other sites

You don't need to modify the contents of pk4 files at all, even if you want to change something. Pk4s are just zips, and they all contain a directory structure of a game. You need to set up a project folder (fms/myfmname) and set t in DR project settings. Now inside that folder you need to mimic the directory structure found in pk4s. If you want to modify stock TDM resources, you need to unzip it and place it in the same directory structure inside your project folder, and then modify the asset. You don't need to put it back into base pk4. When you use project folder, game will recognize your new assets and stock TDM assets you try to modify, and will use your version instead of stock version. It's much cleaner and safer this way.

Link to comment
Share on other sites

It may be useful to know the priorities TDM uses: files as they are inside the pk4 are overwritten by changes made to extracted files in the same folder (but they need the same folder stucture found inside the pk4 files, as you already found out). These files, in turn, are overwritten by files in the folder you have set as your project folder as described by Judith. Make sure that TDM is set up correctly, as this is the most common reason people have problems with missing /not updated assets. I just noticed that the setup described on the Wiki is still from a previous version, so I will change it this evening.

  • Like 1
Link to comment
Share on other sites

Also, a major downside of modifying stock content inside pk4s is that all other missions will be using it as default. AFAIK, you could use the game directory structure in TDM main folder, the game will read both unpacked content and stuff zipped in pk4s. In fact, you can unzip all pk4s in root TDM directory and the game will read it correctly. But, in case of any updates, the updater will notice missing pk4s and will start downloading them again.

 

All in all, using project folders is less complicated or error-prone, and you can always copy assets from stock pk4s to modify them for your mission.

  • Like 1
Link to comment
Share on other sites

That's all good to know. I myself though it would be better to just extract whatever single files I needed. Extracting all the pk4s would take too long, and I generally prefer keeping the integrity of the original files intact.

 

I modified some editor "tool textures" to be translucent (clips, nodraw, visportal, etc), which I had tried a long time ago and failed, so I'm only overriding those. I also created a new one for sealing brushes behind modules, that stands out more among everything else, so it's easier to spot gaps between geometry and models. I'm also mocking about with 3D models, but none of this is project specific.

My FMs: By The Cookbook

Link to comment
Share on other sites

Why did you not just use filters in DR? With these you can hide textures, so they won't bother you while working. Much less work than the replacing all the textures... You can even define new filters for stuff (models, entities, textures, etc) that are not contained in the basic filter set. The only downside is that you have to remember to turn them on, as soon as you move brushes that use these textures.

For sealing brushes behind models, I usually use the caulk texture. This is sealing, invisible in the game, and the magenta colour makes it hard to miss, while searching for gaps.

Link to comment
Share on other sites

On one hand it's down to habituation, as I used to make some mapping on the Source engine and you have transparent tool textures there, but it's also quite annoying to me when, for example, I'm covering a bunch of props with monster clips, and it starts getting hard to travel around the map and see where is what. Filtering off monster clips at that point might make me forget where I already placed some of them.

 

On the other hand I'm also a bit averse to having to access menus for things I can have to use frequently.

 

It's also useful for studying other people's maps, though:

 

(me studying Melan's Fauchard map with some experimental textures on)

i3JVm4Y.png

Edited by Skaruts
  • Like 1

My FMs: By The Cookbook

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • The Black Arrow

      Hope everyone has the blessing of undying motivation for "The Dark Mod 15th Anniversary Contest". Can't wait to see the many magnificent missions you all may have planned. Good luck, with an Ace!
      · 0 replies
    • Ansome

      Finally got my PC back from the shop after my SSD got corrupted a week ago and damaged my motherboard. Scary stuff, but thank goodness it happened right after two months of FM development instead of wiping all my work before I could release it. New SSD, repaired Motherboard and BIOS, and we're ready to start working on my second FM with some added version control in the cloud just to be safe!
      · 2 replies
    • Petike the Taffer  »  DeTeEff

      I've updated the articles for your FMs and your author category at the wiki. Your newer nickname (DeTeEff) now comes first, and the one in parentheses is your older nickname (Fieldmedic). Just to avoid confusing people who played your FMs years ago and remember your older nickname. I've added a wiki article for your latest FM, Who Watches the Watcher?, as part of my current updating efforts. Unless I overlooked something, you have five different FMs so far.
      · 0 replies
    • Petike the Taffer

      I've finally managed to log in to The Dark Mod Wiki. I'm back in the saddle and before the holidays start in full, I'll be adding a few new FM articles and doing other updates. Written in Stone is already done.
      · 4 replies
    • nbohr1more

      TDM 15th Anniversary Contest is now active! Please declare your participation: https://forums.thedarkmod.com/index.php?/topic/22413-the-dark-mod-15th-anniversary-contest-entry-thread/
       
      · 0 replies
×
×
  • Create New...