Fix calculate temerature for ISA METAR scenario
This commit is contained in:
parent
c7c1eee98d
commit
ee14849016
2 changed files with 7 additions and 7 deletions
|
@ -42,17 +42,17 @@ setlistener("/environment/weather-scenario", func(n) {
|
|||
setprop( "/environment/params/metar-updates-environment", 0 );
|
||||
setprop( "/environment/realwx/enabled", 0 );
|
||||
setprop( "/environment/config/enabled", 0 );
|
||||
setprop( "/environment/climate/is-isa", 0 );
|
||||
setprop( "/environment/atmosphere/is-isa", 0 );
|
||||
} else if( scenarioName == "Live data" ) {
|
||||
setprop( "/environment/params/metar-updates-environment", 1 );
|
||||
setprop( "/environment/realwx/enabled", 1 );
|
||||
setprop( "/environment/config/enabled", 1 );
|
||||
setprop( "/environment/climate/is-isa", 0 );
|
||||
setprop( "/environment/atmosphere/is-isa", 0 );
|
||||
} else if( scenarioName == "Manual input" ) {
|
||||
setprop( "/environment/params/metar-updates-environment", 1 );
|
||||
setprop( "/environment/realwx/enabled", 0 );
|
||||
setprop( "/environment/config/enabled", 1 );
|
||||
setprop( "/environment/climate/is-isa", 0 );
|
||||
setprop( "/environment/atmosphere/is-isa", 0 );
|
||||
} else {
|
||||
setprop( "/environment/params/metar-updates-environment", 1 );
|
||||
setprop( "/environment/realwx/enabled", 0 );
|
||||
|
@ -61,6 +61,6 @@ setlistener("/environment/weather-scenario", func(n) {
|
|||
setprop( "environment/metar/data", metar );
|
||||
|
||||
var isISA = scenarioName == "International Standard Atmosphere";
|
||||
setprop( "/environment/climate/is-isa", isISA );
|
||||
setprop( "/environment/atmosphere/is-isa", isISA );
|
||||
}
|
||||
});
|
||||
|
|
|
@ -55,16 +55,16 @@
|
|||
setprop( "/environment/params/metar-updates-environment", 0 );
|
||||
setprop( "/environment/realwx/enabled", 0 );
|
||||
setprop( "/environment/config/enabled", 1 );
|
||||
setprop( "/environment/climate/is-isa", 0 );
|
||||
setprop( "/environment/atmosphere/is-isa", 0 );
|
||||
} else if( scenarioName == "Live data" ) {
|
||||
# If we've selected Live Data we need to force
|
||||
# a refresh of the Live Data setting.
|
||||
setprop( "/environment/realwx/enabled", 1 );
|
||||
setprop( "/environment/climate/is-isa", 0 );
|
||||
setprop( "/environment/atmosphere/is-isa", 0 );
|
||||
} else if( scenarioName == "International Standard Atmosphere" ) {
|
||||
# If we've selected International Standard Atmosphere we need to
|
||||
# enable the ISA setting.
|
||||
setprop( "/environment/climate/is-isa", 1 );
|
||||
setprop( "/environment/atmosphere/is-isa", 1 );
|
||||
}
|
||||
},
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue