Skip to content

Commit

Permalink
Changed battery segment color weights to make more sense
Browse files Browse the repository at this point in the history
  • Loading branch information
Exomanz committed Jul 14, 2024
1 parent e0cbbe0 commit 7c6dcdb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions UITweaks/Decorators/EnergyBarPanelDecorator.cs
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ private void PrepareColorsForEnergyType(GameplayModifiers.EnergyType type)
List<Image> batterySegments = gameEnergyUIPanel._batteryLifeSegments;

batterySegments[0].color = energyConfig.Low;
batterySegments[1].color = HSBColor.Lerp(HSBColor.FromColor(energyConfig.Low), HSBColor.FromColor(energyConfig.Mid), 0.34f).ToColor();
batterySegments[2].color = HSBColor.Lerp(HSBColor.FromColor(energyConfig.Mid), HSBColor.FromColor(energyConfig.High), 0.66f).ToColor();
batterySegments[1].color = HSBColor.Lerp(HSBColor.FromColor(energyConfig.Low), HSBColor.FromColor(energyConfig.Mid), 0.5f).ToColor();
batterySegments[2].color = HSBColor.Lerp(HSBColor.FromColor(energyConfig.Mid), HSBColor.FromColor(energyConfig.High), 0.5f).ToColor();
batterySegments[3].color = energyConfig.High;

return;
Expand Down

0 comments on commit 7c6dcdb

Please sign in to comment.