[feat] bleeding alert, separated chat is default
# Conflicts: # Content.Server/Body/Components/BloodstreamComponent.cs # Content.Server/Body/Systems/BloodstreamSystem.cs # Content.Shared/Alert/AlertType.cs
This commit is contained in:
@@ -165,5 +165,14 @@ namespace Content.Server.Body.Components
|
||||
/// </summary>
|
||||
[ViewVariables(VVAccess.ReadWrite)]
|
||||
public float StatusTime;
|
||||
|
||||
//WD-EDIT
|
||||
|
||||
/// <summary>
|
||||
/// Bool for bleeding alert.
|
||||
/// </summary>
|
||||
public bool IsBleeding => BleedAmount > 0;
|
||||
|
||||
//WD-EDIT
|
||||
}
|
||||
}
|
||||
|
||||
@@ -104,6 +104,12 @@ public sealed class BloodstreamSystem : EntitySystem
|
||||
|
||||
if (!_solutionContainerSystem.ResolveSolution(uid, bloodstream.BloodSolutionName, ref bloodstream.BloodSolution, out var bloodSolution))
|
||||
continue;
|
||||
//WD-EDIT
|
||||
if (bloodstream.IsBleeding)
|
||||
_alertsSystem.ShowAlert(uid, AlertType.Bleed);
|
||||
else
|
||||
_alertsSystem.ClearAlert(uid, AlertType.Bleed);
|
||||
//WD-EDIT
|
||||
|
||||
// Adds blood to their blood level if it is below the maximum; Blood regeneration. Must be alive.
|
||||
if (bloodSolution.Volume < bloodSolution.MaxVolume && !_mobStateSystem.IsDead(uid))
|
||||
|
||||
@@ -1513,7 +1513,7 @@ namespace Content.Shared.CCVar
|
||||
*/
|
||||
|
||||
public static readonly CVarDef<string> UILayout =
|
||||
CVarDef.Create("ui.layout", "Default", CVar.CLIENTONLY | CVar.ARCHIVE);
|
||||
CVarDef.Create("ui.layout", "Separated", CVar.CLIENTONLY | CVar.ARCHIVE);
|
||||
|
||||
public static readonly CVarDef<string> DefaultScreenChatSize =
|
||||
CVarDef.Create("ui.default_chat_size", "", CVar.CLIENTONLY | CVar.ARCHIVE);
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
id: BaseAlertOrder
|
||||
order:
|
||||
- category: Health
|
||||
- alertType: Bleeding
|
||||
- category: Stamina
|
||||
- alertType: SuitPower
|
||||
- category: Internals
|
||||
@@ -457,3 +458,10 @@
|
||||
state: critical
|
||||
name: Debug6
|
||||
description: Debug
|
||||
|
||||
# WD-EDIT
|
||||
- type: alert
|
||||
id: Bleeding
|
||||
icons: [ /Textures/Interface/Alerts/bleeding.png ]
|
||||
name: alerts-bleeding-name
|
||||
description: alerts-bleeding-desc
|
||||
|
||||
BIN
Resources/Textures/Interface/Alerts/bleeding.png
Normal file
BIN
Resources/Textures/Interface/Alerts/bleeding.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 394 B |
Reference in New Issue
Block a user