Sign in to follow this  
Au MaV

Need help with water rudder xml gauge Please

Recommended Posts

HiI'm trying to deploy the water rudder when the landing lights switched on and retract when switched off (yes I have the contact point set right in the aircraft.cfg)Ive tried just about every syntax that my VERY limited xml experience allows,the best I can do is get the water rudder to pulse back and forth here what Ive got so far(A:LIGHT LANDING,number) if{ 1 (>K:TOGGLE_WATER_RUDDER) } els{ 0 (>K:TOGGLE_WATER_RUDDER) }tried this and a dozen other combinations Any help most appreciated Thanks MaV

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Hallo,You can try something like, not tested:(A:LIGHT LANDING,bool) if{ (A: one of the Var's showing the rudder is up) if{ (>K:TOGGLE_WATER_RUDDER) } } els{ (A: one of the Var's showing the rudder is down) if{ (>K:TOGGLE_WATER_RUDDER) } }Hope it helps,Jan"Beatus Ille Procul Negotiis"

Share this post


Link to post
Share on other sites

(A:LIGHT LANDING,bool) if{ (A:WATER RUDDER HANDLE POSITION,bool) ! if{ (>K:TOGGLE_WATER_RUDDER) } } els{ (A:WATER RUDDER HANDLE POSITION,bool) if{ (>K:TOGGLE_WATER_RUDDER) } }A few TIPS:1. All "toggle" events donot require a parameter (no "0" or "1").They just toggle the current state.2. Always use an UpdateFrequency with value 1 - 6 (schedule freq. 1 to resp. 6 times per sec) for these type of gauges that check&toggle the state of a variable. If you omit this line (hence the UpdateFreq = 18 times per sec, by default), the gauge doesn't work properly if the framerate in FS is lower then 18 fps. (with "6" is still fast, and will work OK when fps is above 6)3. To test the state of these types of "surface" variables, always use the "handle" events (which gives the TARGET state as "0" and "1"; unlike eg. "WATER LEFT RUDDER EXTENDED", which give the ACTUAL state which increments/decrements within the animation time when in transition. However, some surfaces (like WIngfold) do not have a "handle" position variable. Then it's still possible, but the gauge becomes more complex (you have to test the direction in which the variable is moving as well to determine whether the state must be toggled or not.Cheers, Rob Barendregt

Share this post


Link to post
Share on other sites

HiThank You very much Rob and JanJan Whilst the code you posted didn't quite work,it pointed me in the right direction for another gaugeRob you get the door prize works a treat and the scary thing I actually understand what your saying :) Thanks to both of youRegardsMaV

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