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

Animated Drums for Engine Time

Messages
683
Country
us-california
I have been through the forums here and came up with codes for the drums that work. I even have them set up to only roll from 9-0 via keyframes. My Problem is that the only one that times properly is the hundredths drum. With the rpm high that drum shifts a digit every 36 seconds, and the shift is good in terms of speed. The tenths drum will start to shift as soon as the hundredths drum hits nine, and slowly completes it's shift as the hundredths drum goes back to 0. The problem just gets worse as you work through the other drums. Here's what I am using...

Code:
<!-- Tach Drums -->

<Animation name="Engine_Time_Hundredths" guid="A3B58E32-A4E1-5384-5C72-1AFD1C5AEFC4" length="100" type="Sim" typeParam2="Engine_Time_Hundredths" typeParam="AutoPlay" />
<PartInfo>
  <Name>Engine_Time_Hundredths</Name>
    <AnimLength>100</AnimLength>
      <Animation>
        <Parameter>
            <Code>(A:GENERAL ENG ELAPSED TIME:1, hours) 100 * 10 % 10 * </Code>
        </Parameter>
      </Animation>
</PartInfo>

<Animation name="Engine_Time_Tenths" guid="A3B58E32-A4E1-6384-5C72-1AFD1C5AEFC4" length="100" type="Sim" typeParam2="Engine_Time_Tenths" typeParam="AutoPlay" />
<PartInfo>
  <Name>Engine_Time_Tenths</Name>
    <AnimLength>100</AnimLength>
      <Animation>
        <Parameter>
            <Code>(A:GENERAL ENG ELAPSED TIME:1, hours) 10 * 10 % 10 * </Code>
        </Parameter>
      </Animation>
</PartInfo>

<Animation name="Engine_Time_Ones" guid="A3B58E32-A4E1-3285-5C72-1AFD1C5AEFC4" length="100" type="Sim" typeParam2="Engine_Time_Ones" typeParam="AutoPlay" />
<PartInfo>
  <Name>Engine_Time_Ones</Name>
    <AnimLength>100</AnimLength>
      <Animation>
        <Parameter>
            <Code>(A:GENERAL ENG ELAPSED TIME:1, hours) 10 % 10 * </Code>
        </Parameter>
      </Animation>
</PartInfo>

<Animation name="Engine_Time_Tens" guid="A3B58E32-A4E1-6397-5C72-1AFD1C5AEFC4" length="100" type="Sim" typeParam2="Engine_Time_Tens" typeParam="AutoPlay" />
<PartInfo>
  <Name>Engine_Time_Tens</Name>
    <AnimLength>100</AnimLength>
      <Animation>
        <Parameter>
            <Code>(A:GENERAL ENG ELAPSED TIME:1, hours) 10 / 10 % 10 * </Code>
        </Parameter>
      </Animation>
</PartInfo>

<Animation name="Engine_Time_Hundreds" guid="A3B58E32-A4E1-6987-5C72-1AFD1C5AEFC4" length="100" type="Sim" typeParam2="Engine_Time_Hundreds" typeParam="AutoPlay" />
<PartInfo>
  <Name>Engine_Time_Hundreds</Name>
    <AnimLength>100</AnimLength>
      <Animation>
        <Parameter>
            <Code>(A:GENERAL ENG ELAPSED TIME:1, hours) 100 / 10 % 10 * </Code>
        </Parameter>
      </Animation>
</PartInfo>

<Animation name="Engine_Time_Thousand" guid="A3B58E32-A4E1-6347-5C72-1AFD1C5AEFC4" length="100" type="Sim" typeParam2="Engine_Time_Thousand" typeParam="AutoPlay" />
<PartInfo>
  <Name>Engine_Time_Thousand</Name>
    <AnimLength>100</AnimLength>
      <Animation>
        <Parameter>
            <Code>(A:GENERAL ENG ELAPSED TIME:1, hours) 1000 / 10 % 10 * </Code>
        </Parameter>
      </Animation>
 
Messages
917
Country
indonesia
you need to zeroed ( floor ) for shift, otherwise it will start shift after +0.5 value
 

n4gix

Resource contributor
Messages
11,674
Country
unitedstates
Bob, try using this script. Only the tenths digit "rolls constantly".
The (L:B737_APU_Hobbs, enum) may be substituted with (A:GENERAL ENG ELAPSED TIME:1, hours)
The /flr causes the rest of the drums to only roll over when the next lower digit goes from 9 to 0.

EDIT: You may only need to add /flr to all but the hundredths drum in your existing script.

XML:
  <PartInfo>
    <Name>B737_APU_Hobbs_10000</Name>
    <AnimLength>10</AnimLength>
    <Animation>
      <Parameter>
        <Code>(L:B737_APU_Hobbs,enum) 99999 min 0 max 100000 % 10000 / flr</Code>
      </Parameter>
      <Lag>30</Lag>
    </Animation>
  </PartInfo>

  <PartInfo>
    <Name>B737_APU_Hobbs_1000</Name>
    <AnimLength>10</AnimLength>
    <Animation>
      <Parameter>
        <Code>(L:B737_APU_Hobbs,enum) 99999 min 0 max 10000 % 1000 / flr</Code>
      </Parameter>
      <Lag>30</Lag>
    </Animation>
  </PartInfo>

  <PartInfo>
    <Name>B737_APU_Hobbs_100</Name>
    <AnimLength>10</AnimLength>
    <Animation>
      <Parameter>
        <Code>(L:B737_APU_Hobbs,enum) 99999 min 0 max 1000 % 100 / flr</Code>
      </Parameter>
      <Lag>30</Lag>
    </Animation>
  </PartInfo>

  <PartInfo>
    <Name>B737_APU_Hobbs_10</Name>
    <AnimLength>10</AnimLength>
    <Animation>
      <Parameter>
        <Code>(L:B737_APU_Hobbs,enum) 99999 min 0 max 100 % 10 / flr</Code>
      </Parameter>
      <Lag>30</Lag>
    </Animation>
  </PartInfo>

  <PartInfo>
    <Name>B737_APU_Hobbs_1</Name>
    <AnimLength>10</AnimLength>
    <Animation>
      <Parameter>
        <Code>(L:B737_APU_Hobbs,enum) 99999 min 0 max 10 % 1 / flr</Code>
      </Parameter>
      <Lag>30</Lag>
    </Animation>
  </PartInfo>

  <PartInfo>
    <Name>B737_APU_Hobbs_01</Name>
    <AnimLength>100</AnimLength>
    <Animation>
      <Parameter>
        <Code>(L:B737_APU_Hobbs,enum) s2 l2 int - 100 *</Code>
      </Parameter>
      <Lag>30</Lag>
    </Animation>
  </PartInfo>
 
Last edited:

n4gix

Resource contributor
Messages
11,674
Country
unitedstates
I assume it was the "/flr" that is all that was missing?
 
Top