DragonflightDesign
Resource contributor
- Messages
- 1,371
- Country

I really have no idea where to put this thread, so here seems as good a place as any.
I've been told by one modeller that it isn't possible to add dynamic tooltips to a VC clickspot, but I'm also being told by a user that he has seen them. So if this is the modeldef code for the rudder trim (yes Roman - you have seen this before!
)
- how do I add L:RudderTrimPos to the tooltip? And no, I have almost no idea what I'm doing when it comes to programming the modeldef.
I've been told by one modeller that it isn't possible to add dynamic tooltips to a VC clickspot, but I'm also being told by a user that he has seen them. So if this is the modeldef code for the rudder trim (yes Roman - you have seen this before!
Code:
<PartInfo>
<Name>RudderWheel</Name>
<AnimLength>360</AnimLength>
<Animation>
<Parameter>
<Code>
(L:RudderWheel, number) 225 + 45 % 8 * 0 max 360 min
</Code>
</Parameter>
</Animation>
<MouseRect>
<Cursor>Hand</Cursor>
<MouseFlags>LeftSingle+LeftDrag</MouseFlags>
<CallbackCode>
-20 20 (L:RudderTrimPos, number) rng (M:Event) 'LeftSingle' scmp 0 == and
if{
(M:X) (>L:MouseX32, number)
(M:Y) (>L:MouseY32, number)
(L:RudderWheel, number) 0.1111111 * -20 max 20 min (>L:RudderTrimPos, number)
}
-20 20 (L:RudderTrimPos, number) rng (M:Event) 'LeftDrag' scmp 0 == and
if{
(L:RudderWheel, number) (M:X) (L:MouseX32, number) - 0.05 * + -180 max 180 min (>L:RudderWheel, number) (M:X) (>L:MouseX32, number)
(L:RudderWheel, number) (M:Y) (L:MouseY32, number) - 0.05 * + -180 max 180 min (>L:RudderWheel, number) (M:Y) (>L:MouseY32, number)
(L:RudderWheel, number) 0.1111111 * -20 max 20 min (>L:RudderTrimPos, number)
}
</CallbackCode>
<TooltipText>Rudder Trim Wheel</TooltipText>
</MouseRect>
</PartInfo>



