Make use-in-hand default to activation interactions. (#5951)

This commit is contained in:
Leon Friedrich
2022-01-05 02:23:01 +13:00
committed by GitHub
parent c4512e3c1a
commit f13f743c51
18 changed files with 58 additions and 116 deletions

View File

@@ -710,8 +710,11 @@ namespace Content.Shared.Hands.Components
if (!TryGetActiveHeldEntity(out var heldEntity))
return;
EntitySystem.Get<SharedInteractionSystem>()
.TryUseInteraction(Owner, heldEntity.Value, altInteract);
var sys = EntitySystem.Get<SharedInteractionSystem>();
if (altInteract)
sys.AltInteract(Owner, heldEntity.Value);
else
sys.TryUseInteraction(Owner, heldEntity.Value);
}
public void ActivateHeldEntity(string handName)