Hanger Bay Shields

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

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

Post Reply
tormox
Posts: 23
Joined: Sat, 4. Aug 18, 21:53
x4

Hanger Bay Shields

Post by tormox » Wed, 14. Aug 19, 14:43

I was hoping to tap into someones of knowledge regarding:

Animations.txt - I am trying, well achieved to apply a semi transparent hanger bay shield common on SW ships. So far I have taken the Boron_SYshield.bod and remodelled it into a plane. It's been successful, it works and is semi-transparent with no collision (I'm not sure if the collision matters for docking ships).
I then look into the texture. Finding an old texture animation thread,

viewtopic.php?t=141309&highlight=videolist

I've figured out it's referenced in animations.txt at index 36. However I don't understand the entry. It is different to guide listed in the old thread. Would you perhaps have any knowledge of it?

User avatar
Killjaeden
Posts: 5366
Joined: Sun, 3. Sep 06, 18:19
x3tc

Re: Hanger Bay Shields

Post by Killjaeden » Fri, 6. Sep 19, 18:03

tormox wrote:
Wed, 14. Aug 19, 14:43
I've figured out it's referenced in animations.txt at index 36. However I don't understand the entry. It is different to guide listed in the old thread. Would you perhaps have any knowledge of it?
Animated textures can be made by "moving" the texture (instead of replacing it with a different image every frame). This is how the Sohnen in XTM/XTC are animated, and if memory serves right, also the boron shield texture. Maybe check the material entry in the model instead, i think it was defined in there.
[ external image ]
X-Tended TC Mod Team Veteran.
Modeller of X3AP Split Acinonyx, Split Drake, Argon Lotan, Teladi Tern. My current work:
Image

tormox
Posts: 23
Joined: Sat, 4. Aug 18, 21:53
x4

Re: Hanger Bay Shields

Post by tormox » Mon, 9. Sep 19, 02:43

Killjaeden wrote:
Fri, 6. Sep 19, 18:03

Animated textures can be made by "moving" the texture (instead of replacing it with a different image every frame). This is how the Sohnen in XTM/XTC are animated, and if memory serves right, also the boron shield texture. Maybe check the material entry in the model instead, i think it was defined in there.
Thanks for repling, I'm not quite sure how you would "move" the texture. The vanilla Boron shield doesn't appear to be animated. I've been using the default entry.

User avatar
Killjaeden
Posts: 5366
Joined: Sun, 3. Sep 06, 18:19
x3tc

Re: Hanger Bay Shields

Post by Killjaeden » Mon, 9. Sep 19, 17:46

tormox wrote:
Mon, 9. Sep 19, 02:43
Thanks for repling, I'm not quite sure how you would "move" the texture. The vanilla Boron shield doesn't appear to be animated. I've been using the default entry.
Ah sorry, was mixing it up. To animate the UV's, you need to look into the model's (bod) material definition:
The TexAnim* entries are the relevant for that. In the following an example for a moving texture from XTM (old X3R argon shader).
MATERIAL6: 40; 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.000000;
TexAnimStartV;SPTYPE_FLOAT;0.000000;
TexAnimEndU;SPTYPE_FLOAT;1.000000;
TexAnimEndV;SPTYPE_FLOAT;0.000000;
TexAnimDuration;SPTYPE_FLOAT;9.000000;
TexAnimRotation;SPTYPE_FLOAT;9.000000;
TexAnimOriginU;SPTYPE_FLOAT;0.500000;
TexAnimOriginV;SPTYPE_FLOAT;0.500000;

Brightness;SPTYPE_FLOAT;1.000000; contrast;SPTYPE_FLOAT;1.000000; saturation;SPTYPE_FLOAT;1.000000; hue;SPTYPE_FLOAT;0.000000; 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.000000;0.000000;0.000000;0.000000; LightDir_Dir0;SPTYPE_LONG;0; LightDir_Color0;SPTYPE_FLOAT4;1.000000;1.000000;1.000000;0.000000; LightDir_Dir1;SPTYPE_LONG;0; LightDir_Color1;SPTYPE_FLOAT4;0.000000;0.000000;0.000000;0.000000; g_MatSpecularStrength;SPTYPE_FLOAT;1.000000; g_MatSpecularPower;SPTYPE_FLOAT;10.000000; g_MatReflectionStrength;SPTYPE_FLOAT;1.000000; g_MatReflectionBias;SPTYPE_FLOAT;1.000000; g_MatReflectionBlur;SPTYPE_FLOAT;0.000000; g_AlphaValue;SPTYPE_FLOAT;1.000000; g_MatEmissiveColor;SPTYPE_FLOAT4;0.000000;0.000000;0.000000;0.000000; t_FilterTypeDiffuse;SPTYPE_LONG;2; t_SamplerAddressMode;SPTYPE_LONG;1; t_SamplerMaxAnisotropy;SPTYPE_LONG;4; t_MipMapLODBias;SPTYPE_FLOAT;0.000000; t_DiffuseTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_diff.dds; t_MinFilterTypeDiffuse;SPTYPE_LONG;3; g_MatDiffuseStrength;SPTYPE_FLOAT;1.000000; t_AlphaTexture;SPTYPE_STRING;NULL; t_BumpTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_bump.dds; t_MinFilterTypeBump;SPTYPE_LONG;3; t_BumpMipMapLODBias;SPTYPE_FLOAT;0.000000; t_FilterTypeBump;SPTYPE_LONG;2; t_SpecularTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_spec.dds; t_LightMapTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_light.dds; t_CubeMapTexture;SPTYPE_STRING;DDS\envmap_test.dds;
[ external image ]
X-Tended TC Mod Team Veteran.
Modeller of X3AP Split Acinonyx, Split Drake, Argon Lotan, Teladi Tern. My current work:
Image

tormox
Posts: 23
Joined: Sat, 4. Aug 18, 21:53
x4

Re: Hanger Bay Shields

Post by tormox » Mon, 23. Sep 19, 12:18

Ok awesome, I'll give this a try. Thank you.

tormox
Posts: 23
Joined: Sat, 4. Aug 18, 21:53
x4

Re: Hanger Bay Shields

Post by tormox » Tue, 1. Oct 19, 11:53

Killjaeden wrote:
Mon, 9. Sep 19, 17:46

Ah sorry, was mixing it up. To animate the UV's, you need to look into the model's (bod) material definition:
The TexAnim* entries are the relevant for that. In the following an example for a moving texture from XTM (old X3R argon shader).
MATERIAL6: 40; 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.000000;
TexAnimStartV;SPTYPE_FLOAT;0.000000;
TexAnimEndU;SPTYPE_FLOAT;1.000000;
TexAnimEndV;SPTYPE_FLOAT;0.000000;
TexAnimDuration;SPTYPE_FLOAT;9.000000;
TexAnimRotation;SPTYPE_FLOAT;9.000000;
TexAnimOriginU;SPTYPE_FLOAT;0.500000;
TexAnimOriginV;SPTYPE_FLOAT;0.500000;

Brightness;SPTYPE_FLOAT;1.000000; contrast;SPTYPE_FLOAT;1.000000; saturation;SPTYPE_FLOAT;1.000000; hue;SPTYPE_FLOAT;0.000000; 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.000000;0.000000;0.000000;0.000000; LightDir_Dir0;SPTYPE_LONG;0; LightDir_Color0;SPTYPE_FLOAT4;1.000000;1.000000;1.000000;0.000000; LightDir_Dir1;SPTYPE_LONG;0; LightDir_Color1;SPTYPE_FLOAT4;0.000000;0.000000;0.000000;0.000000; g_MatSpecularStrength;SPTYPE_FLOAT;1.000000; g_MatSpecularPower;SPTYPE_FLOAT;10.000000; g_MatReflectionStrength;SPTYPE_FLOAT;1.000000; g_MatReflectionBias;SPTYPE_FLOAT;1.000000; g_MatReflectionBlur;SPTYPE_FLOAT;0.000000; g_AlphaValue;SPTYPE_FLOAT;1.000000; g_MatEmissiveColor;SPTYPE_FLOAT4;0.000000;0.000000;0.000000;0.000000; t_FilterTypeDiffuse;SPTYPE_LONG;2; t_SamplerAddressMode;SPTYPE_LONG;1; t_SamplerMaxAnisotropy;SPTYPE_LONG;4; t_MipMapLODBias;SPTYPE_FLOAT;0.000000; t_DiffuseTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_diff.dds; t_MinFilterTypeDiffuse;SPTYPE_LONG;3; g_MatDiffuseStrength;SPTYPE_FLOAT;1.000000; t_AlphaTexture;SPTYPE_STRING;NULL; t_BumpTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_bump.dds; t_MinFilterTypeBump;SPTYPE_LONG;3; t_BumpMipMapLODBias;SPTYPE_FLOAT;0.000000; t_FilterTypeBump;SPTYPE_LONG;2; t_SpecularTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_spec.dds; t_LightMapTexture;SPTYPE_STRING;dds\metal_argon_exhaust_trims_02_light.dds; t_CubeMapTexture;SPTYPE_STRING;DDS\envmap_test.dds;
That worked a treat, thanks very much Killjaeden.

https://www.youtube.com/watch?v=HrrUAI-W8Do

On to the shield effect bubbles when shot at now :)

Post Reply

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