Skip to content

Commit

Permalink
private
Browse files Browse the repository at this point in the history
  • Loading branch information
FoxxoTrystan committed Dec 8, 2024
1 parent 75d9838 commit 9e28873
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions Content.Server/FloofStation/VoreSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@
using Content.Server.Power.Components;
using Content.Server.Nutrition.EntitySystems;
using Content.Shared.Interaction.Events;
using Content.Shared.Hands.Components;
using Content.Shared.Hands.EntitySystems;
using Robust.Shared.Player;

namespace Content.Server.FloofStation;

Expand Down Expand Up @@ -189,7 +189,8 @@ public void TryDevour(EntityUid uid, EntityUid target, VoreComponent? component
if (_food.IsMouthBlocked(uid, uid))
return;

_popups.PopupEntity(Loc.GetString("vore-attempt-devour", ("entity", uid), ("prey", target)), uid, PopupType.MediumCaution);
_popups.PopupEntity(Loc.GetString("vore-attempt-devour", ("entity", uid), ("prey", target)), uid, target, PopupType.MediumCaution);
_popups.PopupEntity(Loc.GetString("vore-attempt-devour", ("entity", uid), ("prey", target)), target, uid, PopupType.MediumCaution);

if (!TryComp<PhysicsComponent>(uid, out var predPhysics)
|| !TryComp<PhysicsComponent>(target, out var preyPhysics))
Expand Down Expand Up @@ -236,9 +237,10 @@ public void Devour(EntityUid uid, EntityUid target, VoreComponent? component = n

_containerSystem.Insert(target, component.Stomach);

_audioSystem.PlayPvs(component.SoundDevour, uid);
_audioSystem.PlayEntity(component.SoundDevour, Filter.Pvs(uid), uid, false);

_popups.PopupEntity(Loc.GetString("vore-devoured", ("entity", uid), ("prey", target)), uid, PopupType.SmallCaution);
_popups.PopupEntity(Loc.GetString("vore-devoured", ("entity", uid), ("prey", target)), uid, target, PopupType.SmallCaution);
_popups.PopupEntity(Loc.GetString("vore-devoured", ("entity", uid), ("prey", target)), target, uid, PopupType.SmallCaution);

_adminLog.Add(LogType.Action, LogImpact.High, $"{ToPrettyString(uid)} vored {ToPrettyString(target)}");
}
Expand All @@ -258,9 +260,11 @@ private void OnRelease(EntityUid uid, VoredComponent component, EntGotRemovedFro
if (TryComp<TemperatureComponent>(uid, out var temp))
temp.AtmosTemperatureTransferEfficiency = 0.1f;

_audioSystem.PlayPvs(component.SoundRelease, args.Container.Owner);
_audioSystem.PlayEntity(component.SoundRelease, Filter.Pvs(uid), uid, false);
_audioSystem.PlayEntity(component.SoundRelease, Filter.Pvs(args.Container.Owner), args.Container.Owner, false);

_popups.PopupEntity(Loc.GetString("vore-released", ("entity", uid), ("pred", args.Container.Owner)), uid, PopupType.Medium);
_popups.PopupEntity(Loc.GetString("vore-released", ("entity", uid), ("pred", args.Container.Owner)), uid, args.Container.Owner, PopupType.Medium);
_popups.PopupEntity(Loc.GetString("vore-released", ("entity", uid), ("pred", args.Container.Owner)), args.Container.Owner, uid, PopupType.Medium);

_adminLog.Add(LogType.Action, LogImpact.Medium, $"{ToPrettyString(uid)} got released from {ToPrettyString(args.Container.Owner)} belly");
}
Expand Down

0 comments on commit 9e28873

Please sign in to comment.