голод и жажда
This commit is contained in:
@@ -136,7 +136,7 @@ public sealed class HungerSystem : EntitySystem
|
||||
return;
|
||||
|
||||
//WD start
|
||||
if (_net.IsServer && component.CurrentThreshold != HungerThreshold.Overfed)
|
||||
if (_net.IsServer)
|
||||
{
|
||||
var ev = new MoodEffectEvent("Hunger" + component.CurrentThreshold);
|
||||
RaiseLocalEvent(uid, ev);
|
||||
|
||||
@@ -10,6 +10,7 @@ using Robust.Shared.Random;
|
||||
using Robust.Shared.Timing;
|
||||
using Content.Shared._White.Mood;
|
||||
using Robust.Shared.Utility;
|
||||
using Robust.Shared.Network;
|
||||
|
||||
namespace Content.Shared.Nutrition.EntitySystems;
|
||||
|
||||
@@ -22,6 +23,7 @@ public sealed class ThirstSystem : EntitySystem
|
||||
[Dependency] private readonly AlertsSystem _alerts = default!;
|
||||
[Dependency] private readonly MovementSpeedModifierSystem _movement = default!;
|
||||
[Dependency] private readonly SharedJetpackSystem _jetpack = default!;
|
||||
[Dependency] private readonly INetManager _net = default!; // WD edit
|
||||
|
||||
[ValidatePrototypeId<StatusIconPrototype>]
|
||||
private const string ThirstIconOverhydratedId = "ThirstIconOverhydrated";
|
||||
@@ -65,7 +67,7 @@ public sealed class ThirstSystem : EntitySystem
|
||||
UpdateEffects(uid, component);
|
||||
|
||||
TryComp(uid, out MovementSpeedModifierComponent? moveMod);
|
||||
_movement.RefreshMovementSpeedModifiers(uid, moveMod);
|
||||
_movement.RefreshMovementSpeedModifiers(uid, moveMod);
|
||||
}
|
||||
|
||||
private void OnRefreshMovespeed(EntityUid uid, ThirstComponent component, RefreshMovementSpeedModifiersEvent args)
|
||||
@@ -172,7 +174,7 @@ public sealed class ThirstSystem : EntitySystem
|
||||
}
|
||||
|
||||
// WD start
|
||||
if (component.CurrentThirstThreshold != ThirstThreshold.OverHydrated)
|
||||
if (_net.IsServer)
|
||||
{
|
||||
var ev = new MoodEffectEvent("Thirst" + component.CurrentThirstThreshold);
|
||||
RaiseLocalEvent(uid, ev);
|
||||
|
||||
@@ -1,8 +1,9 @@
|
||||
#Hunger
|
||||
- type: moodEffect
|
||||
id: HungerOverfed
|
||||
description: "Во мне столько жира..."
|
||||
moodChange: enum.MoodChangeLevel.Small
|
||||
description: "Мой желудок полон!"
|
||||
moodChange: enum.MoodChangeLevel.Medium
|
||||
positive: true
|
||||
category: "Hunger"
|
||||
|
||||
- type: moodEffect
|
||||
@@ -24,11 +25,18 @@
|
||||
moodChange: enum.MoodChangeLevel.Big
|
||||
category: "Hunger"
|
||||
|
||||
- type: moodEffect
|
||||
id: HungerDead
|
||||
description: "Умираю от голода!"
|
||||
moodChange: enum.MoodChangeLevel.Huge
|
||||
category: "Hunger"
|
||||
|
||||
#Thirst
|
||||
- type: moodEffect
|
||||
id: ThirstOverHydrated
|
||||
description: "СЛИШКОМ МНОГО ВОДЫ..."
|
||||
moodChange: enum.MoodChangeLevel.Small
|
||||
description: "Не хочу пить."
|
||||
moodChange: enum.MoodChangeLevel.Medium
|
||||
positive: true
|
||||
category: "Thirst"
|
||||
|
||||
- type: moodEffect
|
||||
@@ -46,10 +54,16 @@
|
||||
|
||||
- type: moodEffect
|
||||
id: ThirstParched
|
||||
description: "ВОДЫ!"
|
||||
description: "Хочу пить!"
|
||||
moodChange: enum.MoodChangeLevel.Big
|
||||
category: "Thirst"
|
||||
|
||||
- type: moodEffect
|
||||
id: ThirstDead
|
||||
description: "Умираю от жажды!"
|
||||
moodChange: enum.MoodChangeLevel.Huge
|
||||
category: "Thirst"
|
||||
|
||||
#Health
|
||||
- type: moodEffect
|
||||
id: HealthNoDamage
|
||||
|
||||
Reference in New Issue
Block a user