Hard Light Productions Forums

Modding, Mission Design, and Coding => FS2 Open Coding - The Source Code Project (SCP) => Topic started by: Rampage on December 07, 2011, 11:23:37 pm

Title: Glow Maps and Debris Chunks
Post by: Rampage on December 07, 2011, 11:23:37 pm
Greetings from the Inferno Team.

We are not sure if this matter has been discussed, but would it be possible for debris chunks created post ship destruction not render glow maps?  We currently have a mission in development where a capital ship w/ glow maps disabled is destroyed and then have glow maps on again on its debris chunks.  Let us know if this can be done.

Rampage
INFTeam
Title: Re: Glow Maps and Debris Chunks
Post by: zookeeper on December 08, 2011, 12:11:06 am
In case it isn't apparent: it'd have to be optional.
Title: Re: Glow Maps and Debris Chunks
Post by: Nighteyes on December 08, 2011, 02:15:19 am
you know, its pretty easy to give the debris a separate debris map that consists of the original texture with burn marks on it, this way you can decide if to even have a glow map for it
Title: Re: Glow Maps and Debris Chunks
Post by: Rampage on December 08, 2011, 06:32:07 am
you know, its pretty easy to give the debris a separate debris map that consists of the original texture with burn marks on it, this way you can decide if to even have a glow map for it

True.  Although it has been standard practice to UVmap capital ships and give their debris their own textures, we still tilemap most of our capital ships to save time.

R
Title: Re: Glow Maps and Debris Chunks
Post by: FreeSpaceFreak on December 08, 2011, 03:14:41 pm
In case it isn't apparent: it'd have to be optional.

As I understand it, the ship had glowmaps disabled by SEXP - so it would just be a matter of not switching them back on on destruction.
Title: Re: Glow Maps and Debris Chunks
Post by: Rampage on December 08, 2011, 07:03:18 pm
As I understand it, the ship had glowmaps disabled by SEXP - so it would just be a matter of not switching them back on on destruction.

It automatically switches back on when the debris chunks form.

R
Title: Re: Glow Maps and Debris Chunks
Post by: FUBAR-BDHR on December 08, 2011, 08:39:26 pm
I don't think there is a good solution to how this would work.  There are a lot of ships that have separate debris maps with glows (some animated).  Since there is no way to specify what map(s) to disable glows on disabling them all might work for some but not for others.  Even making it optional just leaves the problem for half the people. 

The easiest solution I can think of here is texture replacement.  Have you tried replacing the -glow texture with something like nothing.dds (assuming you have one) instead of using the sexp? 
Title: Re: Glow Maps and Debris Chunks
Post by: zookeeper on December 09, 2011, 12:35:27 am
The easiest solution I can think of here is texture replacement.  Have you tried replacing the -glow texture with something like nothing.dds (assuming you have one) instead of using the sexp?

Nope, the effects of texture replace don't extend to debris.
Title: Re: Glow Maps and Debris Chunks
Post by: FreeSpaceFreak on December 09, 2011, 08:17:12 am
As I understand it, the ship had glowmaps disabled by SEXP - so it would just be a matter of not switching them back on on destruction.

It automatically switches back on when the debris chunks form.

Exactly, that's what I meant - the code would need to be adapted to remember the disable-glowmaps across destruction, instead of resetting it.
Title: Re: Glow Maps and Debris Chunks
Post by: FUBAR-BDHR on December 09, 2011, 11:01:51 pm
And what do you do if you want your ship glow maps disabled but not your debris ones?  See this issue?

Now the issue with texture replacement not carrying over to debris sounds like a bug (one that I believe is reported but not 100% on that). 

Of course what really needs done is fixing all the texture replacement bugs and allowing for it to be done via sexp.  Then instead of globally disabling glow maps you could disable the specific maps you want by setting alternate textures. 
Title: Re: Glow Maps and Debris Chunks
Post by: Valathil on December 10, 2011, 05:42:27 am
what about making a copy of the model reskinning the debris without glowmaps?
Title: Re: Glow Maps and Debris Chunks
Post by: FUBAR-BDHR on December 10, 2011, 04:03:17 pm
Waste of a ship slot just for one mission.  That is what texture replacement is for. 
Title: Re: Glow Maps and Debris Chunks
Post by: Trivial Psychic on December 10, 2011, 06:08:28 pm
Would it be possible to have some special texture controls within the ship's table file?

$Texture Modifications:
+LOD: Debris
+Texture: hull-texture-01
+Glow Disable: YES
Title: Re: Glow Maps and Debris Chunks
Post by: Valathil on December 11, 2011, 10:26:55 am
yeah coding, testing and debugging an extra feature just to do that is much less wasteful
Title: Re: Glow Maps and Debris Chunks
Post by: Dragon on December 11, 2011, 12:22:16 pm
An extra feature could be used by other mods that would also want the effect. An extra ship class is an ugly hack with it's own set of problems.