Home Technical Talk

Info On Texture maps

polycounter lvl 6
Offline / Send Message
Havie polycounter lvl 6
Hello guys!
Let me start off by saying I am a total freaking noob when it comes to this area, Im a bit out of my element, but what I am doing is making a huge mod overhaul for a video game called Total war: Shogun2. This requires me to change to the map from japan to china.

After a tedious process i have got this to work in game, now i am trying to texture the map through the tools given to me.

First there is a file called
Heightmap.tiff
http://www.twcenter.net/forums/attachment.php?attachmentid=312606&d=1408754441
This controls what area is land/water and the height of it all. 
Heres what mine  thus far looks like :
http://i.imgur.com/qsVjdJp.png

Heres the general color code idea:
Deep sea = 0, 0, 0
Regular sea = 24, 24, 24
Shallow sea = 43, 43, 43

Land = 86, 86, 86 (if the land colour is too dark Shogun 2 will put this area underwater)
Low mountain = 122, 122, 122
High mountain = 184, 184, 184
Mountain peak = 240, 240, 240

This is all working and making sense to me.

Next up is the
campaign detail mask.dds
Which looks like this
http://www.twcenter.net/forums/attachment.php?attachmentid=312615&d=1408755826
and has an alpha channel here
http://www.twcenter.net/forums/attachment.php?attachmentid=312614&d=1408755826

The color idea here is :
Red = rocky
Green = fertile land
Blue = mountain
Black = grass
Alpha channel = sand/coast

I've only done the blue layers so far and what appears on the map is like this ugly brown texture, which would be fine, but what seems to be happening regardless of this texture is another White like "mountain cap" texture that i have no idea where its coming from right? Either its just hardcoded to a certain terrain height looks this way or maybe something else is going on?
Heres an image of that issue:
http://i.imgur.com/XBEKgW5.jpg
Heres my area in the files
http://i.imgur.com/v9Qpecz.png
http://i.imgur.com/v13JdB8.png 

Heres an image of what a vanilla looking mountain in Shogun2 looks like in game:
http://i.imgur.com/UZkWwod.jpg
Heres the Area in the files
http://i.imgur.com/LNUQOno.png
http://i.imgur.com/sR23qJc.png

Whats confusing is despite me not having "red" for "rocky" and only using blue for mountain. They are still achieving a look of gray rocks going up the elevation, THEN the mountain texture on top. Where they have "red" doesnt correlate with how this is presenting itself. right?

So then i dig a little deeper and find this file called 
terrain_metadata.TGA
which looks like this:
http://i.imgur.com/AAnPa5J.png

and im thinking this must be the golden ticket, duplicate the layers, select brush, then hold alt, select that color of green, wipe the area clean, then i proceed to do the same for the rest of the colors and paint in my mountains. I hit save as .dds and it opens up this prompt in PS of which way to save it , (16bits/pixel, 24 or 32. and an option to compress RLE)  except this file needs to be ran through the Modding tool that the developers gave us to mod this game, when it goes through it says :
"Loading terrain_metadata.tga ... Done!
Loading attribute_metadata.tga ... Done!
cannot find terrain type from colour - see Chu
t:\branches\shogun2\modders\common\tooldatabuilder\source\CampaignMapData/CampaignMetaData.cpp(178) : TOOLDATABUILDER::CAMPAIGN_METADATA_PROCESSOR::write_metadata
terrain_type_valid
cannot find terrain type from colour - see Chu"

So Im thinking i must be saving this wrong? 

Anybody got any advice on this matter here? or familiar at all with these types of files enough to lend some advice?




Replies

  • Havie
    Options
    Offline / Send Message
    Havie polycounter lvl 6
    Upon looking further into this:

    If i open the original TGA file and immediately save as, then it saves normal  (use compress RLE)

    if I try to save my edited one ( deleted all down to 1 layer) it get this weird pop up message about must save as a copy with this selection
    http://i.imgur.com/gdWeEmX.png

    been googling around about it, and its something to do with TGA files and alpha channel but i looked under layers and this image doesnt have an alpha channel so?

    Update: Using flatten image gets rid of the save as selection error, but file still does not pass through the converter 

    Update2: looks like there is something called a supertexture.stpd looking to extract that now but only have gotten the normal/bump map out.


    TDLR:
    http://i.imgur.com/IqXg7fX.png
  • Havie
    Options
    Offline / Send Message
    Havie polycounter lvl 6
    Someone can just delete this thread, i figured it all out
Sign In or Register to comment.