Skip to content
This repository has been archived by the owner on May 16, 2024. It is now read-only.

Commit

Permalink
fixed bug where track vector would update improperly after toggling o…
Browse files Browse the repository at this point in the history
…ff/on
  • Loading branch information
cywang90 committed Oct 14, 2020
1 parent 274e241 commit 784f7b3
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ class SvgTrackVectorElement extends SvgMapElement {
let windSpeed = SimVar.GetSimVarValue("AMBIENT WIND VELOCITY", "knots") / map.NMWidth * 1000 / 3600;
let windDirection = (SimVar.GetSimVarValue("AMBIENT WIND DIRECTION", "degree") + 180) * Math.PI / 180;

turnSpeed = turnSpeed * smoothingFactor + (this.lastTurnSpeed) * (1 - smoothingFactor);
if (dt < 1) {
turnSpeed = turnSpeed * smoothingFactor + (this.lastTurnSpeed) * (1 - smoothingFactor);
}

let points = null;
if (this.lookahead > this.dynamicLookaheadMax) {
Expand Down

0 comments on commit 784f7b3

Please sign in to comment.