diff --git a/A320-main.xml b/A320-main.xml index 21e790f2..cd98de39 100644 --- a/A320-main.xml +++ b/A320-main.xml @@ -55,7 +55,9 @@ The Airbus A320 is a family of narrow body airliners built by Airbus Industrie. First flown in 1987, the aircraft is the most produced airliner ever, with over 9,500 built to date. It was one of the first airliners to use digital flight controls and fly by wire, and a fully glass cockpit. - + + A320-family + false false @@ -574,7 +576,7 @@ 300.0 - 2019.2.0 + 2020.3.12 3000 diff --git a/Models/Instruments/MCDU/MCDU.nas b/Models/Instruments/MCDU/MCDU.nas index 64ddb90a..f3ea9547 100644 --- a/Models/Instruments/MCDU/MCDU.nas +++ b/Models/Instruments/MCDU/MCDU.nas @@ -442,6 +442,32 @@ var canvas_MCDU_base = { me["Simple_R5S"].setFont("HoneywellMCDUSmall.ttf"); me["Simple_R5S"].setFontSize(small); } + if (page == "RECEIVEDMSG" or page == "ATISDETAIL") { + if (page == "RECEIVEDMSG") { + me["Simple_L2S"].setFontSize(normal); + me["Simple_L3S"].setFontSize(normal); + me["Simple_L4S"].setFontSize(normal); + me["Simple_L5S"].setFontSize(normal); + } else { + me["Simple_L2S"].setFontSize(small); + me["Simple_L3S"].setFontSize(small); + me["Simple_L4S"].setFontSize(small); + me["Simple_L5S"].setFontSize(small); + } + me["Simple_L2S"].setFont("HoneywellMCDU.ttf"); + me["Simple_L3S"].setFont("HoneywellMCDU.ttf"); + me["Simple_L4S"].setFont("HoneywellMCDU.ttf"); + me["Simple_L5S"].setFont("HoneywellMCDU.ttf"); + } else { + me["Simple_L2S"].setFont("HoneywellMCDUSmall.ttf"); + me["Simple_L2S"].setFontSize(small); + me["Simple_L3S"].setFont("HoneywellMCDUSmall.ttf"); + me["Simple_L3S"].setFontSize(small); + me["Simple_L4S"].setFont("HoneywellMCDUSmall.ttf"); + me["Simple_L4S"].setFontSize(small); + me["Simple_L5S"].setFont("HoneywellMCDUSmall.ttf"); + me["Simple_L5S"].setFontSize(small); + } if (page == "IRSMON") { me["Simple_R1S"].setFont("HoneywellMCDU.ttf"); me["Simple_R1S"].setFontSize(normal); @@ -941,11 +967,11 @@ var canvas_MCDU_base = { me["Simple_L1"].setText(" WEATHER TYPE"); me["Simple_L1S"].setText(" " ~ atsu.AOC.selectedType); - me["Simple_R1S"].setText("STA 1 "); - me["Simple_R2"].setText("[ ]"); - me["Simple_R2S"].setText("STA 2 "); - me["Simple_R3"].setText("[ ]"); - me["Simple_R3S"].setText("STA 3 "); + me["Simple_R1S"].setText("STA 1"); + me["Simple_R2"].setText("[ ]"); + me["Simple_R2S"].setText("STA 2"); + me["Simple_R3"].setText("[ ]"); + me["Simple_R3S"].setText("STA 3"); pageSwitch[i].setBoolValue(1); } @@ -964,7 +990,7 @@ var canvas_MCDU_base = { } } else { me["Simple_R5"].setText("SEND "); - me["Simple_R1"].setText("[ ]"); + me["Simple_R1"].setText("[ ]"); me["WEATHERREQSEND"].hide(); } @@ -1029,12 +1055,8 @@ var canvas_MCDU_base = { if (mcdu.ReceivedMessagesDatabase.getCountPages() > 1) { me["Simple_PageNum"].show(); me["Simple_PageNum"].setText(myReceivedMessages[i].getPageNumStr()); - me["ArrowLeft"].show(); - me["ArrowRight"].show(); } else { me["Simple_PageNum"].hide(); - me["ArrowLeft"].hide(); - me["ArrowRight"].hide(); } me.dynamicPageArrowFunc(myReceivedMessages[i]); @@ -1069,7 +1091,7 @@ var canvas_MCDU_base = { me["Simple_C3B"].hide(); me["Simple_C4B"].hide(); - me.fontSizeLeft(small, small, small, small, small, normal); + me.fontSizeLeft(normal, normal, normal, normal, normal, normal); me.fontSizeCenter(normal, normal, normal, normal, normal, normal); me.fontSizeRight(normal, normal, normal, normal, normal, normal); @@ -4145,7 +4167,7 @@ var canvas_MCDU_base = { me["Simple_C1S"].setText("FLP RETR"); me["Simple_C2S"].setText("SLT RETR"); - me["Simple_C3S"].setText("CLEAN "); + me["Simple_C3S"].setText(" CLEAN"); } else if (page == "PERFCLB") { if (!pageSwitch[i].getBoolValue()) { @@ -4622,7 +4644,7 @@ var canvas_MCDU_base = { } me["Simple_L0S"].setText("DEST"); - me["Simple_L1S"].setText("QNH"); + me["Simple_L1S"].setText(" QNH"); if (dest_qnh.getValue() != -1) { if (dest_qnh.getValue() < 100) { me["Simple_L1"].setText(sprintf("%4.2f", dest_qnh.getValue())); @@ -4630,7 +4652,7 @@ var canvas_MCDU_base = { me["Simple_L1"].setText(sprintf("%4.0f", dest_qnh.getValue())); } } else { - me["Simple_L1"].setText("[ ] "); + me["Simple_L1"].setText("[ ]"); } me["Simple_L2S"].setText("TEMP"); @@ -4643,9 +4665,7 @@ var canvas_MCDU_base = { me["Simple_L3S"].setText("MAG WIND"); if (fmgc.FMGCInternal.destMagSet and fmgc.FMGCInternal.destWindSet) { me["Simple_L3"].setText(sprintf("%03.0f°", fmgc.FMGCInternal.destMag) ~ sprintf("/%.0f", fmgc.FMGCInternal.destWind)); - me["Simple_L3"].setFontSize(normal); } else { - me["Simple_L3"].setFontSize(small); if (myDESWIND[i] != nil and myDESWIND[i].returnGRND() != nil) { var result = myDESWIND[i].returnGRND(); me["Simple_L3"].setText(sprintf("%03.0f°", result[0]) ~ sprintf("/%.0f", result[1])); @@ -4675,16 +4695,16 @@ var canvas_MCDU_base = { me["Simple_R1"].setColor(WHITE); } - me["Simple_R2S"].setText("BARO"); + me["Simple_R2S"].setText("BARO "); if (getprop("/FMGC/internal/baro") != 99999) { me["Simple_R2"].setText(sprintf("%.0f", getprop("/FMGC/internal/baro"))); me.fontSizeRight(0, normal, 0, 0, 0, 0); } else { - me["Simple_R2"].setText(" [ ]"); + me["Simple_R2"].setText("[ ]"); me.fontSizeRight(0, small, 0, 0, 0, 0); } - me["Simple_R3S"].setText("RADIO"); + me["Simple_R3S"].setText("RADIO "); if (getprop("/FMGC/internal/radio") != 99999) { me["Simple_R3"].setText(sprintf("%.0f", getprop("/FMGC/internal/radio"))); me.fontSizeRight(0, 0, normal, 0, 0, 0); @@ -4692,13 +4712,13 @@ var canvas_MCDU_base = { me["Simple_R3"].setText("NO"); me.fontSizeRight(0, 0, normal, 0, 0, 0); } else { - me["Simple_R3"].setText(" [ ]"); + me["Simple_R3"].setText("[ ]"); me.fontSizeRight(0, 0, small, 0, 0, 0); } - me["Simple_R4S"].setText("LDG CONF "); - me["Simple_R4"].setText("CONF3 "); - me["Simple_R5"].setText("FULL "); + me["Simple_R4S"].setText("LDG CONF "); + me["Simple_R4"].setText("CONF3 "); + me["Simple_R5"].setText("FULL "); if (fmgc.FMGCInternal.ldgConfig3 == 1 and fmgc.FMGCInternal.ldgConfigFull == 0) { me["PERFAPPR_LDG_3"].hide(); me["PERFAPPR_LDG_F"].show(); @@ -4736,15 +4756,15 @@ var canvas_MCDU_base = { me["Simple_L5"].setText(sprintf("%3.0f", fmgc.FMGCInternal.vapp_appr)); me.fontSizeLeft(0, 0, 0, 0, normal, 0); } else { - me["Simple_L5"].setText("[ ] "); + me["Simple_L5"].setText("[ ] "); me.fontSizeLeft(0, 0, 0, 0, small, 0); } } me["Simple_C1S"].setText("FLP RETR"); me["Simple_C2S"].setText("SLT RETR"); - me["Simple_C3S"].setText("CLEAN "); - me["Simple_C5S"].setText("VLS "); + me["Simple_C3S"].setText(" CLEAN"); + me["Simple_C5S"].setText("VLS"); } else if (page == "PERFGA") { if (!pageSwitch[i].getBoolValue()) { @@ -4820,7 +4840,7 @@ var canvas_MCDU_base = { me["Simple_C1S"].setText("FLP RETR"); me["Simple_C2S"].setText("SLT RETR"); - me["Simple_C3S"].setText("CLEAN "); + me["Simple_C3S"].setText(" CLEAN"); } else if (page == "WINDCLB" or page == "WINDCRZ" or page == "WINDDES" or page == "WINDHIST") { if (!pageSwitch[i].getBoolValue()) { me.defaultHideWithCenter(); diff --git a/Nasal/MCDU/MCDU.nas b/Nasal/MCDU/MCDU.nas index b0cac383..440d47b7 100644 --- a/Nasal/MCDU/MCDU.nas +++ b/Nasal/MCDU/MCDU.nas @@ -953,13 +953,19 @@ var rskbutton = func(btn, i) { } else if (page == "AOCMENU") { pageNode[i].setValue("FLTLOG"); } else if (page == "WEATHERREQ") { - var result = atsu.AOC.newStation(mcdu_scratchpad.scratchpads[i].scratchpad, i); - if (result == 1) { - mcdu_message(i, "NOT ALLOWED"); - } elsif (result == 2) { - mcdu_message(i, "NOT IN DATA BASE"); + if (mcdu_scratchpad.scratchpads[i].scratchpad != "CLR") { + var result = atsu.AOC.newStation(mcdu_scratchpad.scratchpads[i].scratchpad, i); + if (result == 1) { + mcdu_message(i, "NOT ALLOWED"); + } elsif (result == 2) { + mcdu_message(i, "NOT IN DATA BASE"); + } else { + mcdu_scratchpad.scratchpads[i].empty(); + } } else { - mcdu_scratchpad.scratchpads[i].empty(); + atsu.AOC.sent = 0; + atsu.AOC.received = 0; + atsu.AOC.station = nil; } } else if (page == "WEATHERTYPE") { atsu.AOC.selectedType = "TERM FCST"; diff --git a/Nasal/MCDU/RECEIVEDMESSAGES.nas b/Nasal/MCDU/RECEIVEDMESSAGES.nas index 63347196..bf6d9279 100644 --- a/Nasal/MCDU/RECEIVEDMESSAGES.nas +++ b/Nasal/MCDU/RECEIVEDMESSAGES.nas @@ -20,7 +20,7 @@ var receivedMessagesPage = { computer: nil, size: 0, getPageNumStr: func() { - return me.curPage ~ "/" ~ ReceivedMessagesDatabase.getCountPages(); + return " " ~ sprintf("%02d",me.curPage) ~ "/" ~ sprintf("%02d",ReceivedMessagesDatabase.getCountPages()); }, new: func(computer) { var ap = {parents:[receivedMessagesPage]}; @@ -61,7 +61,7 @@ var receivedMessagesPage = { me.arrowsMatrix = [[0, 0, 0, 0, 0, 1], [0, 0, 0, 0, 0, 0]]; }, _setupPageWithData: func() { - me.title = "RECEIVED MESSAGES "; + me.title = "ACARS - RCVD MSGS "; me.L6 = [" RETURN", nil, "wht"]; me.arrowsMatrix = [[0, 0, 0, 0, 0, 1], [0, 0, 0, 0, 0, 0]]; me.arrowsColour = [["blu", "blu", "blu", "blu", "blu", "wht"], ["ack", "ack", "ack", "ack", "ack", "ack"]]; @@ -74,60 +74,60 @@ var receivedMessagesPage = { if (me.size >= (me.curPage * 5) + -4) { message = ReceivedMessagesDatabase.database.vector[-5 + (me.curPage * 5)]; - me.L1[0] = " " ~ left(message.body, size(message.body) > 23 ? 23 : size(message.body)); + me.L1[0] = " " ~ left(message.body, size(message.body) > 17 ? 17 : size(message.body)); me.L1[2] = "blu"; if (!message.viewed) { - me.L1[1] = " " ~ message.time ~ " NEW"; + me.L1[1] = " " ~ message.time ~ " NEW"; } else { - me.L1[1] = " " ~ message.time ~ " VIEWED"; + me.L1[1] = " " ~ message.time ~ " VIEWED"; } me.arrowsMatrix[0][0] = 1; } if (me.size >= (me.curPage * 5) + -3) { message = ReceivedMessagesDatabase.database.vector[-4 + (me.curPage * 5)]; - me.L2[0] = " " ~ left(message.body, size(message.body) > 23 ? 23 : size(message.body)); + me.L2[0] = " " ~ left(message.body, size(message.body) > 17 ? 17 : size(message.body)); me.L2[2] = "blu"; if (!message.viewed) { - me.L2[1] = " " ~ message.time ~ " NEW"; + me.L2[1] = " " ~ message.time ~ " NEW"; } else { - me.L2[1] = " " ~ message.time ~ " VIEWED"; + me.L2[1] = " " ~ message.time ~ " VIEWED"; } me.arrowsMatrix[0][1] = 1; } if (me.size >= (me.curPage * 5) + -2) { message = ReceivedMessagesDatabase.database.vector[-3 + (me.curPage * 5)]; - me.L3[0] = " " ~ left(message.body, size(message.body) > 23 ? 23 : size(message.body)); + me.L3[0] = " " ~ left(message.body, size(message.body) > 17 ? 17 : size(message.body)); me.L3[2] = "blu"; if (!message.viewed) { - me.L3[1] = " " ~ message.time ~ " NEW"; + me.L3[1] = " " ~ message.time ~ " NEW"; } else { - me.L3[1] = " " ~ message.time ~ " VIEWED"; + me.L3[1] = " " ~ message.time ~ " VIEWED"; } me.arrowsMatrix[0][2] = 1; } if (me.size >= (me.curPage * 5) + -1) { message = ReceivedMessagesDatabase.database.vector[-2 + (me.curPage * 5)]; - me.L4[0] = " " ~ left(message.body, size(message.body) > 23 ? 23 : size(message.body)); + me.L4[0] = " " ~ left(message.body, size(message.body) > 17 ? 17 : size(message.body)); me.L4[2] = "blu"; if (!message.viewed) { - me.L4[1] = " " ~ message.time ~ " NEW"; + me.L4[1] = " " ~ message.time ~ " NEW"; } else { - me.L4[1] = " " ~ message.time ~ " VIEWED"; + me.L4[1] = " " ~ message.time ~ " VIEWED"; } me.arrowsMatrix[0][3] = 1; } if (me.size >= (me.curPage * 5) + 0) { message = ReceivedMessagesDatabase.database.vector[-1 + (me.curPage * 5)]; - me.L5[0] = " " ~ left(message.body, size(message.body) > 23 ? 23 : size(message.body)); + me.L5[0] = " " ~ left(message.body, size(message.body) > 17 ? 17 : size(message.body)); me.L5[2] = "blu"; if (!message.viewed) { - me.L5[1] = " " ~ message.time ~ " NEW"; + me.L5[1] = " " ~ message.time ~ " NEW"; } else { - me.L5[1] = " " ~ message.time ~ " VIEWED"; + me.L5[1] = " " ~ message.time ~ " VIEWED"; } me.arrowsMatrix[0][4] = 1; } @@ -239,37 +239,37 @@ var receivedMessagePage = { me.L1[1] = message.time; me.C1[1] = "VIEWED"; me.C1[2] = "grn"; - me.R1[1] = me.curPage ~ "/" ~ ReceivedMessagesDatabase.getSize(); + me.R1[1] = sprintf("%02d",me.curPage) ~ "/" ~ sprintf("%02d",ReceivedMessagesDatabase.getSize()); - me.L1[0] = left(message.body, size(message.body) > 30 ? 30 : size(message.body)); + me.L1[0] = left(message.body, size(message.body) > 24 ? 24 : size(message.body)); me.L1[2] = "wht"; me.L2[2] = "wht"; me.L3[2] = "wht"; me.L4[2] = "wht"; me.L5[2] = "wht"; - if (size(message.body) > 30) { - me.L2[1] = left(split(me.L1[0], message.body)[1], size(message.body) > 60 ? 30 : size(message.body) - 30); + if (size(message.body) > 24) { + me.L2[1] = left(split(me.L1[0], message.body)[1], size(message.body) > 48 ? 24 : size(message.body) - 24); } - if (size(message.body) > 60) { - me.L2[0] = left(split(me.L2[1], message.body)[1], size(message.body) > 90 ? 30 : size(message.body) - 60); + if (size(message.body) > 48) { + me.L2[0] = left(split(me.L2[1], message.body)[1], size(message.body) > 72 ? 24 : size(message.body) - 48); } - if (size(message.body) > 90) { - me.L3[1] = left(split(me.L2[0], message.body)[1], size(message.body) > 120 ? 30 : size(message.body) - 90); + if (size(message.body) > 72) { + me.L3[1] = left(split(me.L2[0], message.body)[1], size(message.body) > 96 ? 24 : size(message.body) - 72); + } + if (size(message.body) > 96) { + me.L3[0] = left(split(me.L3[1], message.body)[1], size(message.body) > 120 ? 24 : size(message.body) - 96); } if (size(message.body) > 120) { - me.L3[0] = left(split(me.L3[1], message.body)[1], size(message.body) > 150 ? 30 : size(message.body) - 120); + me.L4[1] = left(split(me.L3[0], message.body)[1], size(message.body) > 144 ? 24 : size(message.body) - 120); } - if (size(message.body) > 150) { - me.L4[1] = left(split(me.L3[0], message.body)[1], size(message.body) > 180 ? 30 : size(message.body) - 150); + if (size(message.body) > 144) { + me.L4[0] = left(split(me.L4[1], message.body)[1], size(message.body) > 168 ? 24 : size(message.body) - 144); } - if (size(message.body) > 180) { - me.L4[0] = left(split(me.L4[1], message.body)[1], size(message.body) > 210 ? 30 : size(message.body) - 180); + if (size(message.body) > 168) { + me.L5[1] = left(split(me.L4[0], message.body)[1], size(message.body) > 192 ? 24 : size(message.body) - 168); } - if (size(message.body) > 210) { - me.L5[1] = left(split(me.L4[0], message.body)[1], size(message.body) > 240 ? 30 : size(message.body) - 210); - } - if (size(message.body) > 240) { - me.L5[0] = left(split(me.L5[1], message.body)[1], size(message.body) > 270 ? 30 : size(message.body) - 240); + if (size(message.body) > 192) { + me.L5[0] = left(split(me.L5[1], message.body)[1], size(message.body) > 216 ? 24 : size(message.body) - 192); } } canvas_mcdu.pageSwitch[me.computer].setBoolValue(0); diff --git a/Sounds/A320-common-sound.xml b/Sounds/A320-common-sound.xml index 0ac0dc3b..10da1546 100644 --- a/Sounds/A320-common-sound.xml +++ b/Sounds/A320-common-sound.xml @@ -145,6 +145,7 @@ V1 once + avionics Aircraft/A320-family/Sounds/V1.wav @@ -183,6 +184,7 @@ 2500 Aircraft/A320-family/Sounds/GPWS/2500.wav once + avionics @@ -226,6 +228,7 @@ 2000 Aircraft/A320-family/Sounds/GPWS/2000.wav once + avionics @@ -269,6 +272,7 @@ 1000 Aircraft/A320-family/Sounds/GPWS/1000.wav once + avionics @@ -312,6 +316,7 @@ 500 Aircraft/A320-family/Sounds/GPWS/500.wav once + avionics @@ -355,6 +360,7 @@ 400 Aircraft/A320-family/Sounds/GPWS/400.wav once + avionics @@ -398,6 +404,7 @@ 300 Aircraft/A320-family/Sounds/GPWS/300.wav once + avionics @@ -441,6 +448,7 @@ 200 Aircraft/A320-family/Sounds/GPWS/200.wav once + avionics @@ -484,6 +492,7 @@ 100 Aircraft/A320-family/Sounds/GPWS/100.wav once + avionics @@ -527,6 +536,7 @@ 50 Aircraft/A320-family/Sounds/GPWS/50.wav once + avionics @@ -566,6 +576,7 @@ 40 Aircraft/A320-family/Sounds/GPWS/40.wav once + avionics @@ -605,6 +616,7 @@ 30 Aircraft/A320-family/Sounds/GPWS/30.wav once + avionics @@ -644,6 +656,7 @@ 20 Aircraft/A320-family/Sounds/GPWS/20.wav once + avionics @@ -683,6 +696,7 @@ 10 Aircraft/A320-family/Sounds/GPWS/10.wav once + avionics @@ -736,6 +750,7 @@ 5 Aircraft/A320-family/Sounds/GPWS/5.wav once + avionics @@ -787,6 +802,7 @@ 100above Aircraft/A320-family/Sounds/GPWS/100-above.wav once + avionics @@ -822,6 +838,7 @@ Minimum Aircraft/A320-family/Sounds/GPWS/minimum.wav once + avionics @@ -859,6 +876,7 @@ retard Aircraft/A320-family/Sounds/GPWS/retard.wav looped + avionics @@ -939,6 +957,7 @@ retard2 Aircraft/A320-family/Sounds/GPWS/retard.wav looped + avionics /sim/sound/warnings/retard @@ -953,6 +972,7 @@ apoff-looped looped + avionics Aircraft/A320-family/Sounds/Cockpit/calvary-charge-loop.wav @@ -983,6 +1003,7 @@ apoff-single once + avionics Aircraft/A320-family/Sounds/Cockpit/calvary-charge-once.wav @@ -1013,6 +1034,7 @@ autolandwarning-single once + avionics Aircraft/A320-family/Sounds/Cockpit/click.wav