Jump to content
Sign in to follow this  
Guest

.xml switch backgrounds

Recommended Posts

Guest

QUOTE: Transparent overlay?? Gee... Can you guess my next question!?! : )How does one go about doing THAT? It would be perfect!REPLY: The color of black (RGB=0,0,0) is a special case that is treated as transparent. Wherever this color is use, it is totally transparent. Create a mask with black 0,0,0 and simply paint your 'light splash' on it where you want it to be.As far as your lighted text, you may want to do this the "easy way." :) Note that I've simply repeated the exact same section, but the second is tagged to only be when the battery and panel lights are on (please note that I substituted the LIGHT_LOGO for the PANEL_LIGHTS, but the principle is still the same... :)- - - - (A:Airspeed true calibrate,radians)- (A:LIGHT LOGO,bool) (A:Electrical master battery,bool) && - - - (A:Airspeed true calibrate,radians)BillAVSIM OmbudsmanFounder and Director,Creative Recycling of Aircraft Partshttp://catholic-hymns.com/frbill/FS2002/images/fartslogo.jpg

Share this post


Link to post
Share on other sites

Hi,Just an example of what you can achieve with Luminous and Bright, using your own Variables and bitmaps.Same picture, same time, 4 different lightings, sorry for the bad jpg format.Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites
Guest Ionizeyou

"You might simply use a bitmap swap. Set up an alternate bitmap with the "light splash" and switch between the two in the same code with your panel lights."Bill,Well... I have a Night-Time, Main panel bitmap, and it looks pretty good. How do I go about having the game re-load the main-panel bitmap when it's night?Here's a couple of screenshots. The first is at Dusk and the second is at Night. If I had my way, I'd like to see the bitmap swap somewhere near the middle of dusk, that way the switch wouldn't be too dramatic. Or is this another thing that would be tagged with the panel lights? That switch is sure getting overloaded!!Still can't seem to get my sounds playing... I have the FSSound module (long-time ago), the Kevents.gau and the XMLsound.gau. I think my Click events aren't textbook... here's the tag I'm currently using with my Flight-Director Switch... the switch works, but no "click" sound.(>K:TOGGLE_FLIGHT_DIRECTOR) ! (>K:TOGGLE_AFTERBURNER1)I think it's coming along nicely!Kevin

Share this post


Link to post
Share on other sites
Guest Ionizeyou

Sorry, I really did read your post!!I tried to make a bitmap swap and what happens is that it "overlay's" everything else, making the gauges invisible. Oh well, I'm hoping to be done soon enough to have this uploaded before the Fourth of July...Kevin

Share this post


Link to post
Share on other sites

Try:(>K:TOGGLE_FLIGHT_DIRECTOR) 1 (>K:TOGGLE_AFTERBURNER1)Works for me.Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites
Guest Ionizeyou

I just tried that and I don't know what I'm doing wrong here, but it will not play...I'm pretty sure I have the files where they need to be and yet I get no sound. Any suggestions? I'm running out of patience with this sound thing...Best to you...Kevin

Share this post


Link to post
Share on other sites

OKCheck:1. WHM-kevents.gau and XMLsound.gau in the Gauges Directory.2. The click sounds must have the following name:whm-sound1.wav, whm-sound2.wav, whm-sound3.wav and whm-sound4.wav.3. FSSound.dll in the Modules directory.4. Add in the fs2002.cfg file:[OLDMODULES]FSSound.dll=15. Adjust the sound-sliders in the Sound Setting Menu.6. (>K:TOGGLE_AFTERBURNER1)7. If nothing helps: ???????????????? Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites
Guest Ionizeyou

And yet... still nothing with the sounds... aaargh!!Here's the entire coding for my FD Switch...Where and what would you suggest I do to edit this so that the sounds might have a fighting chance to playback. Obviously I'm starting at the beginning here again as I removed the click section.(A:Panel Lights,bool)(A:Autopilot flight director active,bool)(A:Autopilot flight director active,bool)(A:Autopilot flight director active,bool)Thanks again,Kevin

Share this post


Link to post
Share on other sites

Hi,I "rewrote" the gauge a little bit, hope it will work now:(A:Panel Lights,bool)(A:Autopilot flight director active,bool)(A:Autopilot flight director active,bool)(>K:TOGGLE_FLIGHT_DIRECTOR) (>K:TOGGLE AFTERBURNER1)Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites

Hi,Forgot this one, panel.cfg:gaugexx=WHM-kevents!XML-kevents, 0, 0, 10gaugeyy=XMLSound!XML-Sound, 0, 0, 10You need it!Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites
Guest

>Sorry, I really did read your post!!>>I tried to make a bitmap swap and what happens is that it>"overlay's" everything else, making the gauges invisible. Oh>well, I'm hoping to be done soon enough to have this uploaded>before the Fourth of July...There are at least three ways of accomplishing the 'overlay:'1) duplicate the gauges on the 'overlay' (bad method!)2) cut 'holes' in the overlay so the gauges will show through (use 0,0,0 to make transparent)3) make the entire overlay transparent, but with the 'light splashes' added to the bitmap (the same technique you would use in an Alpha channel). IMHO, this is the better method since it is often difficult to accurately 'cut holes' as in #2 above.As far as control goes, you you can either tie the overlay to the PANEL_ID_xx in your panel lights switch code, or use an "autoswitch."The "Autoswitch" was a collaborative effort of many of us here, with the invaluable help of Arne Bartels (who developed the algorithim to calculate 'sun angle.' EaglesoftDG uses the "autoswitch" in our 400A and Premier I releases, and it has been well received. Of course, we're using it to switch on/off 'daytime panel floods' in the VC to eliminate/mitigate the excessive shadowing effect that FS uses, that makes the VC darn near impossible to see in the daytime when flying in the VC! :)===================================================================%((P:ZULU TIME,hours) (A:PLANE LONGITUDE, degrees) 15 / + (P:ZULU DAY OF YEAR,number) 3 - 365.25 / 2.0 pi * * sin 7.3 * (P:ZULU DAY OF YEAR,number) 80 - 365.25 / 4.0 pi * * sin -9.8 * + 60 / - (>L:local_sun_time,number) (P:ZULU DAY OF YEAR,number) 80 - 365.25 / 2.0 pi * * sin 23.45 * dgrd (>L:declin,number) (L:declin,number) sin (A:PLANE LATITUDE, radians) sin * (L:declin,number) cos (A:PLANE LATITUDE, radians) cos * (L:local_sun_time,number) 12 - 24.0 / 2.0 pi * * cos * + asin rddg 1.0 (A:PLANE ALTITUDE,km) 6370 / 1 + / acos rddg + (>L:local_sun_angle,number) (L:local_sun_time,number) d int )%!02d!:%( 1 % 60 * )%!.1f! %((L:local_sun_angle,number))%!.(A:Light Logo, bool) 1 == (L:local_sun_angle,number) -1 < && if{ (K:TOGGLE_LOGO_LIGHTS) ! (>K:TOGGLE_LOGO_LIGHTS) } (A:Light Logo, bool) 0 == (L:local_sun_angle, number) -1 > && if{ (K:TOGGLE_LOGO_LIGHTS) ! (>K:TOGGLE_LOGO_LIGHTS) }==========================================================The 'controlling' element in the above is contained in the constant following (L:local_sun_angle,number), in this case "-1"... This sets the autoswitch to activate when the sun is -1 degree below the horizon, which seems to be about the time of night/dawn and dusk/night transition.BillAVSIM OmbudsmanFounder and Director,Creative Recycling of Aircraft Partshttp://catholic-hymns.com/frbill/FS2002/images/fartslogo.jpg

Share this post


Link to post
Share on other sites
Guest Ionizeyou

Thanks Jan...I was able to get the sounds to work, however there remains a new problem for me and I cannot figure it out.Whenever I activate a switch or button, the sound plays, but is repeated randomly and very rapidly... sometimes it clicks once, but for the most part it is several "clicks" at a time with one throw of the switch. Any idea what this might be?I've decided to upload what I have to this point. There's a few things that I'm going to continue to work on... the night lighting bitmap and the sound issue. You can find it as "ks737ng.zip".Thanks again,Kevin

Share this post


Link to post
Share on other sites

Hi,I have the same .. sometimes.Can be a little bit wrong code.Try 0 (>K:Toggle Aft..), 1 (>K:Toggle Aft..) and (>K:Toggle Aft..).Beware of the "If" function:.....If{ (>K:Toggle Aft..) }, then it "toggles" all the time!(You can use it, when you want to loop play a sound; i use it for the airco). Jan"Procul Negotiis"

Share this post


Link to post
Share on other sites
Guest

Just keep in mind that the xml-sound gauge WILL NOT work with FS2004 (unless an FS patch is released). Even if you think that someone else will make a workable gauge for this version, the actual problem (that will crash FS2004) is happening with the events themselves. In other words, the crash is a result of (>K:TOGGLE_AFTERBURNER1), NOT because of xml-sound gauge as such.

Share this post


Link to post
Share on other sites
Guest

Re statement above: " the xml-sound gauge WILL NOT work with FS2004 "Experience now is that xml-sound.gau DOES work in FS2004 provided that:1. it is used in a jet aircraft which has Afterburners enabled in the aircraft.cfg file and as many engines as you wish to use afterburners.[TurbineEngineData]..afterburner_available=12. FSSound.dll=1 is included in the OLDMODULES section of your fs9.cfg file. Trevor.

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...