diff --git a/Kerbal Telemetry/Class1.cs b/Kerbal Telemetry/Class1.cs index 8e44dd2..a3e1bf3 100644 --- a/Kerbal Telemetry/Class1.cs +++ b/Kerbal Telemetry/Class1.cs @@ -19,7 +19,7 @@ public class KerbalTelemetry : MonoBehaviour public List velOverTime = new List(); public List dVOverTime = new List(); private float time = 0.0f; - public float interpolationPeriod = 5.0f; + public float interpolationPeriod = 0.03f; public string dataToShare; public string finalAltOverTime = "{\"data\": []}"; @@ -660,7 +660,7 @@ public void Update() situation = "In Space High"; break; } - if (time >= interpolationPeriod) + if (Mathf.Floor(time / interpolationPeriod) > Mathf.Floor((time - Time.deltaTime) / interpolationPeriod)) { time = time - interpolationPeriod; if (situation != "Landed" && altitude < 90000)