forked from FractalUK/KSPInterstellar
-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Description
The displayed reactor lifetime counts up from zero as it accumulates Actinides. Should the "fuel_lifetime_d = Math.Min(fuel_lifetime_d, availability / fuel_use);" line be removed in the ReactorProducts loop?
foreach (var product in current_fuel_mode.ReactorProducts)
{
double availability = getResourceAvailability(product.FuelName);
GUILayout.BeginHorizontal();
GUILayout.Label(product.FuelName, bold_label, GUILayout.Width(150));
GUILayout.Label((availability * product.Density * 1000).ToString("0.000000") + " kg", GUILayout.Width(150));
GUILayout.EndHorizontal();
double fuel_use = total_power_per_frame * product.ProductUsePerMJ * fuelUsePerMJMult / TimeWarp.fixedDeltaTime / FuelEfficiency * current_fuel_mode.NormalisedReactionRate * GameConstants.EARH_DAY_SECONDS;
fuel_lifetime_d = Math.Min(fuel_lifetime_d, availability / fuel_use);
GUILayout.BeginHorizontal();
GUILayout.Label(product.FuelName, bold_label, GUILayout.Width(150));
GUILayout.Label(fuel_use.ToString("0.000000") + " " + product.Unit + "/day", GUILayout.Width(150));
GUILayout.EndHorizontal();
}
PrintToGUILayout("Current Lifetime", (double.IsNaN(fuel_lifetime_d) ? "-" : (fuel_lifetime_d).ToString("0.00")) + " days", bold_label);
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels