File structure for organization?

seth

aa
May 31, 2013
1,019
851
I find it kind of challenging to keep custom assets, project maps, and content packs organized efficiently. I keep project maps in Dropbox with their respective soundscape/particle files etc. Custom assets and content packs I've found a bit more difficult to deal with. I want to be able to check and see exactly what custom things I've downloaded and keep them kinda organized, so I would install the files in the tf directory and sym-link the assets to a folder on my desktop. That's kinda stupid though. Could I just put everything in the custom folder? How do you guys keep stuff together?
 

EArkham

Necromancer
aa
Aug 14, 2009
1,625
2,774
What I do is set up a folder specifically for the map I'm working on. For example, on pl_snowycoast, so the structure will be like the following (it was originally going to be called pl_outpost, so ignore the fact it's a different name):

  • tf/custom/pl_outpost/materials/metals/<various textures>
  • tf/custom/pl_outpost/materials/nature/<various textures>
  • tf/custom/pl_outpost/models/props_invader/<just the ones I used>

Etc.

Whatever stuff that's NOT standard content, I put in the appropriate /custom/pl_outpost/ folder. Even if I'm already using it in another map, I'll make a copy and move it to the /custom/pl_outpost/ to make organizing easier.

Then I use VIDE to pack up the custom stuff as outlined here.

This method has failed me once though -- pl_snowycoast_b1 is missing a model because I didn't realize it was custom content, so I didn't think to move it to the /custom/pl_snowycoast/ folder.

So really in the end, nothing beats out carefully planning what custom content you want to use, putting it in the map folder, and removing it if you decide not to use it.
 

A Boojum Snark

Toraipoddodezain Mazahabado
aa
Nov 2, 2007
4,775
7,670
Your symlink thing is basically doing the hard way what the tf\custom folder can do for you by default thanks to the steampipe search paths.
Make folders inside custom for each "bunch" of content, and within those place the materials/sounds/etc folders.

To keep things clean and easy, you shouldn't ever need to touch the stock tf content folders.
 

EArkham

Necromancer
aa
Aug 14, 2009
1,625
2,774
One thing I forgot to mention is that using /custom/ exclusively makes it easier to check if you packed everything correctly. After packing, but before you start TF2, rename /custom/ to something else (like /xcustom/), then load up your map, fly around and look for purple checks and ERROR models.
 

Freyja

aa
Jul 31, 2009
2,994
5,813
This video was jsut released and I find it almost eerily-perfect for this topic.

 
Last edited by a moderator:

seth

aa
May 31, 2013
1,019
851
ABS, I think that's what I'm gonna do. I do know about the custom folders' vast capabilities, but I just didn't really think about putting everything there. I'll see about moving everything over, thanks!

Aly, I literally checked TopHatt's videos yesterday to see if #23 had come out yet and it hadn't. How timely!
 

seth

aa
May 31, 2013
1,019
851
If anyone wants to know, I figured out what I wanted to do.

I decided not to contaminate my custom folder with hierarchies for all the custom assets I have, instead, I made a folder in Dropbox for them since they won't take up that much space and I'll install future assets there as well. I'm doing this because I'm also going to use TopHatt's scripts as seen in the video above and use Valve's resident content packer, bspzip instead of Vide or Pakrat. This will allow me to setup independent dev environments where scripts I've configured will create "pure" folders where stock files shipped with the game are placed. So when I'm working on a map, I enable my dev environment and all the stock files are moved out of harms way and another script pulls all the assets I'm using for the map into the "materials", "scripts" or whatever folder so I can see them in Hammer. Then, when I compile, I setup bspzip in the expert compiler to pack content named in a file list I created in Dropbox for a specific map, disable the dev environment so my tf directory goes back to default and I can check to see if everything packed correctly. So after the compile, my tf directory is untouched, and all my content and packing instructions for bspzip is stored in Dropbox and Hammer for future compiles. And I can setup map-specific content mirroring scripts or bspzip instructions for each map, so everything stays organized and out of my game directory.

Kind of long-winded, but I'm excited for how this will work out.
 
Last edited:

A Boojum Snark

Toraipoddodezain Mazahabado
aa
Nov 2, 2007
4,775
7,670
...what? I haven't watched the video so I'm not sure what the scripts do, but that sounds excessively complicated. Also... "contaminate"? That's kinda the only reason it is there... to fill with stuff.
 

seth

aa
May 31, 2013
1,019
851
...what? I haven't watched the video so I'm not sure what the scripts do, but that sounds excessively complicated. Also... "contaminate"? That's kinda the only reason it is there... to fill with stuff.

Sorry, I'm not very articulate. All I want is for everything to be organized and kept out of the game directory if possible. As I understand, plopping a bunch of new hierarchies in the custom folder will make map load times longer as the game will be searching through more directories for overlapping files. The way I have it now, all I have to do is execute a script to move source files from the maps, materials, scripts folders etc. into other folders it creates called maps_pure, materials_pure, scripts_pure etc. Then a 2nd script will drop all my custom content for a specific map into the now empty materials, scripts, sound folders etc., so Hammer can see all of it. When I go to compile, I create a new compile preset to use bspzip to pack up the custom content using a text file that lists all the content I use from my Dropbox. The content gets packed, I disable the dev environment so my tf directory gets reset back to a fresh install in case I need to test to be sure stuff is packed and to clean up the directory. This way, my custom folder is nice and neat for game-related stuff like class .cfg's and custom hitsounds, and my tf folder is just like stock. All my assets and packing instructions are left in Hammer and Dropbox. What's also nice is that I can obviously create separate packing instructions for each map so I can use the same Hammer compile preset across different maps and the correct stuff gets packed. And my instructions gets saved in Dropbox so I only have to set this up once per map when I get all of my custom content for it decided.

I hope that makes more sense that was even more wordy I'm stupid.

EDIT: finished up configuring the scripts and whatnot and it actually works. Pretty neat.
 
Last edited: