Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 4 additions & 13 deletions source/WaypointManager/WaypointFlightRenderer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -403,19 +403,10 @@ protected string GetTimeToWaypoint(WaypointData wpd)

double time = (wpd.distanceToActive / v.horizontalSrfSpeed);

// Earthtime
uint SecondsPerYear = 31536000; // = 365d
uint SecondsPerDay = 86400; // = 24h
uint SecondsPerHour = 3600; // = 60m
uint SecondsPerMinute = 60; // = 60s

if (GameSettings.KERBIN_TIME == true)
{
SecondsPerYear = 9201600; // = 426d
SecondsPerDay = 21600; // = 6h
SecondsPerHour = 3600; // = 60m
SecondsPerMinute = 60; // = 60s
}
uint SecondsPerYear = (uint)KSPUtil.dateTimeFormatter.Year;
uint SecondsPerDay = (uint)KSPUtil.dateTimeFormatter.Day;
uint SecondsPerHour = (uint)KSPUtil.dateTimeFormatter.Hour;
uint SecondsPerMinute = (uint)KSPUtil.dateTimeFormatter.Minute;

int years = (int)(time / SecondsPerYear);
time -= years * SecondsPerYear;
Expand Down