]> git.smokeofanarchy.ru Git - space-station-14.git/commitdiff
Fix strip menu opening on regular click (#14272)
authorVasilis The Pikachu <vasilis@pikachu.systems>
Sat, 25 Feb 2023 17:17:40 +0000 (18:17 +0100)
committerGitHub <noreply@github.com>
Sat, 25 Feb 2023 17:17:40 +0000 (04:17 +1100)
Content.Server/Buckle/Systems/BuckleSystem.Buckle.cs
Content.Server/Interaction/InteractionPopupSystem.cs

index 48ec12f9f9bb32f353d59edbc9b3de7a5f0c11e9..32d2a9ba02bf60c5cf0c3e036ad7dba085a67140 100644 (file)
@@ -76,7 +76,8 @@ public sealed partial class BuckleSystem
 
     private void HandleInteractHand(EntityUid uid, BuckleComponent component, InteractHandEvent args)
     {
-        args.Handled = TryUnbuckle(uid, args.User, buckle: component);
+        if (TryUnbuckle(uid, args.User, buckle: component))
+            args.Handled = true;
     }
 
     private void MoveEvent(EntityUid uid, BuckleComponent buckle, ref MoveEvent ev)
index ca14b2843305861015ba8a0c9849f9ec0050aefe..286919b64fc881fe5559ca82e7dbb2b881015f21 100644 (file)
@@ -34,6 +34,8 @@ public sealed class InteractionPopupSystem : EntitySystem
         if (HasComp<SleepingComponent>(uid))
             return;
 
+        args.Handled = true;
+
         var curTime = _gameTiming.CurTime;
 
         if (curTime < component.LastInteractTime + component.InteractDelay)
@@ -85,6 +87,5 @@ public sealed class InteractionPopupSystem : EntitySystem
         }
 
         component.LastInteractTime = curTime;
-        args.Handled = true;
     }
 }