- Messages
- 95
- Country

Hey all,
I have an old style com radio in my plane with knobs and drums etc... Can't for the life of me figure why the com1 knobs (Mhz and KHz) won't rotate the com1 drums... instead, they rotate the com1 standby drums... Here's the code for the MHz knob and the second and third MHz drums... (the first drum is always a '1' so never mind that one). If somebody could look it over for an error I'd really appreciate it...
Thanks.
Skip.
And the drums....
Here's two com1 standby drums that rotate instead.....
I have an old style com radio in my plane with knobs and drums etc... Can't for the life of me figure why the com1 knobs (Mhz and KHz) won't rotate the com1 drums... instead, they rotate the com1 standby drums... Here's the code for the MHz knob and the second and third MHz drums... (the first drum is always a '1' so never mind that one). If somebody could look it over for an error I'd really appreciate it...
Thanks.
Skip.
Code:
<PartInfo>
<Name>LJ35_COM1_knob_MHz</Name>
<AnimLength>180</AnimLength>
<Animation>
<Parameter>
<Code>(L:LJ35_COM1MHzKnob, number)</Code>
</Parameter>
</Animation>
<MouseRect>
<Cursor>Hand</Cursor>
<TooltipText>COM1 MHz Knob</TooltipText>
<MouseFlags>LeftSingle+RightSingle+WheelUp+WheelDown</MouseFlags>
<CallbackCode>
(M:Event) 'LeftSingle' scmp 0 == if{ (L:LJ35_COM1MHzKnob, number) 0 > if{ (L:LJ35_COM1MHzKnob, number) 1 - (>L:LJ35_COM1MHzKnob, number) } els{ 99 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 10 - (>L:LJ35_COM1MHzKnob, number)
(L:LJ35_COM1MHzKnob, number) 180 > if{ 0 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 0 < if{ 180 (>L:LJ35_COM1MHzKnob, number) }
1 (>K:COM_RADIO_WHOLE_DEC)
}
(M:Event) 'RightSingle' scmp 0 == if{ (L:LJ35_COM1MHzKnob, number) 99 < if{ (L:LJ35_COM1MHzKnob, number) 1 + (>L:LJ35_COM1MHzKnob, number) } els{ 0 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 10 + (>L:LJ35_COM1MHzKnob, number)
(L:LJ35_COM1MHzKnob, number) 180 > if{ 0 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 0 < if{ 180 (>L:LJ35_COM1MHzKnob, number) }
1 (>K:COM_RADIO_WHOLE_INC)
}
(M:Event) 'WheelDown' scmp 0 == if{ (L:LJ35_COM1MHzKnob, number) 0 > if{ (L:LJ35_COM1MHzKnob, number) 1 - (>L:LJ35_COM1MHzKnob, number) } els{ 99 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 10 - (>L:LJ35_COM1MHzKnob, number)
(L:LJ35_COM1MHzKnob, number) 180 > if{ 0 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 0 < if{ 180 (>L:LJ35_COM1MHzKnob, number) }
1 (>K:COM_RADIO_WHOLE_DEC)
}
(M:Event) 'WheelUp' scmp 0 == if{ (L:LJ35_COM1MHzKnob, number) 99 < if{ (L:LJ35_COM1MHzKnob, number) 1 + (>L:LJ35_COM1MHzKnob, number) } els{ 0 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 10 + (>L:LJ35_COM1MHzKnob, number)
(L:LJ35_COM1MHzKnob, number) 180 > if{ 0 (>L:LJ35_COM1MHzKnob, number) }
(L:LJ35_COM1MHzKnob, number) 0 < if{ 180 (>L:LJ35_COM1MHzKnob, number) }
1 (>K:COM_RADIO_WHOLE_INC)
}
</CallbackCode>
</MouseRect>
</PartInfo>
And the drums....
Code:
<PartInfo>
<Name>cylinder_com1_dig2</Name>
<AnimLength>90</AnimLength>
<Animation>
<Parameter>
<Code>(A:COM ACTIVE FREQUENCY:1, MHz) 10 / 10 % int 10 *</Code>
</Parameter>
</Animation>
</PartInfo>
<PartInfo>
<Name>cylinder_com1_dig3</Name>
<AnimLength>90</AnimLength>
<Animation>
<Parameter>
<Code>(A:COM ACTIVE FREQUENCY:1, MHz) 10 % int 10 *</Code>
</Parameter>
</Animation>
</PartInfo>
Here's two com1 standby drums that rotate instead.....
Code:
<PartInfo>
<Name>cylinder_com1B_dig2</Name>
<AnimLength>90</AnimLength>
<Animation>
<Parameter>
<Code>(A:COM STANDBY FREQUENCY:1, MHz) 10 / 10 % int 10 *</Code>
</Parameter>
</Animation>
</PartInfo>
<PartInfo>
<Name>cylinder_com1B_dig3</Name>
<AnimLength>90</AnimLength>
<Animation>
<Parameter>
<Code>(A:COM STANDBY FREQUENCY:1, MHz) 10 % int 10 *</Code>
</Parameter>
</Animation>
</PartInfo>

