1
0
Fork 0

Icing: Add scaling factor to frost-level

Significantly increase scaling factor of
/environment/aircraft-effects/frost-level, so that frost effects are
visible.
This commit is contained in:
Colin Geniet 2020-03-16 08:48:45 +01:00
parent 7acb378e7d
commit b10a164a62
2 changed files with 8 additions and 1 deletions

View file

@ -45,7 +45,7 @@
<ice-inches>0.0</ice-inches> <ice-inches>0.0</ice-inches>
<salvage-control>/controls/deice/windowprobeheat</salvage-control> <salvage-control>/controls/deice/windowprobeheat</salvage-control>
<sensitivity type="double">0.5</sensitivity> <sensitivity type="double">0.5</sensitivity>
<output-property>/environment/aircraft-effects/frost-level</output-property> <output-property>/environment/aircraft-effects/frost-inch</output-property>
</iceable> </iceable>
<iceable> <iceable>
<name>Fuselage</name> <name>Fuselage</name>

View file

@ -43,6 +43,11 @@ var environment = {
visibLclWx: props.globals.getNode("environment/visibility-m"), visibLclWx: props.globals.getNode("environment/visibility-m"),
}; };
var effects = {
frost_inch: props.globals.getNode("environment/aircraft-effects/frost-inch", 1),
frost_norm: props.globals.getNode("environment/aircraft-effects/frost-level"),
};
# Icing factor computation. # Icing factor computation.
var maxSpread = 0; var maxSpread = 0;
@ -166,6 +171,8 @@ var icingModel = func {
foreach(iceable; iceables) { foreach(iceable; iceables) {
iceable.update(factor, melt_factor); iceable.update(factor, melt_factor);
} }
effects.frost_norm.setDoubleValue(effects.frost_inch.getValue() * 50);
if (WingHasBeenTurnedOff and !wowl and !wowr and GroundModeFinished) { if (WingHasBeenTurnedOff and !wowl and !wowr and GroundModeFinished) {
setprop("controls/deice/wing", 1); setprop("controls/deice/wing", 1);