Bug fix if no winds stored
This commit is contained in:
parent
536f61d197
commit
0f820ece04
2 changed files with 6 additions and 6 deletions
|
@ -893,12 +893,6 @@ var rskbutton = func(btn, i) {
|
|||
canvas_mcdu.myDESWIND[i].pushButtonRight(6);
|
||||
} else if (getprop("/MCDU[" ~ i ~ "]/page") == "WINDHIST") {
|
||||
canvas_mcdu.myHISTWIND[i].pushButtonRight(6);
|
||||
if (canvas_mcdu.myCLBWIND[i] == nil) {
|
||||
canvas_mcdu.myCLBWIND[i] = windCLBPage.new(i);
|
||||
} else {
|
||||
canvas_mcdu.myCLBWIND[i].reload();
|
||||
}
|
||||
setprop("MCDU[" ~ i ~ "]/page", "WINDCLB");
|
||||
} else if (getprop("/MCDU[" ~ i ~ "]/page") == "PERFTO") {
|
||||
perfTOInput("R6",i);
|
||||
} else if (getprop("/MCDU[" ~ i ~ "]/page") == "PERFCLB") {
|
||||
|
|
|
@ -176,6 +176,12 @@ var windHISTPage = {
|
|||
fmgc.windController.clb_winds[2].wind5.altitude = hist_winds.wind5.altitude;
|
||||
fmgc.windController.clb_winds[2].wind5.set = 1;
|
||||
}
|
||||
if (canvas_mcdu.myCLBWIND[me.computer] == nil) {
|
||||
canvas_mcdu.myCLBWIND[me.computer] = windCLBPage.new(me.computer);
|
||||
} else {
|
||||
canvas_mcdu.myCLBWIND[me.computer].reload();
|
||||
}
|
||||
setprop("MCDU[" ~ me.computer ~ "]/page", "WINDCLB");
|
||||
} else {
|
||||
mcdu_message(me.computer, "NO WINDS");
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue