Whisper bleed update v3 (#25434)
* Whisper bleed update v3 * missed a few * Add bleeding message to health analyzer. * Fix bleed notification not updating. * Apparently this either doesnt exist
This commit is contained in:
@@ -35,7 +35,7 @@ namespace Content.Server.Body.Components
|
||||
/// How much should bleeding should be reduced every update interval?
|
||||
/// </summary>
|
||||
[DataField]
|
||||
public float BleedReductionAmount = 1.0f;
|
||||
public float BleedReductionAmount = 0.33f;
|
||||
|
||||
/// <summary>
|
||||
/// How high can <see cref="BleedAmount"/> go?
|
||||
|
||||
@@ -203,6 +203,7 @@ public sealed partial class CryoPodSystem : SharedCryoPodSystem
|
||||
bloodstream.BloodSolutionName, ref bloodstream.BloodSolution, out var bloodSolution))
|
||||
? bloodSolution.FillFraction
|
||||
: 0,
|
||||
null,
|
||||
null
|
||||
));
|
||||
}
|
||||
|
||||
@@ -179,16 +179,24 @@ public sealed class HealthAnalyzerSystem : EntitySystem
|
||||
bodyTemperature = temp.CurrentTemperature;
|
||||
|
||||
var bloodAmount = float.NaN;
|
||||
var bleeding = false;
|
||||
|
||||
if (TryComp<BloodstreamComponent>(target, out var bloodstream) &&
|
||||
_solutionContainerSystem.ResolveSolution(target, bloodstream.BloodSolutionName, ref bloodstream.BloodSolution, out var bloodSolution))
|
||||
_solutionContainerSystem.ResolveSolution(target, bloodstream.BloodSolutionName,
|
||||
ref bloodstream.BloodSolution, out var bloodSolution))
|
||||
{
|
||||
bloodAmount = bloodSolution.FillFraction;
|
||||
bleeding = bloodstream.BleedAmount > 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
_uiSystem.SendUiMessage(ui, new HealthAnalyzerScannedUserMessage(
|
||||
GetNetEntity(target),
|
||||
bodyTemperature,
|
||||
bloodAmount,
|
||||
scanMode
|
||||
scanMode,
|
||||
bleeding
|
||||
));
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user