Recycling in game art for a Building [RESOLVED}

Sostratus

Deity
Joined
Jul 31, 2017
Messages
2,400
Location
Minnesota, USA
Hello fellow fanatics. I realize Art can get a bit complex.

I've read the Beginner's Guide to Art Assets by esosorcdc, and followed it along until adding custom textures.
In it he goes through importing art from civ6 to blender, exporting, the whole deal.
However, there's a big section on texturing etc.

If I only seek to wholesale use an existing building's art, is there a much cleaner method?
I am seeking to reuse the factory as it is in game for a building which replaces the factory.

He mentions, from the standpoint of editing a base game building,
-a building asset file. In this case I have DIS_PRD_Factory.ast.
-A building base file. I'm not sure if this is it, but DIS_PRD_Industrial_Base_03Factory_.ast is my best guess.

Then there's a few things that he imports from civ_nexus6. namely, material and texture files, and obstruction files. But I've no clue how to just use what's already there. (I understand, from his guide, that i can use the .fgx in the SDK pantry already, and I can get the geometryset file from civ nexus 6 from the base files too.)
Then, the .xlp's and ArtDefs.
hero_buildings and tilebases I get, those would use the existing files. But again, materials, textures, etc- are these just being inferred if you don't set them?

Is there a simpler guide or something similar of the few things to tweak to totally recycle an in game asset like this?
 
If you want to re-use existing art then you only have to replicate the relevant .artdef entries with your new game entity name (e.g. BUILDING_MY_LOVELY_HOUSE). That way your are re-using base game 3D assets that have already been cooked into BLP (Binary Library Package) files and are included with the game.

You don't have to re-cook the assets, or get into editing them unless you want something to look different. If you do the all the asset entities (Assets .ast, Geometries .geo, Materials .mtl, Textures .tex, Animations .anm, etc) in the pantry (SDK Assets) can be used as if they were part of your mod.

You may want to use Sukritact's Artdef Editor rather than the Asset Editor which can be a bit clunky and long-winded in comparison.

The guide you mention is really a guide for import new custom 3D building made with Blender although there is useful general info there too.

This diagram for the architectural overview here might be helpful:
civ-6-graphical-asset-erd-page-1-png.476216
 
You may want to use Sukritact's Artdef Editor rather than the Asset Editor which can be a bit clunky and long-winded in comparison.
This program looks very handy, even for just telling me what the referenced files are.
Is there a readme / manual on it? Do I just use it to open and edit an existing artdef file?
 
This program looks very handy, even for just telling me what the referenced files are.
Is there a readme / manual on it? Do I just use it to open and edit an existing artdef file?

No manual AFAIK, it is just @sukritact's own tool that he has shared. You can open and edit an existing .artdef file, yes.
 
If you want to re-use existing art then you only have to replicate the relevant .artdef entries with your new game entity name
Edit: to clarify, the ArtDef.log is showing that it loads my mod's artdef file. But it isn't having an effect in game.

Okay, been playing around with this:
It looks like the base game ArtDefs, and the ones found in various mods/ modbuddy templates, are essentially just the same thing except the elements in m_rootcollections are limited to whatever the mod is providing.
So for a unit, it would just be one entry in m_rootcollections where for example, everything is the same as the base file except at the bottom of the element m_name=UNIT_WARRIOR would become UNIT_MY_CUSTOM_UNIT. Your Steel & Thunder mod seems to do this too (albeit possibly some extra stuff for animations.)
For buildings that go in districts it looks the same except there's an element towards the end with a collection name of "buildingchains" that defines what's the district, level 1, level 2, etc.
So for a unit would my artdef be:
<That version and header stuff all these files have>
<Rootcollections containing the element i'm adding>
<bunch of elements at the bottom that don't get changed>

And for a building that would be
<That version and header stuff all these files have>
<Rootcollections containing the element i'm adding>
<a new element in building chains specifying my new building is a level 2 IZ building>
<whatever other elements>

The units one seem to result in nothing happening for me. I made a UU that replaces the ironclad. icon is working, but it just shows a warrior for a model/animations. My unitdef is as described- i copied the ironclad element in the rootcollections from the base unit.artdef, added an UpdateArt action, file "(Mod Art Dependency File.)" Which is what Steel&Thunder appears ot also do - although do I need to generate that .dep in modbuddy? Or does modbuddy do that for me? I mention this because in your nice diagram it mentions it's part of the modbuddy build, so I'm just assuming that's it. I can't figure out how my unit.artdef differs from others, but certainly nothing is updating.
 
Last edited:
I got this one.
The issue was me not realizing landmarks.artdef has building info in it too. Once I copied that over, good to go. I also added a frontend action to load the art too. I might have missed something because the building appears in the district, but the little district clutter still apears under it- close enough for now!
This ancient thread was very helpful, for any future visitors.
 
I'm having similar issues trying to reuse the Redcoat's graphics with some tint changes (and Hungary's leader's with no changes at all). It's a huge pain in the ass to do anything with graphics in Civ6.

Instead of the old, relatively approachable XML, DDS and ArtDefs ways, you now have that plus presumably TEX, DEP and possible XLP and BLP in addition to a frustrating Mod.Art.xml.

I finally got my code mostly working (had to simplify my Civ's UA a bit), but now I have to wrestle with what should be an extremely simple graphics job. Tried to improvise a DEP from looking into those of mods which do similar things, but my UU is still invisible (icon as well with just DDS files referenced the Icons XML) and my custom leader is only partially using Matthias Corvinus' graphics (no background nor still image during game creation). I'm assuming the DEP is wrong and the ArtDefs aren't importing correctly.

I guess I've no choice but to get into ModBuddy and figure out its complicated way of doing things...
 
Instead of the old, relatively approachable XML, DDS and ArtDefs ways, you now have that plus presumably TEX, DEP and possible XLP and BLP in addition to a frustrating Mod.Art.xml.

If you're using Modbuddy the .dep is effectively the cooked version of Mod.Art.xml. Re-tinting existing unit parts can be done solely with Units.artdef. There a few examples in the Steel and Thunder:Unique Units artdef file: https://github.com/deliverator23/MoarUniqueUnits/blob/master/MoarUniqueUnits/ArtDefs/Units.artdef.

I think re-skins are simpler with Civ VI than Civ V. In Civ V you had to edit the actual .gr2 file using Nexus Buddy 2 to point to a different texture. Civ VI process is nicer but you have to get over the hump of learning the framework. The Civ VI artdefs are very complex and are the main stumbling block, but things like the District/Building system and the Unit attachment system are quite complex from a graphic standpoint. I will they could be manipulated via SQL but the highly nested structure doesn't lend itself to that.

I guess I've no choice but to get into ModBuddy and figure out its complicated way of doing things...

I think using Modbuddy for cooking is easier than trying to hand craft a .dep file and get everything right. If you set the Build Output level to Normal above it will report on errors which is useful.
 
Last edited:
If you're using Modbuddy the .dep is effectively the cooked version of Mod.Art.xml. Re-tinting existing unit parts can be done solely with Units.artdef. There a few examples in the Steel and Thunder:Unique Units artdef file: https://github.com/deliverator23/MoarUniqueUnits/blob/master/MoarUniqueUnits/ArtDefs/Units.artdef.

I think re-skins are simpler with Civ VI than Civ V. In Civ V you had to edit the actual .gr2 file using Nexus Buddy 2 to point to a different texture. Civ VI process is nicely but you have to get over the hump of learning the framework. The Civ VI are very complex and are the main stumbling block, but things like the District/Building system and the Unit attachment system are quite complex from a graphic standpoint. I will they could be manipulated via SQL but the highly nested structure doesn't lend itself to that.

(...)

I think using Modbuddy for cooking is easier than trying to hand craft a .dep file and get everything right. If you set the Build Output level to Normal above it will report on errors which is useful.
I've properly imported my stuff into a proper ModBuddy project now, and that helped with the DEP. Also generated TEX for the UU's icon just in case.

Then I used the automated Mod.Art.xml generator that's floating around (a godsend, along with the ArtDefs viewer).

The UU is now visible and generally functional, but there's still a number of kinks left to iron out. I'll PM you so not to continue derailing this thread.
 
Hi, I know I am a bit late to the party. I am also trying to reuse an existing building model for my new building (wonder). Everything else is set up and it was easy for me to reuse unit models. However, I am failing to get the building to show up.

I copied the Buildings.artdef and Landmarks.artdef files from the base game, renamed BUILDING_ARENA to BUILDING_FOO_BAR and added it to the Mpd.Art.Xml (ModArtGenerator).
Am I missing any important step?

I know that I am missing the WonderMovie part, but it should be okay to just skip that for now, right?

Thank you in advance! :)
 
Back
Top Bottom