Let's all try and help each other with these Art 'Assets'

TheRealHellBlazer

Chieftain
Joined
Feb 26, 2017
Messages
59
So far I feel like I am trying to find a needle in a haystack blind folded and with both hands tied behind my back.

I can load models in to the FGX viewer and move them around, make them solid or wire frame. I can also load animations, but the animation only shows in the small box next to the file details and the loaded model just sits there.

The textures in the FGX viewer all seem to be just white when enabled and some form of grid when disabled.

As for the assets, well. I mean I have made some links to certain files but its a mystery mostly. I can open some .dds files in paint.net other say they are invalid .dds files!

I have no idea how to use or replace one of these .dds files. For example you can open the TER_Desert_B.dds file and change it, but how would I then replace the base game one.

As for the state graph, not a clue on that one!

I have noticed there are some new .artdef files in the ArtDefs folder for the base game. There used to be a Foliage.arfdef file and several others that now seem to all be in one file called Clutter.artdef which handles things like tress, jungle etc.

When using the Firetuner to place assets there is trees in there called Tree_C_Lg, Tree_A_Lg etc, so for a test I changed all the Pine tree entries in the clutter file with these trees and the game just stopped showing forests. They were in the game (tile yeilds prove this) yet there was no visual. So Firetuner seems to be able to place trees the base game cannot.

It appears the documentation for how to use the 'Assets' is rather on the light side.

I say 'Assets' because I am still dubious just how much of an asset it was to give up 27GB of hard drive space for something I can't really use.

And that is pretty much my experience so far, in summary, frustrating.

I mean I have made mods that add units, with new icons, unit models etc, but this stuff is just too frustrating.
 
Yes it is very frustrating and no doco that I can find so I am just clicking on things and running scripts to see what happens and it is usually not much.
I have tried creating a unit assets in asset maker but it crashes asset maker and then it can never be opened again unless I start a new mod.
I have managed to import a unit from .fbx but it was not usable due to the fact that there are no templates to work off so I have no ideas of scale position rotation etc.
Have tried to export civ6 units but NexusBuddy is not able to yet (hopefully Deliverator will save the day on this one).
FGX viewer is just a re-badged granny viewer that is only useful for viewing 3d files.
 
So after a lot and I mean a lot of playing around I finally got my head around the asset editor and modbuddy a little.

I edited the file Feature_Forest_Visible.dds in the textures folder of the pantry and saved it as HB_Forest_Visible.dds I basically made the trees in strategic view blue rather than green, not very useful but it is only for testing.

This is the result, https://goo.gl/J7cKfl

So basically you start a new mod and open the asset editor, this creates a fair few folders in the Modbuddy folder for your solution. Then in the asset editor you add a new artdef file from a template (it gives you them to choose from). You can then add the parts you need to that. You then have to new add a texture file, setting the source file your new .dds file. Then you create a new .xlp file linking the texture to your artdef file. The artdef file has a part you can select an entry from a BLP library, however you just use the new name of your texture set in the XLP file in this box as your BLP files are only created on the fly when you build the project.

The only problem I have found is modbuddy does not add the newly created BLP library to be loaded with your mod, even though it has a dependency library set, so I had to add this myself.

I set the project properties to have an action under FrontEnd and In-Game as UpdateArt and just set the (Mod Art Dependency File) on them both.

But as you can see I am finally getting some results.
 
Last edited:
Have tried to export civ6 units but NexusBuddy is not able to yet (hopefully Deliverator will save the day on this one).

The AssetEditor folder kindly contains very similar looking C# libraries for working with Granny Files to Civ 5. So an updated version of Nexus Buddy 2 for Civ 6 looks pretty do-able on the face of it. Not promising anything though at this stage!
 
Well turns out you can;t make a new asset, each time I try I set the name, the class and at this point you can save it, but the second you set the DSG and try to save it the asset editor crashes :(
 
Well turns out you can;t make a new asset, each time I try I set the name, the class and at this point you can save it, but the second you set the DSG and try to save it the asset editor crashes :(

Yes I have noticed this. You can edit the asset file with a text editor and remove the DSG entry and it will load again. I tried to add animation files and got crashes as well.

I have successfully import a unit.fbx file now of a civ 5 unit.
The included .fbx & .dds importer is rubbish and greatly reduces quality so after you import something you need to copy over the top of it with the original.

I think going forward most editing will be done outside of asset editor due to instability and will only be used to make templates to work from.

The AssetEditor folder kindly contains very similar looking C# libraries for working with Granny Files to Civ 5. So an updated version of Nexus Buddy 2 for Civ 6 looks pretty do-able on the face of it. Not promising anything though at this stage!
That would be awesome if you can.:) If you can't I understand, its very time consuming working on these things.
 
Oh wow. So all Civ 5 unit models work in Civ 6? Do they animate correctly?
I have not got that far yet all I have done is convert the art files to Civ 6 art files. I have not had a chance to test it in game yet due to the multitude of other files and things that are needed to be done and it does not help with asset editor crashing every few minutes.
 
Yes I have noticed this. You can edit the asset file with a text editor and remove the DSG entry and it will load again. I tried to add animation files and got crashes as well.

I have successfully import a unit.fbx file now of a civ 5 unit.
The included .fbx & .dds importer is rubbish and greatly reduces quality so after you import something you need to copy over the top of it with the original.

I think going forward most editing will be done outside of asset editor due to instability and will only be used to make templates to work from.


That would be awesome if you can.:) If you can't I understand, its very time consuming working on these things.

Well done Wolfdog, glad you are making some good progress, it would be much easier if the tools worked as intended huh!
 
I have not got that far yet all I have done is convert the art files to Civ 6 art files. I have not had a chance to test it in game yet due to the multitude of other files and things that are needed to be done and it does not help with asset editor crashing every few minutes.

It looks like the Asset Cooker can be kicked off from the command line or Python script too if that helps. But I haven't played with any of that stuff yet.

It does seem like getting a new unit model into the game is going to be even more complex than Civ 5 which is isn't a good sign. :(

Seeing any custom model in game would be encouraging - if someone can get that far - even if it isn't animated or anything.

That would be awesome if you can. :) If you can't I understand, its very time consuming working on these things.

I'll chip away at it when I have time. In a couple of hours I was able to re-hook the Nexus Buddy 2 code to the Civ 6 C# libraries and get the application to load in a .fgx file successfully which is the first hurdle.

There are two main challenges now:
1) The internal structure of the objects used for Model, Mesh, Skeleton, Bone etc is different between Civ 5 .gr2 and Civ 6 .fgx, but there's a chance I can crack that using a combination of decompiling the Firaxis code and the FGX Viewer. The goal of this would be a working .nb2 export for .fgx to get Civ 6 models into Blender.
2) The structure of Materials and Textures seems completely different so I'll need to work out how to make Materials and Texture mappings editable. This will be needed to make the remainder of Nexus Buddy 2 functionality work.
 
Last edited:
Nice. Reskins are go! Can you reskin a unit?

I have no idea yet, took quite a bit to get that working, some of it (or what was possible) I did in the asset editor, artdef, tex and XLP file and the mtl and ast I changed in Sublime. But I can't see why you could not reskin a unit. The dds files for unit skins look weird, like a flat mosaic. As the units are made of different assets, such as hat, armor, body etc I guess you can make a texture for each of them parts.
 
There are two main challenges now:
1) The internal structure of the objects used for Model, Mesh, Skeleton, Bone etc is different between Civ 5 .gr2 and Civ 6 .fgx, but there's a chance I can crack that using a combination of decompiling the Firaxis code and the FGX Viewer. The goal of this would be a working .nb2 export for .fgx to get Civ 6 models into Blender.
2) The structure of Materials and Textures seems completely different so I'll need to work out how to make Materials and Texture mappings editable. This will be needed to make the remainder of Nexus Buddy 2 functionality work.
Yes one thing I was having difficulty getting my head around was I could see how to import a mesh but it did not seem to import any of the skeleton data. It looks like each mesh for a model has to be a separate .fgx file with .geo file that goes with it. Each animation file requires a .anm file to be generated so its not as simple as renaming all your animation .gr2 files to .fgx unfortunately. Material files look like they need extra light maps and things but I am hoping they are not mandatory.
 
Yes one thing I was having difficulty getting my head around was I could see how to import a mesh but it did not seem to import any of the skeleton data. It looks like each mesh for a model has to be a separate .fgx file with .geo file that goes with it. Each animation file requires a .anm file to be generated so its not as simple as renaming all your animation .gr2 files to .fgx unfortunately. Material files look like they need extra light maps and things but I am hoping they are not mandatory.

Yeah as you say there is a geo and an fgx with each. As for the material files, since I have done quite some work on the so far, I have noticed you have things like filename_B, filename_G, filename_M, filename_N, filename_H, where filename is the name of the item in question. They are all .dds files but paint.net cannot open most of them, the _B is for base colour and this one can be edited in paint.net the other _G = gloss, _M = metalness, _N = Normal and _H = Height map.

Now I think, and this is just an assumption that the others are more for data than for texture, not sure why they are in .dds format and not sure if / when firaxis will give us anything to open them with. Also not ALL material files have all the letters, some don't have the _G, some don't have the _N etc, you get the picture.
 
Yeah as you say there is a geo and an fgx with each. As for the material files, since I have done quite some work on the so far, I have noticed you have things like filename_B, filename_G, filename_M, filename_N, filename_H, where filename is the name of the item in question. They are all .dds files but paint.net cannot open most of them, the _B is for base colour and this one can be edited in paint.net the other _G = gloss, _M = metalness, _N = Normal and _H = Height map.

Now I think, and this is just an assumption that the others are more for data than for texture, not sure why they are in .dds format and not sure if / when firaxis will give us anything to open them with. Also not ALL material files have all the letters, some don't have the _G, some don't have the _N etc, you get the picture.

All the .dds files will be images including Gloss and Normal maps etc. A couple of good overviews of map types here and here. With Civ 5 most community made units just set the Base/Diffuse map and just set the Gloss maps to all black. With Civ 4 Gloss and Normal map texture .dds files could be opened and edited with Paint.NET just fine.

Salec mentioned on Discord that he would ask the "engine guys" why some textures could be viewed/opened.
 
Hi. I'm new here. I modded other games (well, only texture and art related things, I suck at coding) and I was very excited for the SDK release because I want to make a resource mod. I already have the dds retexturized, but the awful asset editor and mod buddy gives me a headache. If anyone could help me with coding, I can help him/her with textures and icons.
 
Hey!
Awesome to have this information out already, and the discord -chat log gives much hope for future!
I just downloaded the SDK&assets, and did some quick testing on textures (as that's what I'm most interested in changing) for a couple of hours.

Looks like the _B.dds base colormap-textures are in a more straightforward (similar to usual .png, .tga etc) DXT (DirectX Texture) -format, "R8G8B8A8_UNORM" (you can see the format by opening the .tex -files with AssetEditor, and under Export Settings: Pixel Format), which has 4 channels (RGB and alpha), 8bits per channel, that can be read easily by programs with at least basic DXTexture support.
However the _G, _M, _F (is for "fuzz" map) etc. maps seem to be in a R8_UNORM -format, where there is only a single 8 bit red channel (probably for reasons of optimization, less space, simpler rendering) - and I'm guessing here, but I suspect that file viewer programs have to implement the details of each DXT-format separately (just 5 formats, but looks like they can contain data in >100 different ways).

I tried unpacking the R8 -files with Nvidia's dds-utilities, that contain a readdxt.exe, but while it did unpack it in to a .tga, but all of the resulting files channels are pure black. Fastpictureviewer looks to be able to display the R8-images, but even it shows the images in a rather strange style (not talking about the mipmaps).

So, I'm currently at a loss on how to decompress/convert the R8 .dds -files to any usable format, but I'd imagine packing said files from new textures wouldn't be a problem, as long as a suitable DXT -compressor and settings are setup (I'd imagine the nvidia dds-utilities' compressor might support the format, even if the readdxt.exe did not) - unless all of this is done by the AssetEditor, or some other tool that might be included in the SDK.

Who wouldn't love to pick the brains of the graphics programmer(s) or pipeline/tool technical artist of Firaxis for a few hours?

--edit:
Argh, right after posting this, I went back to re-read the discord -log again, and indeed: "The .tex files get created automatically by the asset editor. It's used to specify how the textures get processed. The cooking/building process may compress the textures or do things with em based on what context the texture is being used." - so looks like the AssetEditor will handle creating the .dds's, as long as proper bitmaps and .tex metadata files are input.
 
Last edited:
Hey!
Awesome to have this information out already, and the discord -chat log gives much hope for future!
I just downloaded the SDK&assets, and did some quick testing on textures (as that's what I'm most interested in changing) for a couple of hours.

Looks like the _B.dds base colormap-textures are in a more straightforward (similar to usual .png, .tga etc) DXT (DirectX Texture) -format, "R8G8B8A8_UNORM" (you can see the format by opening the .tex -files with AssetEditor, and under Export Settings: Pixel Format), which has 4 channels (RGB and alpha), 8bits per channel, that can be read easily by programs with at least basic DXTexture support.
However the _G, _M, _F (is for "fuzz" map) etc. maps seem to be in a R8_UNORM -format, where there is only a single 8 bit red channel (probably for reasons of optimization, less space, simpler rendering) - and I'm guessing here, but I suspect that file viewer programs have to implement the details of each DXT-format separately (just 5 formats, but looks like they can contain data in >100 different ways).

I tried unpacking the R8 -files with Nvidia's dds-utilities, that contain a readdxt.exe, but while it did unpack it in to a .tga, but all of the resulting files channels are pure black. Fastpictureviewer looks to be able to display the R8-images, but even it shows the images in a rather strange style (not talking about the mipmaps).

So, I'm currently at a loss on how to decompress/convert the R8 .dds -files to any usable format, but I'd imagine packing said files from new textures wouldn't be a problem, as long as a suitable DXT -compressor and settings are setup (I'd imagine the nvidia dds-utilities' compressor might support the format, even if the readdxt.exe did not) - unless all of this is done by the AssetEditor, or some other tool that might be included in the SDK.

Who wouldn't love to pick the brains of the graphics programmer(s) or pipeline/tool technical artist of Firaxis for a few hours?

--edit:
Argh, right after posting this, I went back to re-read the discord -log again, and indeed: "The .tex files get created automatically by the asset editor. It's used to specify how the textures get processed. The cooking/building process may compress the textures or do things with em based on what context the texture is being used." - so looks like the AssetEditor will handle creating the .dds's, as long as proper bitmaps and .tex metadata files are input.

I have been on this for the past 2/3 days now, the R8_UNORM seems not to be an 'official' DDS format. If you download the DXSDK from Microsoft you will get a right click context menu option on the DDS files to convert them to any other format. GIMP does open them any way without converting them. Like you it seems to be that they use the red channel.

I have been working on the Heightmap for the Hill_Element to make hills look different. The problem is you cannot save or convert a DDS to R8, so I have managed to do it by saving a file as an A8 file and use the Alpha channel for the data. Basically the _H file I opened n gimp for hills is a greyscale Gaussian blurred image. It is blurred to add smoothness to the hills, and black (0) is the low points (dips) in hills and white is the peaks (tops) of hills.

I am assuming what ever program was used to create the hightmap dds files made them use the red channel.

I have a mod that I can use that changes the look of hills now and they have to be a repeatable file type, the top has to match the bottom and left has to match the right for seemlessness in the game. If they don't you can see where the 512 x 512 tiles are layered under the terrain.
 
Top Bottom