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

Saving modeldef

Messages
306
Country
unitedstates
I have a issue with the modeldef not saving what I change. I have tried several times to change the length to 200, but when I recheck it goes back to the original 100. Also in the same instance of saving I added the line <Scale>200</Scale> and it saved that .........
<Animation name="custom_anim_EXIT_OPEN_1_00" guid="0420a34e-c366-4b1f-bbcc-a32bfcd17c87" typeParam2="custom_anim_EXIT_OPEN_1_00" length="200" type="Sim" typeParam="AutoPlay" />
<PartInfo>
<Name>custom_anim_EXIT_OPEN_1_00</Name>
<AnimLength>200</AnimLength>
<Animation>
<Parameter>
<Sim>
<Variable>WATER RUDDER HANDLE POSITION</Variable>
<Units>percent</Units>
<Scale>200</Scale>
</Sim>
</Parameter>
</Animation>
</PartInfo>
 
I'm no expert on modeldef.xml, but I found the same problem when I tried to slow down some animation:


It seems some animations can't be changed. You have to copy them to a different name and then link that to your model.
 
I'm no expert on modeldef.xml, but I found the same problem when I tried to slow down some animation:


It seems some animations can't be changed. You have to copy them to a different name and then link that to your model.
You mean change the name (custom_anim_EXIT_OPEN_1_00) to say water rudder lever??? This plane has 2 canopies and on planes with just 1 I have got to work .
 
Just can't understand what you wanted to do.
What kind of animation you want to make?

To add a animation, not only the code part , you need to write the register part on modeldef.xml
 
Just can't understand what you wanted to do.
What kind of animation you want to make?

To add a animation, not only the code part , you need to write the register part on modeldef.xml
I'm trying to get the canopies to open. Everything I've done works fine on other planes except for this F-4 with s canopies.
 
Canopies open by a WATER RUDDER HANDLE POSITION ?

Why not using default exit codes ..
Or you already used EXIT 1 to 4 ??
 
This is in a converted plane in MSFS2020 if that makes a difference. This is the code in the F-100 and all I did was change the animation in the Heiarchy editor and it works fine. I was thinking if I use this in the F-4 could that work??
<Animation name="custom_anim_EXIT_OPEN_0_03" guid="9b5ed86c-b114-4924-b5c9-163a99042f2f" typeParam2="custom_anim_EXIT_OPEN_0_03" length="100" type="Sim" typeParam="AutoPlay" />
<PartInfo>
<Name>custom_anim_EXIT_OPEN_0_03</Name>
<AnimLength>100</AnimLength>
<Animation>
<Parameter>
<Sim>
<Variable>EXIT OPEN:0</Variable>
<Units>percent</Units>
</Sim>
</Parameter>
</Animation>
</PartInfo>


NOTE This is the added water rudder code
<Animation name="lever_water_rudder" guid="7f3487ca-73ca-446d-b738-b5e3a6c9cdee" length="100" type="Sim" typeParam2="lever_water_rudder" typeParam="AutoPlay" />
<PartInfo>
<Name>lever_water_rudder</Name>
<AnimLength>100</AnimLength>
<Animation>
<Parameter>
<Sim>
<Variable>WATER RUDDER HANDLE POSITION</Variable>
<Units>percent</Units>
<Scale>100</Scale>
<Bias>0</Bias>
</Sim>
<Lag>20</Lag>
</Parameter>
</Animation>
<MouseRect>
<Cursor>Hand</Cursor>
<HelpID>HELPID_GAUGE_WATER_RUDDER_LEVER</HelpID>
<TooltipID>TOOLTIPTEXT_WATER_RUDDER_HANDLE</TooltipID>
<EventID>TOGGLE_WATER_RUDDER</EventID>
</MouseRect>
</PartInfo>
 
You mean change the name (custom_anim_EXIT_OPEN_1_00) to say water rudder lever??? This plane has 2 canopies and on planes with just 1 I have got to work .
I think you can change the name if you're sure you don't have (and never will have) another model which will reference that animation. But safer to make a copy of it and change the name in the copy. You have to copy/create the "Animation Name" entry and the "PartInfo" Entry in modeldef for the animation.
 
Under is the FSX Microsoft default modeldef.xml's canopy part.
At the top links Animation name to GUID and several other info.
And at each animation just reading the variables.


<Animation name="f_canopy" guid="AD1B3466-C52F-4885-9EDE-3DDC15A1587A" length="100" type="Sim" typeparam2="f_canopy" typeparam="AutoPlay" />
<Animation name="r_canopy" guid="0420A34E-C366-4b1f-BBCC-A32BFCD17C87" length="100" type="Sim" typeparam2="r_canopy" typeparam="AutoPlay" />


<PartInfo>
<Name>f_canopy</Name>
<AnimLength>100</AnimLength>
<Animation>
<Parameter>
<Sim>
<Variable>EXIT OPEN:0</Variable>
<Units>percent</Units>
</Sim>
</Parameter>
</Animation>
</PartInfo>

<PartInfo>
<Name>r_canopy</Name>
<AnimLength>100</AnimLength>
<Animation>
<Parameter>
<Sim>
<Variable>EXIT OPEN:1</Variable>
<Units>percent</Units>
</Sim>
</Parameter>
</Animation>
</PartInfo>
 
I assume you have changed both canopies in the model to reference the "lever_water_rudder" animation ?

I should say that my changes were for FSX. MSFS may be different.
 
I assume you have changed both canopies in the model to reference the "lever_water_rudder" animation ?

I should say that my changes were for FSX. MSFS may be different.
Yes I think I will try and use the ones posted above and see if that works.
 
Didn't work plane came in with canopy stuck half open...I checked the modeldef and it didn't change to the one I added....
 
Half open means code itself is working.
Isn't your animation from 0 to 200?

Animation length is 100 as written under so needs to match.
<Animation name="f_canopy" guid="AD1B3466-C52F-4885-9EDE-3DDC15A1587A" length="100" type="Sim" typeparam2="f_canopy" typeparam="AutoPlay" />

Write a 0 - 200 animation code or shrink the animation to 0-100
 
Last edited:
How about a code like under.
Will multiply (A:EXIT OPEN:0, percent) and will give 0 - 200


<PartInfo>
<Name>EXAMPLE_200EXIT</Name>
<AnimLength>200</AnimLength>
<Animation>
<Parameter>
<Code>
(A:EXIT OPEN:0, percent) 2 *
</Code>
<Lag>100</Lag>
</Parameter>
</Animation>
</PartInfo>
 
Last edited:
How about a code like under.
Will multiply (A:EXIT OPEN:0, percent) and will give 0 - 200


<PartInfo>
<Name>EXAMPLE_200EXIT</Name>
<AnimLength>200</AnimLength>
<Animation>
<Parameter>
<Code>
(A:EXIT OPEN:0, percent) 2 *
</Code>
<Lag>100</Lag>
</Parameter>
</Animation>
</PartInfo>
thanks its working now
 
Anyway good news it worked.

Making a code itself is not really difficult
Only difficult part is can be sure it works or not.
So I use a debug guage like under and write the code and check at the panel.
I don't know how it works at FS2020 but this is how check the XML codes


<Gauge Name="Poskydebug" Version="1.0">
<Size X="102" Y="102"/>

<Element>
<Position X="32" Y="35"/>
<Text X="70" Y="18" Bright="Yes" Length="5" Font="Quartz" Color="#FBDFC3" Adjust="center" VerticalAdjust="Bottom" Multiline="No" Bold="Yes">
<String>%(


(A:EXIT OPEN:0, percent) 2 *


)%!3d!</String>
</Text>
</Element>
</Gauge>
 
Back
Top