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

FSXA 2D Animation Gauge

Messages
106
Country
germany
Hi,
I`ve wrote a 2d-Gauge for controlling an animation. This is for the Doors.
When I cklicked on the area then the animation is playing, but the image isn`t visible. Who can help me?

Image:
Code:
<Element>
 <Position X="296" Y="132"/>
   <Select>
      <Visible>(K:TOGGLE_AIRCRAFT_EXIT,position)</Visible>
	<Case Value="1">
	    <Image Name="copilot_open.bmp"/>
	</Case>
   </Select>
</Element>

Animation:
Code:
    <Area Left="296" Top="132" Width="69" Height="42">
      <Tooltip>%CoPilot Door(%((K:TOGGLE_AIRCRAFT_EXIT,position))% {if}Open%{else}Closed%{end})</Tooltip>
      <Cursor Type="Hand"/>
      <Click>(K:TOGGLE_AIRCRAFT_EXIT,position) ! (&gt;K:TOGGLE_AIRCRAFT_EXIT,position)</Click>
    </Area>
 
Hi,
I`ve wrote a 2d-Gauge for controlling an animation. This is for the Doors.
When I cklicked on the area then the animation is playing, but the image isn`t visible. Who can help me?

Image:
Code:
<Element>
 <Position X="296" Y="132"/>
   <Select>
      <Visible>[COLOR="Red"](K:TOGGLE_AIRCRAFT_EXIT,position)[/COLOR]</Visible>
	<Case Value="1">
	    <Image Name="copilot_open.bmp"/>
	</Case>
   </Select>
</Element>

Animation:
Code:
    <Area Left="296" Top="132" Width="69" Height="42">
      <Tooltip>%CoPilot Door(%([COLOR="red"](K:TOGGLE_AIRCRAFT_EXIT,position)[/COLOR])% {if}Open%{else}Closed%{end})</Tooltip>
      <Cursor Type="Hand"/>
      <Click>(K:TOGGLE_AIRCRAFT_EXIT,position) ! (&gt;K:TOGGLE_AIRCRAFT_EXIT,position)</Click>
    </Area>

First, you need to use the "read variable" A: for the image. K: are commands...

Secondly, you only need to send the command once, because it is a TOGGLE. Click once to turn on, click again to turn off.

Code:
<Element>
 <Position X="296" Y="132"/>
   <Select>
      <Visible>(A:EXIT OPEN:1,bool)</Visible>
	<Case Value="1">
	    <Image Name="copilot_open.bmp"/>
	</Case>
   </Select>
</Element>
Code:
    <Area Left="296" Top="132" Width="69" Height="42">
      <Tooltip>%CoPilot Door(%([COLOR="red"](A:EXIT OPEN:1,bool)[/COLOR])% {if}Open%{else}Closed%{end})</Tooltip>
      <Cursor Type="Hand"/>
      <Click>(>K:TOGGLE_AIRCRAFT_EXIT)</Click>
    </Area
 
Thirdly: You need to change your avatar if you expect more help.

I doubt that I am the only here who finds it offensive.
 
it works great. thanks.

I'm sorry if I offended you avatar. It will not be offensive. I did this for years. So far, no one has complained. it looks funny and even to laugh sometimes
 
Well, I consider it offensive also, and not because it's pointed towards Microsoft. It's an extremely rude gesture all by itself.

Despite that however, I didn't allow it to affect my decision to help... :tongue-ti
 
Code:
    <Area Left="296" Top="132" Width="69" Height="42">
      <Tooltip>%CoPilot Door(%([COLOR="red"](A:EXIT OPEN:1,bool)[/COLOR])% {if}Open%{else}Closed%{end})</Tooltip>
      <Cursor Type="Hand"/>
      <Click>(>K:TOGGLE_AIRCRAFT_EXIT)</Click>
    </Area

I discovered a small error. the red-marked must be in the code, otherwise no animation is triggered.
your code:
Code:
    <Area Left="296" Top="132" Width="69" Height="42">
      <Tooltip>%CoPilot Door(%([COLOR="red"](A:EXIT OPEN:1,bool)[/COLOR])% {if}Open%{else}Closed%{end})</Tooltip>
      <Cursor Type="Hand"/>
      <Click>(>K:TOGGLE_AIRCRAFT_EXIT)</Click>
    </Area>

working code:

Code:
    <Area Left="296" Top="132" Width="69" Height="42">
      <Tooltip>%CoPilot Door(%([COLOR="red"](A:EXIT OPEN:0,bool)[/COLOR])% {if}Open%{else}Closed%{end})</Tooltip>
      <Cursor Type="Hand"/>
      <Click>(K:TOGGLE_AIRCRAFT_EXIT,position) ! (&gt;K:TOGGLE_AIRCRAFT_EXIT,position)</Click>
    </Area>
 
Well, how about that. Technically speaking, it's not an error, as EXIT OPEN:1 is door #2 (copilot's door).

The corrected command for opening door #2 (EXIT OPEN:1) is:

Code:
<Click>(>K:TOGGLE_AIRCRAFT_EXIT) 2 (>K:SELECT)</Click>

which is the equivalent of using the keyboard Ctrl-E, 2... ;)

There are a total of four possible doors in FS. Here is a chart with the read variables and the associated K: command sequences for each:
Code:
              Read Variable                     K: Command Sequence
======================================================================================

Door #1  (A:EXIT OPEN:0,bool)          (>K:TOGGLE_AIRCRAFT_EXIT)

Door #2  (A:EXIT OPEN:1,bool)          (>K:TOGGLE_AIRCRAFT_EXIT) 2 (>K:SELECT)

Door #3  (A:EXIT OPEN:2,bool)          (>K:TOGGLE_AIRCRAFT_EXIT) 3 (>K:SELECT)

Door #4  (A:EXIT OPEN:3,bool)          (>K:TOGGLE_AIRCRAFT_EXIT) 4 (>K:SELECT)
 
Back
Top