Remove IInteractHand (#7601)

* Plantholder

* Strap

* Finish him

* Mirror review stuff
This commit is contained in:
Rane
2022-04-22 23:49:45 -04:00
committed by GitHub
parent e5bc79a713
commit c022afaec4
8 changed files with 71 additions and 112 deletions

View File

@@ -272,17 +272,6 @@ namespace Content.Shared.Interaction
if (message.Handled)
return;
var interactHandEventArgs = new InteractHandEventArgs(user, target);
var interactHandComps = AllComps<IInteractHand>(target).ToList();
foreach (var interactHandComp in interactHandComps)
{
// If an InteractHand returns a status completion we finish our interaction
#pragma warning disable 618
if (interactHandComp.InteractHand(interactHandEventArgs))
#pragma warning restore 618
return;
}
// Else we run Activate.
InteractionActivate(user, target,
checkCanInteract: false,
@@ -439,7 +428,7 @@ namespace Content.Shared.Interaction
CollisionGroup collisionMask = CollisionGroup.Impassable,
Ignored? predicate = null,
bool popup = false)
{;
{;
Ignored combinedPredicate = e => e == origin || (predicate?.Invoke(e) ?? false);
var inRange = InRangeUnobstructed(Transform(origin).MapPosition, other, range, collisionMask, combinedPredicate);