]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Fix filter popup prediction spam (#16274)
authormetalgearsloth <31366439+metalgearsloth@users.noreply.github.com>
Wed, 10 May 2023 00:00:58 +0000 (10:00 +1000)
committerGitHub <noreply@github.com>
Wed, 10 May 2023 00:00:58 +0000 (10:00 +1000)
Content.Client/Popups/PopupSystem.cs

index 573c45617aeaaa9578d6ec85cc59eacc8558128d..58e304459161b3c795e3b0040814fe8e3f7af343 100644 (file)
@@ -1,3 +1,4 @@
+using System.Linq;
 using Content.Shared.GameTicking;
 using Content.Shared.Popups;
 using Robust.Client.Graphics;
@@ -122,6 +123,9 @@ namespace Content.Client.Popups
 
         public override void PopupEntity(string message, EntityUid uid, Filter filter, bool recordReplay, PopupType type=PopupType.Small)
         {
+            if (!filter.Recipients.Contains(_playerManager.LocalPlayer?.Session))
+                return;
+
             PopupEntity(message, uid, type);
         }