diff --git a/ClockLib/OWClock.cs b/ClockLib/OWClock.cs index 27c9c64..a725d18 100644 --- a/ClockLib/OWClock.cs +++ b/ClockLib/OWClock.cs @@ -107,11 +107,11 @@ private void AddEvent(string text) string ParseTime(float timestamp) { var minutes = Mathf.Floor(timestamp / 60f).ToString().PadLeft(2, '0'); - var seconds = Mathf.Round(timestamp % 60f * 100f / 100f).ToString().PadLeft(2, '0'); + var seconds = Math.Truncate(timestamp % 60f).ToString().PadLeft(2, '0'); var clock = $"{minutes}:{seconds}"; if (Milliseconds) { - var milliseconds = Math.Round((timestamp - Math.Floor(timestamp)) * 1000).ToString().PadLeft(3, '0'); + var milliseconds = Math.Truncate((timestamp - Math.Floor(timestamp)) * 1000).ToString().PadLeft(3, '0'); clock = $"{clock}.{milliseconds}"; } return clock; diff --git a/ClockLib/manifest.json b/ClockLib/manifest.json index eebd03c..469a81e 100644 --- a/ClockLib/manifest.json +++ b/ClockLib/manifest.json @@ -4,6 +4,6 @@ "name": "Clock", "uniqueName": "clubby789.OWClock", "description": "Add a clock overlay", - "version": "0.2.5", + "version": "0.2.6", "owmlVersion": "0.7.3" } \ No newline at end of file