Applying New Textures - Things I've tried for my ship (to spare others the pain)

The place to discuss scripting and game modifications for X³: Terran Conflict and X³: Albion Prelude.

Moderators: Scripting / Modding Moderators, Moderators for English X Forum

aXeL_UK
Posts: 200
Joined: Thu, 23. Oct 08, 22:45
x3tc

Applying New Textures - Things I've tried for my ship (to spare others the pain)

Post by aXeL_UK »

Thanks to 'Observe' I've finally got my Whitestar assembled and into the game except for one tiny detail... Textures.

I've searched the threads and gone through five 'X' specific tutorials on importing ships, covering X2-X3TC. I can lump them all together if people want them but you may want to wait till I have this kink resolved. Most of the tutorials talk about re-using X3 textures which is no use to me.

No matter what I try the game will not pick up my textures. I'm getting reasonably proficient at UVW mapping and modding/applying different textures but X3TC will use none of them. I'm running patch TC 1.2.1 and 3DS Max 8.5 with the DBOX 1.9 plugin and Observe's DDS Converter 2.1

Things I've tried:

1) Switching between jpg, tga, dds formats
2) Using powers of 2 for the texture dimensions e.g. 128x512
3) Placing the textures in the /textures dir, /tex and /tex/true dirs
4) Placing textures in the /dds dir
5) Giving all textures short numeric names
6) Copying an X3 multi-material and replacing the maps with my DDS/JPG/TGA. For this I imported a Fighter Drone mk2, deleted the object, replaced it with mine and kept the textures
7) Overwriting the individual Drone texture maps with my DDS map files
8) Trying (6) and (7) with an OTAS Skiron
9) Manually editing the materials lines in my exported bod file to reference the textures explicitly
10) Just using the X3 textures from the Drone/Skiron - This works perfectly but is obviously useless unless anyone wants to see a metallic Whitestar....

I can't help but think that I might need to create a new entry in materials.txt, but that does look very heavy going, trying to work out which line item to use as a baseline...

It can't be THIS hard. What am I doing wrong? :evil:
smbh
Posts: 129
Joined: Wed, 10. Jan 07, 06:22

Post by smbh »

Worked fine for my custom ship & textures (the reddish glow)

[ external image ]
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

:lol: aXel, you just came a a month to late..... no just kidding i have still the same problem on my twin ships. I have no problems whit the glow parts (just like smbh) but for the main body i whanted to use own tex's but everything i can think of or try it wont help a bit. If you look good on my ships you can see the tex's details but no color.....

I'm tryíng to get help of any kind and read the help file but cant get any further on the matter :(
aXeL_UK
Posts: 200
Joined: Thu, 23. Oct 08, 22:45
x3tc

Cool

Post by aXeL_UK »

Nice ship! Did you use a light map or just self illumination for the glow?

Don't suppose you could provide a method as to what kind of textures you used, how you applied them, e.g. UVW, multi-material?, things you had to change/edit to get them to render in the game? I suspect a number of us would be grateful if you could break it down, given I've tried the tutorials...

...and possibly a link to the ship as well? :wink:
aXeL_UK
Posts: 200
Joined: Thu, 23. Oct 08, 22:45
x3tc

Post by aXeL_UK »

Vash_the_Stampede wrote::lol: aXel, you just came a a month to late..... no just kidding i have still the same problem on my twin ships. I have no problems whit the glow parts (just like smbh) but for the main body i whanted to use own tex's but everything i can think of or try it wont help a bit. If you look good on my ships you can see the tex's details but no color.....

I'm tryíng to get help of any kind and read the help file but cant get any further on the matter :(
Yeah but it looks like smbh might be the man with the goods!
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

You know.... I really hope so, becouse i get a little f**** here :lol:
smbh
Posts: 129
Joined: Wed, 10. Jan 07, 06:22

Post by smbh »

I'll describe the process once I get back home, but in general, I imported one of the ships, think it was Boreas, which also imported a bunch of multi-materials. Then I just found the ones corresponding to for example the glow, opened the dds files in the directory I unpacked them to, tweaked the hue a bit and threw them into the .cat in the X3 Mod Manager with a dds\ path. I'll post the MATERIAL6 line of the .bod once I get home.

As for the ship, I'll post a link once the intellectual property questions are taken care of.

EDIT: Home now, here is the MAT6 entry in the Glowing01.bod (the reddish glowing ribs). I vaguely remember doing it differently the first time around, this time I explicitly pointed it to the location of the changed DDS's

In 3ds Max, I imported the Boreas scene, used the material SM 39, changed the paths for the dds files accordingly, as for maps, I used a self-illumination map. So basically everything but the paths was left as it was.

Code: Select all

MATERIAL6: 0; 0x2000000; 1; argon.fx; 57; diffcompression;SPTYPE_BOOL;0; bumpcompression;SPTYPE_BOOL;0; speccompression;SPTYPE_BOOL;0; lightcompression;SPTYPE_BOOL;0; nofiltering;SPTYPE_BOOL;0; autofree;SPTYPE_BOOL;0; Tex2;SPTYPE_BOOL;0; TexAnimStartU;SPTYPE_FLOAT;0.0; TexAnimStartV;SPTYPE_FLOAT;0.0; TexAnimEndU;SPTYPE_FLOAT;0.0; TexAnimEndV;SPTYPE_FLOAT;0.0; TexAnimDuration;SPTYPE_FLOAT;0.0; TexAnimRotation;SPTYPE_FLOAT;0.0; TexAnimOriginU;SPTYPE_FLOAT;0.5; TexAnimOriginV;SPTYPE_FLOAT;0.5; Brightness;SPTYPE_FLOAT;1.0; contrast;SPTYPE_FLOAT;1.0; saturation;SPTYPE_FLOAT;1.0; hue;SPTYPE_FLOAT;0.0; colormatrix;SPTYPE_BOOL;0; g_ColorWriteEnable;SPTYPE_LONG;15; g_Wrap;SPTYPE_LONG;0; g_CullMode;SPTYPE_LONG;2; g_AlphaBlendEnable;SPTYPE_LONG;0; g_BlendOp;SPTYPE_LONG;1; g_SrcBlend;SPTYPE_LONG;2; g_DestBlend;SPTYPE_LONG;1; g_ZEnable;SPTYPE_LONG;1; g_ZWriteEnable;SPTYPE_LONG;1; g_ALPHATESTENABLE;SPTYPE_LONG;0; g_LightAmbientIntensity;SPTYPE_FLOAT4;0.0;0.0;0.0;0.0; LightDir_Dir0;SPTYPE_LONG;0; LightDir_Color0;SPTYPE_FLOAT4;1.0;1.0;1.0;0.0; LightDir_Dir1;SPTYPE_LONG;0; LightDir_Color1;SPTYPE_FLOAT4;0.0;0.0;0.0;0.0; g_MatSpecularStrength;SPTYPE_FLOAT;1.0; g_MatSpecularPower;SPTYPE_FLOAT;10.0; g_MatReflectionStrength;SPTYPE_FLOAT;1.0; g_MatReflectionBias;SPTYPE_FLOAT;1.0; g_MatReflectionBlur;SPTYPE_FLOAT;0.0; g_AlphaValue;SPTYPE_FLOAT;1.0; g_MatEmissiveColor;SPTYPE_FLOAT4;0.0;0.0;0.0;0.0; t_FilterTypeDiffuse;SPTYPE_LONG;2; t_SamplerAddressMode;SPTYPE_LONG;1; t_SamplerMaxAnisotropy;SPTYPE_LONG;4; t_MipMapLODBias;SPTYPE_FLOAT;0.0; t_DiffuseTexture;SPTYPE_STRING;D:\egosoft\X3TC_unpacked\objects\ships\niagra\Izverg\dds\metal_argon_exhaust_source_02_diff.dds; t_MinFilterTypeDiffuse;SPTYPE_LONG;3; g_MatDiffuseStrength;SPTYPE_FLOAT;1.0; t_AlphaTexture;SPTYPE_STRING;NULL; t_BumpTexture;SPTYPE_STRING;D:\egosoft\X3TC_unpacked\objects\ships\niagra\Izverg\dds\metal_argon_exhaust_source_02_bump.dds; t_MinFilterTypeBump;SPTYPE_LONG;3; t_BumpMipMapLODBias;SPTYPE_FLOAT;0.0; t_FilterTypeBump;SPTYPE_LONG;2; t_SpecularTexture;SPTYPE_STRING;D:\egosoft\X3TC_unpacked\objects\ships\niagra\Izverg\dds\metal_argon_exhaust_source_02_spec.dds; t_LightMapTexture;SPTYPE_STRING;D:\egosoft\X3TC_unpacked\objects\ships\niagra\Izverg\dds\metal_argon_exhaust_source_02_light.dds; t_CubeMapTexture;SPTYPE_STRING;DDS\envmap_test.dds; 
 
EDIT 2: If you want, I can try to reproduce the process using your textures. Bear in mind, I'm a modo guy, 3ds Max is quite alien to me.

EDIT 3: Here's a "custom" texture -
[ external image ] and the corresponding MAT6 entry

Code: Select all

MATERIAL6: 0; 0x2000000; 1; argon.fx; 57; diffcompression;SPTYPE_BOOL;0; bumpcompression;SPTYPE_BOOL;0; speccompression;SPTYPE_BOOL;0; lightcompression;SPTYPE_BOOL;0; nofiltering;SPTYPE_BOOL;0; autofree;SPTYPE_BOOL;0; Tex2;SPTYPE_BOOL;0; TexAnimStartU;SPTYPE_FLOAT;0.0; TexAnimStartV;SPTYPE_FLOAT;0.0; TexAnimEndU;SPTYPE_FLOAT;0.0; TexAnimEndV;SPTYPE_FLOAT;0.0; TexAnimDuration;SPTYPE_FLOAT;0.0; TexAnimRotation;SPTYPE_FLOAT;0.0; TexAnimOriginU;SPTYPE_FLOAT;0.5; TexAnimOriginV;SPTYPE_FLOAT;0.5; Brightness;SPTYPE_FLOAT;1.0; contrast;SPTYPE_FLOAT;1.0; saturation;SPTYPE_FLOAT;1.0; hue;SPTYPE_FLOAT;0.0; colormatrix;SPTYPE_BOOL;0; g_ColorWriteEnable;SPTYPE_LONG;15; g_Wrap;SPTYPE_LONG;0; g_CullMode;SPTYPE_LONG;2; g_AlphaBlendEnable;SPTYPE_LONG;0; g_BlendOp;SPTYPE_LONG;1; g_SrcBlend;SPTYPE_LONG;2; g_DestBlend;SPTYPE_LONG;1; g_ZEnable;SPTYPE_LONG;1; g_ZWriteEnable;SPTYPE_LONG;1; g_ALPHATESTENABLE;SPTYPE_LONG;0; g_LightAmbientIntensity;SPTYPE_FLOAT4;0.0;0.0;0.0;0.0; LightDir_Dir0;SPTYPE_LONG;0; LightDir_Color0;SPTYPE_FLOAT4;1.0;1.0;1.0;0.0; LightDir_Dir1;SPTYPE_LONG;0; LightDir_Color1;SPTYPE_FLOAT4;0.0;0.0;0.0;0.0; g_MatSpecularStrength;SPTYPE_FLOAT;1.0; g_MatSpecularPower;SPTYPE_FLOAT;10.0; g_MatReflectionStrength;SPTYPE_FLOAT;1.0; g_MatReflectionBias;SPTYPE_FLOAT;1.0; g_MatReflectionBlur;SPTYPE_FLOAT;0.0; g_AlphaValue;SPTYPE_FLOAT;1.0; g_MatEmissiveColor;SPTYPE_FLOAT4;0.0;0.0;0.0;0.0; t_FilterTypeDiffuse;SPTYPE_LONG;2; t_SamplerAddressMode;SPTYPE_LONG;1; t_SamplerMaxAnisotropy;SPTYPE_LONG;4; t_MipMapLODBias;SPTYPE_FLOAT;0.0; t_DiffuseTexture;SPTYPE_STRING;D:\egosoft\X3TC_unpacked\objects\ships\niagra\Izverg\dds\metal_argon_simple_plating_diff.dds; t_MinFilterTypeDiffuse;SPTYPE_LONG;3; g_MatDiffuseStrength;SPTYPE_FLOAT;1.0; t_AlphaTexture;SPTYPE_STRING;NULL; t_BumpTexture;SPTYPE_STRING;metal_argon_simple_plating_bump.dds; t_MinFilterTypeBump;SPTYPE_LONG;3; t_BumpMipMapLODBias;SPTYPE_FLOAT;0.0; t_FilterTypeBump;SPTYPE_LONG;2; t_SpecularTexture;SPTYPE_STRING;D:\egosoft\X3TC_unpacked\objects\ships\niagra\Izverg\dds\metal_argon_simple_plating_spec.dds; t_LightMapTexture;SPTYPE_STRING;NULL; t_CubeMapTexture;SPTYPE_STRING;dds\envmap_test.dds; 
 
The changed and applied DDSs are obviously metal_argon_simple_plating_diff.dds and metal_argon_simple_plating_spec.dds
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

I get a feeling that i have a bad .dds or just a fackt that i dont know how to make them properly :? :? I have copy'd the mat 6 in my model but still if i change the diff and spec in my own file then i can see the tex in detail but still no color :cry:
smbh
Posts: 129
Joined: Wed, 10. Jan 07, 06:22

Post by smbh »

Would the format of the DDS you're saving in matter at all?
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

Well i have re-make some pic in Photoshop CS3 and save them as .tga 16-bit then i convert them whit DDS Converter 2 to .dds and then i copy the file name in the Mat 6 line's. And so i get the details but not the color. I have aslo try'd to save the .tga on 8 bit, 24 bit and 32 bit but that wont help and i'm still trying to get different out put settings on the DDS Converter 2 i have now try'd DXT5 and DXT3 whit build midmaps on still have to try DXT1a and DXT1c and then all my options are passt (btw DXT3 was standard when i installd the prog)
smbh
Posts: 129
Joined: Wed, 10. Jan 07, 06:22

Post by smbh »

If you want, send me the textures and I'll try to it exactly as I did before but with yours.
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

when i'm right then you have a pm from me :lol:
Ravenholme
Posts: 246
Joined: Sat, 18. Nov 06, 15:54
x3tc

Post by Ravenholme »

There is a DDS plugin for photoshop that might be worth hunting down, Vash. It's what I used for doing textures for Oblivion/Morrowind when I did texture work for those games. It also allows the creation of normal maps from the texture file, often a good way to start getting yourself a normal map (Usually you'll have to edit it yourself somewhat)
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

Thanks for the info :D

Let the hunt begin :twisted:

*EDIT*

That was a fast hunt.....
http://developer.nvidia.com/object/phot ... #downloads
Ravenholme
Posts: 246
Joined: Sat, 18. Nov 06, 15:54
x3tc

Post by Ravenholme »

Vash_the_Stampede wrote:Thanks for the info :D

Let the hunt begin :twisted:

*EDIT*

That was a fast hunt.....
http://developer.nvidia.com/object/phot ... #downloads
Isn't that the best kind of hunt? :P

Try mucking about with the settings of that plugin and see if you get better results (It brings up a dialogue box when you try to save a texture as a DDS)
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

Indeed this will work much better to make .dds but i'm testing ingame now of it is better or not 8)
aXeL_UK
Posts: 200
Joined: Thu, 23. Oct 08, 22:45
x3tc

Single texture test using your materials knowledge

Post by aXeL_UK »

Vash_the_Stampede wrote:when i'm right then you have a pm from me :lol:
smbh,

Were I to send one you object with one map which I'm trying to render in the game, would you be willing to have a look and see if you can get it to render? Or just see if you can apply to your ship?
Vash_the_Stampede
Posts: 128
Joined: Mon, 5. Jul 04, 14:47
x3tc

Post by Vash_the_Stampede »

The plugin helps a lot more detail but........ still no color
smbh
Posts: 129
Joined: Wed, 10. Jan 07, 06:22

Re: Single texture test using your materials knowledge

Post by smbh »

aXeL_UK wrote:
Vash_the_Stampede wrote:when i'm right then you have a pm from me :lol:
smbh,

Were I to send one you object with one map which I'm trying to render in the game, would you be willing to have a look and see if you can get it to render? Or just see if you can apply to your ship?
Sure, shoot away. I can provide email details via PM or alternatively you can upload it somewhere for me to grab.
aquemnun
Posts: 247
Joined: Sun, 26. Oct 08, 19:47

Post by aquemnun »

smbh. what ship is that? did you make it yourself or rip it from a game, if so which? i love it!

although it looks very similar to that infinite cambat game (the prototype)
There once was a buggy AI
who decided her subject must die
when the plot was uncovered,
the subject discovered
that sadly the cake was a lie.

Return to “X³: Terran Conflict / Albion Prelude - Scripts and Modding”