1
0
Fork 0

Add CG-MAC to weights dialog

Patch from Huntley Palmer
This commit is contained in:
James Turner 2023-11-11 14:19:11 +00:00
parent 9242e133fd
commit 53a6e3b8f8

View file

@ -817,9 +817,10 @@ var showWeightDialog = func {
# FDM dependent settings
if(fdm == "yasim") {
var fdmdata = {
grosswgt : "/yasim/gross-weight-lbs",
grosswgt : "/fdm/yasim/gross-weight-lbs",
payload : "/sim",
cg : "/fdm/yasim/cg-x-m",
cgMAC : "/fdm/yasim/cg-x-mac",
};
setprop("/limits/mass-and-balance/cg/dimension","m");
} elsif(fdm == "jsb") {
@ -827,6 +828,7 @@ var showWeightDialog = func {
grosswgt : "/fdm/jsbsim/inertia/weight-lbs",
payload : "/payload",
cg : "/fdm/jsbsim/inertia/cg-x-in",
cgMAC : nil,
};
}
@ -884,6 +886,10 @@ var showWeightDialog = func {
tablerow("Center of Gravity", props.globals.getNode(fdmdata.cg), "%.2f " ~ (n == nil ? "in" : n.getValue()));
}
if( fdmdata.cgMAC != nil ) {
tablerow("CoG vs Mean Aero Chord", props.globals.getNode(fdmdata.cgMAC), "%.2f " );
}
dialog[name].addChild("hrule");
var buttonBar = dialog[name].addChild("group");