Skip to content

Commit

Permalink
MORE POPUPS
Browse files Browse the repository at this point in the history
  • Loading branch information
FaDeOkno committed Jul 14, 2024
1 parent 5c12126 commit 961e6a7
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
24 changes: 24 additions & 0 deletions Content.Shared/Movement/Pulling/Systems/PullingSystem.cs
Original file line number Diff line number Diff line change
Expand Up @@ -625,7 +625,31 @@ public bool TryStartPull(EntityUid pullerUid, EntityUid pullableUid,
return false;

if (!TryStopPull(pullableUid, pullableComp, pullableComp.Puller))
{
_popup.PopupEntity(Loc.GetString("popup-grab-retake-fail",
("puller", Identity.Entity(pullableComp.Puller.Value, EntityManager)),
("pulled", Identity.Entity(pullableUid, EntityManager))),
pullerUid, pullerUid, PopupType.MediumCaution);
_popup.PopupEntity(Loc.GetString("popup-grab-retake-fail-puller",
("puller", Identity.Entity(pullerUid, EntityManager)),
("pulled", Identity.Entity(pullableUid, EntityManager))),
pullableComp.Puller.Value, pullableComp.Puller.Value, PopupType.MediumCaution);

return false;
}

else if (pullableComp.GrabStage != GrabStage.No)
{
_popup.PopupEntity(Loc.GetString("popup-grab-retake-success",
("puller", Identity.Entity(pullableComp.Puller.Value, EntityManager)),
("pulled", Identity.Entity(pullableUid, EntityManager))),
pullerUid, pullerUid, PopupType.MediumCaution);
_popup.PopupEntity(Loc.GetString("popup-grab-retake-success-puller",
("puller", Identity.Entity(pullerUid, EntityManager)),
("pulled", Identity.Entity(pullableUid, EntityManager))),
pullableComp.Puller.Value, pullableComp.Puller.Value, PopupType.MediumCaution);
}

}

var pullAttempt = new PullAttemptEvent(pullerUid, pullableUid);
Expand Down
4 changes: 4 additions & 0 deletions Resources/Locale/en-US/pulling/popups.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ popup-grab-no-others = {CAPITALIZE($puller)} stopped grabbing {CAPITALIZE($targe
popup-grab-release-fail-self = You are trying to escape.
popup-grab-release-success-self = You escaped from grab!
popup-grab-release-success-puller = {CAPITALIZE($target)} escaped!
popup-grab-retake-fail = {CAPITALIZE($puller)} is not letting you to pull {CAPITALIZE($pulled)}!
popup-grab-retake-fail = {CAPITALIZE($puller)} is trying to release {CAPITALIZE($pulled)}!
popup-grab-retake-success = You released {CAPITALIZE($pulled)} from {CAPITALIZE($puller)}'s grab!
popup-grab-retake-success-puller = {CAPITALIZE($puller)} released {CAPITALIZE($pulled)} from your grab!
popup-grabbed-cant-speak = You can't breathe!
Expand Down

0 comments on commit 961e6a7

Please sign in to comment.