Graphics - TEX "Hello World"

I’m still trying to push a “Hello World” example for each content type, but I should probably release them sequentially instead of waiting for them all to be done.

Here is a tutorial for exporting and modifying TEX files, then making those changes live in the game. I’ll do a separate post for importing data.

If you have not done so yet, you need to do chapter 1 from the tutorial in order to have the necessary files. AssetManager -> Tools -> Extract Game Files. This will extract to the working directory. I will try to start fresh and do this again as a complete tutorial in another post, but basically you need a “mods” folder.
You can look at 3d versions of resources with Viewer.exe, and 2d with TexViewer.exe. Make some backups of files. You probably won’t, but you will wish you did.

Open TexViewer.exe, open a FILE_dif.tex (Look inside: C:\Program Files (x86)\Steam\steamapps\common\Grim Dawn\mods\YOURMODNAME\resources\creatures\pc to start, but if you haven’t created a mod yet then you won’t see your changes made. )
and then Save As -> BMP.
Open the FILE_dif.bmp in paint.
Perform some graffiti to make sure this is the right file.
Flip horizontal (probably on the image menu, YMMV)
Save in MSPaint.

C:\Program Files (x86)\Steam\steamapps\common\Grim Dawn\mods\YOURMODNAME\resources\creatures\pc>..\..\..\..\..\TextureCompiler.exe heroine00_spc.bmp heroine00_spc.tex -format tex
OR (if you're working on the base extracted files)
C:\Program Files (x86)\Steam\steamapps\common\Grim Dawn\resources\creatures\pc>..\..\..\TextureCompiler.exe heroine00_dif.bmp heroine00_dif.tex -format tex 

Run AssetManager.exe
Build -> Build

Load the game, this is not the “main campaign” but the name of your mod. Select YOURMODNAME and create a new character. I altered the heroine model, so I can see those changes immediately after removing the armor.

All that done, I feel really silly with hours of my texture and MSH research, since AssetManager can import textures in 5 formats, and directly from PSD files. 3D Studio Max files are imported to create the MSH files. Will post separately.

Here are some images showing the results in TexViewer and in game. (Yes, it ended up being the armpit.)

Wait how do you convert to .tex? Do I have to do cmd command lines for every file?

Managed to find my way in, but now what?

yep, see the code segment he posted

although you could make a little batch program to do all .bmp files in a folder

or maybe post 7 from here

You can use the TEX conversion files from TQ, there is a good one called TQCompiler by Tamschi (i think that was his name, sorry!) and that app will convert the tex files into DDS. You can edit them in Photoshop, then save them as TGA or PSD. TGA in my experience is far better for importing into Asset/Art Manager, for some reason PSD will have an error occasionally but TGA works perfectly. I batch imported about 300 bitmap files the other day, and out of those I got 2 that didn’t properly import.

That was incredibly simple, thanks for the link

Where do we put the file in order to build it into our mod? What is the correct file path under our mod folder?

“it depends”. This example used “resources\creatures\pc” and my Stasher mod to make the stash bigger used “resources\ui\caravan” but if you build the Asset into your Archive, then you can pick a path for your dbr files to load it.

tl;dr = Replace art in a matching folder. Add new art anywhere.

I did everything correctly but it says my tex file is invalid and I can’t open it in TexViewer either. I noticed that when I clicked auto create asset, the tex file created is only 1kb even though my tga file is originally 400kb.

That’s why I ended up using the command line

I wanted to modify some textures, but I don’t have photoshop and paint is quite limited in what I can do with it, so I found out a fine little program and a work process that allows me to import files with certainty, albeit a little slow. Easy2Convert BMP to TGA.

Now, if I want to edit a texture I do this.

  1. Open texture with TexViewer. Save as… texture.Jpg*

  2. I go to

  3. Image->Flip Canvas Vertical

  4. Draw silly things

5)Save as… file.bmp

  1. Run Easy2Convert BMP to TGA. Press button.

  2. Import modified .tga file in asset manager, and auto-create asset. At this point your .tex is usable.

  • pixlr only recognizes the .jpg of the Texviewer, and Asset Manager doesn’t recognize the .bmp of pixlr, so I unfortunately have to go:

[Easy2Convert BMp to TGA].BMP->.tga
[Asset Manager].tga->.tex

Some sloppy examples:

Manticore Texture, Modification:p

Stock Manticore, Modified Manticore

PNG is a better format, because it includes transparency layers and doesn’t make things blurry with lossy compression. BMP I used because it preserves everything except transparency. You should be able to use TGA, JPG, PNG or BMP, but PNG or TGA will be best. Harder to find TGA editors as you well know.

So out of curiosity, would I be able to some transfer let’s say Captain Bourbon’s textures and replace those of the player character, which would then make my character look like Captain Bourbon?

The player character texture is different from the npcs. The npc textures are just the head so some heavy texture editing of the player texture would be required. Since the npcs also have a different shaped head, the editing would need to factor that also.
It will be much easier modding once the model export tools are released. Anyone could then just swap out the head on the actual player model.

TIL Manticores are ugly as hell up close.

Thanks for this!

Ahh I see. Well then, that makes sense. Thanks for the heads up. Yeah I was looking into the textures for the different npcs and of the pc and definitely noticed the differences.

You can swap out the textures, but they are flattened out versions of your character, which is then wrapped around the mesh. The geometry of each mesh changes the “seams” on the texture.

Have a look at, you can work with .tga, .bmp. .jpg, .png, and many more.