I've added the option to replicate two MDU displays into full canvas windows, so you can monitor flight performance while in outside or FG HUD view.
The code to do that seems simple enough:
- Code: Select all
var create_MDU_clone = func (index) {
if (index == 0) {string = "CDR1";}
else if (index == 1) {string = "CDR2";}
var window = canvas.Window.new([512,512],"dialog").set("title", string);
var canvas_clone = SpaceShuttle.MDU_array[index].PFD._canvas;
window.setCanvas(canvas_clone);
}
Works like a charm. However, when I have such windows active, the on-screen messaging system breaks and reports an error from screen.nas about 'trim' not being a valid member. So... it seems something here interferes badly.
To replicate:
* start SpaceShuttle-orbit
* use SpaceShuttle -> clone CDR-1 MDU to get the canvas window open
* press 'd' to disconnect the ET (that triggers a message) - watch the message not appear and the console error