• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

FS2004 Spill Valve Switch

Messages
1,468
Country
italy
I want this switch to be open by default with a default value of 2. At the moment the default is zero.
vololiberista
Code:
<Gauge Name="RIGHT SPILL VALVE" Version="1.0">
   <Element>
      <Select>
         <Value>(L:SPILL2,number)</Value>
         <Case Value="0">
            <Image Name="SPILL_VALVE_CLOSED.bmp"/>
         </Case>        
         <Case Value="1">
           <Image Name="SPILL_VALVE_50.bmp"/>
         </Case>
         <Case Value="2">
             <Image Name="SPILL_VALVE_OPEN.bmp"/>
         </Case>
      </Select>
   </Element>
  <Mouse>
  <Tooltip>Right Spill Valve</Tooltip>
      <Area Top="25" Bottom="36">
         <Cursor Type="Hand"/>
         <Click>0 (&gt;L:SPILL2,number) 1 (>L:Sound_click,enum)</Click>
      </Area>
      <Area Top="12" Bottom="24">
         <Cursor Type="Hand"/>
         <Click>1 (&gt;L:SPILL2,number) 1 (>L:Sound_click,enum)</Click>
      </Area>
      <Area Top="0" Bottom="11">
         <Cursor Type="Hand"/>
         <Click>2 (&gt;L:SPILL2,number) 1 (>L:Sound_click,enum)</Click>
      </Area>
   </Mouse>
</Gauge>
 
I want this switch to be open by default with a default value of 2. At the moment the default is zero.
vololiberista

This what you need?

Code:
<Update>
(L:SetSpill2,bool) 0 == 
   if{ 
      2 (>L:SPILL2, number) 
      1 (>L:SetSpill2, bool) 
   }
</Update>

Bob
 
Thanks for that Bob,
Following that I created two indicator gauges with a moving semicircular bar. All I have to do now is to remember to close the spill valves shortly after take-off. Reason being I don't have any boiled sweets to give to the pax!!!!!!! :D
vololiberista
 
Alternatively, since all L:vars are initialized to zero on loading, simply swap the order for OPEN and CLOSED cases:

Code:
         <Case Value="0">
            <Image Name="SPILL_VALVE_OPEN.bmp"/>
         </Case>        
         <Case Value="1">
           <Image Name="SPILL_VALVE_50.bmp"/>
         </Case>
         <Case Value="2">
             <Image Name="SPILL_VALVE_CLOSED.bmp"/>
         </Case>
 
Last edited:
Alternatively, since all L:vars are initialized to zero on loading, simply swap the order for OPEN and CLOSED cases:

Code:
         <Case Value="0">
            <Image Name="SPILL_VALVE_OPEN.bmp"/>
         </Case>        
         <Case Value="1">
           <Image Name="SPILL_VALVE_50.bmp"/>
         </Case>
         <Case Value="2">
             <Image Name="SPILL_VALVE_CLOSED.bmp"/>
         </Case>

I thought of that too! But, the cabin depressurisation L:var was already set up with a value of 2 so I wanted to keep everything in line with that.
Everything works now. Including a warning horn with a cancel button. I'm following the flight manuel precisely! My next step is to indroduce an actual depressurisation event!!
vololiberista
 
Back
Top