Fix damage state displays in the Crew Monitoring UI (#2973)

fix damage state calculations
This commit is contained in:
Quanteey 2025-02-13 18:44:24 +01:00 committed by GitHub
parent 8dfe878fd2
commit ded0b17e38
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -221,7 +221,7 @@ public sealed partial class CrewMonitoringWindow : FancyWindow
else if (sensor.DamagePercentage != null)
{
var index = MathF.Round(4f * sensor.DamagePercentage.Value);
var index = (int)(sensor.DamagePercentage.Value * 5f); // DeltaV - Ensure damage states are calculated properly
if (index >= 5)
specifier = new SpriteSpecifier.Rsi(new ResPath("Interface/Alerts/human_crew_monitoring.rsi"), "critical");