Больше лучше

This commit is contained in:
BIGZi0348
2025-01-06 18:15:28 +03:00
parent 8aa5d138d5
commit 3a586578e2
3 changed files with 19 additions and 6 deletions

View File

@@ -9,10 +9,10 @@ public sealed partial class DirectBallsHitComponent : Component
public TimeSpan KnockdownTime = TimeSpan.FromSeconds(2.0f);
[DataField]
public TimeSpan JitterTime = TimeSpan.FromSeconds(2.0f);
public TimeSpan JitterTime = TimeSpan.FromSeconds(4.0f);
[DataField]
public TimeSpan StutterTime = TimeSpan.FromSeconds(2.0f);
public TimeSpan StutterTime = TimeSpan.FromSeconds(4.0f);
[DataField]
public SharedStandingStateSystem.DropHeldItemsBehavior KnockDownBehavior = SharedStandingStateSystem.DropHeldItemsBehavior.AlwaysDrop;

View File

@@ -10,6 +10,7 @@ using Content.Shared.Popups;
using Content.Shared._White.Implants.NeuroControl;
using Robust.Shared.Timing;
using Content.Server.Chat.Systems;
using Content.Server._White.Mood;
namespace Content.Server._White._Engi.DirectBallsHit;
@@ -21,6 +22,7 @@ public sealed class DirectBallsHitSystem : EntitySystem
[Dependency] private readonly SharedElectrocutionSystem _electrocution = default!;
[Dependency] private readonly SharedPopupSystem _popupSystem = default!;
[Dependency] private readonly ChatSystem _chat = default!;
[Dependency] private readonly MoodSystem _mood = default!;
public override void Initialize()
{
@@ -42,10 +44,15 @@ public sealed class DirectBallsHitSystem : EntitySystem
foreach (var uid in args.HitEntities)
{
_popupSystem.PopupEntity(
Loc.GetString("direct-balls-hit", ("uid", uid)),
uid,
PopupType.SmallCaution);
if (TryComp<MoodComponent>(uid, out var mood))
{
_popupSystem.PopupEntity(
Loc.GetString("direct-balls-hit", ("uid", uid)),
uid,
PopupType.SmallCaution);
_mood.ApplyEffect(uid, mood, "GotHitInTheBalls");
}
Timer.Spawn(TimeSpan.FromSeconds(0.5f), () => _chat.TryEmoteWithChat(uid, "Scream"));

View File

@@ -41,3 +41,9 @@
id: MobHighPressure
description: "На меня оказывается огромное давление!"
moodChange: enum.MoodChangeLevel.Medium
- type: moodEffect
id: GotHitInTheBalls
description: "Господи... Как же больно..."
moodChange: enum.MoodChangeLevel.Large
timeout: 1