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.

<?xml version="1.0" encoding="UTF-8"?>
<SimBase.Document Type="AceXML" version="1,0" id="F1EE Radar">
<Descr>P3DRadarTexture</Descr>
<SimGauge.Gauge id="Gauge" ArtDirectory="C:\Prepar3D\SDK\Panels and User Interface\Panels\XML Gauge samples">
<FloatPosition>0.000,0.000</FloatPosition>
<Size>1024,1024</Size>
<Element FloatPosition="1.000,1.000">
<Visibility>(L:ELEC_AC_MAIN1_BUS, Bool)</Visibility>
<Texture Name="P3DRadarTexture" Width="1024" Height="1024" />
</Element>
<MouseArea id="MouseArea all">
<FloatPosition>0.000,0.000</FloatPosition>
<Size>1024,1024</Size>
<CursorType>Normal</CursorType>
<MouseArea>
<FloatPosition>1.0,1.0</FloatPosition>
<Size>1024,1024</Size>
<CursorType>Hand</CursorType>
<MouseClick id="MouseClick">
<Script>!lua
.
(your code)
.
</Script>
<ClickType>WheelUp+WheelDown+LeftSingle+LeftDrag+LeftRelease</ClickType>
</MouseClick>
</MouseArea>
</MouseArea>
I'm not sure if i understand well your question, but in the understanding that you lua script is inside an xml file .. them you only need to add a line on the panel.cfg like any other xml gauge. take look on the tipical example about P3DRadar
Code:<?xml version="1.0" encoding="UTF-8"?> <SimBase.Document Type="AceXML" version="1,0" id="F1EE Radar"> <Descr>P3DRadarTexture</Descr> <SimGauge.Gauge id="Gauge" ArtDirectory="C:\Prepar3D\SDK\Panels and User Interface\Panels\XML Gauge samples"> <FloatPosition>0.000,0.000</FloatPosition> <Size>1024,1024</Size> <Element FloatPosition="1.000,1.000"> <Visibility>(L:ELEC_AC_MAIN1_BUS, Bool)</Visibility> <Texture Name="P3DRadarTexture" Width="1024" Height="1024" /> </Element> <MouseArea id="MouseArea all"> <FloatPosition>0.000,0.000</FloatPosition> <Size>1024,1024</Size> <CursorType>Normal</CursorType> <MouseArea> <FloatPosition>1.0,1.0</FloatPosition> <Size>1024,1024</Size> <CursorType>Hand</CursorType> <MouseClick id="MouseClick"> <Script>!lua . (your code) . </Script> <ClickType>WheelUp+WheelDown+LeftSingle+LeftDrag+LeftRelease</ClickType> </MouseClick> </MouseArea> </MouseArea>
The entire thing is LUA script now. I did it in air manager but trying to figure out how to convert it to usable in a vc in msfs.I'm not sure if i understand well your question, but in the understanding that you lua script is inside an xml file .. them you only need to add a line on the panel.cfg like any other xml gauge. take look on the tipical example about P3DRadar
Code:<?xml version="1.0" encoding="UTF-8"?> <SimBase.Document Type="AceXML" version="1,0" id="F1EE Radar"> <Descr>P3DRadarTexture</Descr> <SimGauge.Gauge id="Gauge" ArtDirectory="C:\Prepar3D\SDK\Panels and User Interface\Panels\XML Gauge samples"> <FloatPosition>0.000,0.000</FloatPosition> <Size>1024,1024</Size> <Element FloatPosition="1.000,1.000"> <Visibility>(L:ELEC_AC_MAIN1_BUS, Bool)</Visibility> <Texture Name="P3DRadarTexture" Width="1024" Height="1024" /> </Element> <MouseArea id="MouseArea all"> <FloatPosition>0.000,0.000</FloatPosition> <Size>1024,1024</Size> <CursorType>Normal</CursorType> <MouseArea> <FloatPosition>1.0,1.0</FloatPosition> <Size>1024,1024</Size> <CursorType>Hand</CursorType> <MouseClick id="MouseClick"> <Script>!lua . (your code) . </Script> <ClickType>WheelUp+WheelDown+LeftSingle+LeftDrag+LeftRelease</ClickType> </MouseClick> </MouseArea> </MouseArea>

Ok I’ll give it a look. This is for fs2020/2024 My lua script is based on referencing pngs in a resource file. Does the xml allow for that? I’m still incredibly new to all this but have managed to get this 700+ line code to work great.In my understanding you can only introduce in VC an xml or dll/gau gauge... so you need to revise the way where a xml with lua script inside on the P3D examples .. for instance the radar example or the clock example on this link
https://www.prepar3d.com/SDKv3/LearningCenter/utilities/scripting/lua_scripting.html
