Jump to content
Sign in to follow this  
badderjet

Swapping lit/unlit gauge polys - Bill?

Recommended Posts

I've been trying to implement the technique of swapping out lit/unlit gauge polys for analog gauge lighting, but something is elluding me in the process. I assume since the lit $texture has an associated _L, that in order to REMOVE the backlighting for a copy, one must apply a new material based on a copy of $texture and omit the Self-Illumination property.The only problem is I can't get it to work that way! It remains lit (although the swapping XML .mdl code works fine). It's just ignoring the self-illumination attribute on the new material.Perhaps I'm going about it all wrong, but short of adding a copy of the gauge to my $texture (seems a waste), or adding a new VC section (an even larger waste), this seems like it should be the correct way to do it. What am I missing here?Thanks,--Jon

Share this post


Link to post
Share on other sites

>I've been trying to implement the technique of swapping out>lit/unlit gauge polys for analog gauge lighting, but something>is elluding me in the process. I assume since the lit $texture>has an associated _L, that in order to REMOVE the backlighting>for a copy, one must apply a new material based on a copy of>$texture and omit the Self-Illumination property.It is actually so simple that you'll probably slap yourself silly... ;)First, make sure you have properly set up the VC gauge backlighting and it works... ;)Clone the "lighted gauge polygon(s)"Create a new "Material" and simply add the $vcxxx.bmp texture to the Diffuse Color slot. Since you are using a "clone" of the original, the original's UVW mapping is also cloned, so that is ALL you need to do! ;)Of course you do need to set up the hiearchy in the model appropriately, as well as provide the XML condition based on the panel lights variable (or whatever custom switching you might want).interior....panel_not_lighted........(all gauge polys go here with no Self-Illumination _L.bmp in the Material)....panel_lighted........(all gauge polys go here with Self-Illumination _L.bmp in the Material)Obviously, once you've mastered this, if you are modeling a complex aircraft panel that has multiple, independently controlled lighting switches, you can expand this concept by using custom L:vars to control the gauge backlighting.Also, don't forget that you need to account for more than just the light switches... it would look silly to have the panel lighted up with the battery turned off and ground power disconnected... ;)


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites

Thanks Bill, I'll try that. From your description, it seems the only difference is that you would create a new material, where I had copied the original material and then un-checked "Self-Illumination". Perhaps some strange quirk (as if that'd be surprising:)Also, I will check my hierarchy as I certainly haven't been proactive in making sure it's intact during construction.The lighting is certainly very frustrating, and "hack" feeling, and I'm sure many many people are grateful for the ground you've broken (and shared) in helping us overcome these design flaws. Here's an image of what I've been up to...Thanks again,--Jonhttp://forums.avsim.net/user_files/146342.jpg

Share this post


Link to post
Share on other sites

>Thanks Bill, I'll try that. From your description, it seems>the only difference is that you would create a new material,>where I had copied the original material and then un-checked>"Self-Illumination". Perhaps some strange quirk (as if that'd>be surprising:)If you have truly "copied the Material" and aren't just seeing the same Material, unchecking won't work... but, simply dragging any of the "NONE" entries into the Self-Illumination slot will... ;)>The lighting is certainly very frustrating, and "hack">feeling, and I'm sure many many people are grateful for the>ground you've broken (and shared) in helping us overcome these>design flaws. Here's an image of what I've been up to...SWEET! Nice looking cockpit!


Fr. Bill    

AOPA Member: 07141481 AARP Member: 3209010556


     Avsim Board of Directors | Avsim Forums Moderator

Share this post


Link to post
Share on other sites
Guest Vorlin

I've been oogling that pic for a few days now and all I can say is HOLY COW!Jon, that's one VC that will change the standard for all others that follow in the future. Truly amazing work.Scott / Vorlin

Share this post


Link to post
Share on other sites

Oh, thanks so much Scott (and Bill). I haven't released many pics of the project over the last 3 years, but it's certainly been tempting:) I hope to have much more material available later this year as it approaches completion.I just want to say that none of it would have been possible without this forum and the many helpful people who contribute here.--Jon

Share this post


Link to post
Share on other sites

Second that guys, no kiddin, it's truely amazing... :-eek Awesome work dude. :-hahCheers! :-beerchugEtienne :-wave

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...