Beispiel #1
0
 public void Update()
 {
     if (m_container.isVisible)
     {
         ushort lineID = UVMPublicTransportWorldInfoPanel.GetLineID();
         m_minutePointer.transform.localEulerAngles = new Vector3(0, 0, (SimulationManager.instance.m_currentDayTimeHour % 1 * -360) + 180);
         m_hourPointer.transform.localEulerAngles   = new Vector3(0, 0, (SimulationManager.instance.m_currentDayTimeHour / 24 * -360) + 180);
         Tuple <float, int, int, float> value = TLMLineUtils.GetBudgetMultiplierLineWithIndexes(lineID);
         m_effectiveSprite.color         = UVMBudgetConfigTab.m_colorOrder[value.Second % UVMBudgetConfigTab.m_colorOrder.Count];
         m_effectiveSprite.progressColor = UVMBudgetConfigTab.m_colorOrder[value.Third % UVMBudgetConfigTab.m_colorOrder.Count];
         m_effectiveSprite.value         = value.Fourth;
         int currentVehicleCount = Singleton <TransportManager> .instance.m_lines.m_buffer[lineID].CountVehicles(lineID);
         int targetVehicleCount  = TransportLineOverrides.NewCalculateTargetVehicleCount(lineID);
         m_effectiveLabel.prefix = (value.First * 100).ToString("0");
         m_effectiveLabel.suffix = $"{currentVehicleCount.ToString("0")}/{targetVehicleCount.ToString("0")}";
     }
 }