diff --git a/Content.Server/GameTicking/GameTicker.Spawning.cs b/Content.Server/GameTicking/GameTicker.Spawning.cs index 238a614695..5d7d966c5f 100644 --- a/Content.Server/GameTicking/GameTicker.Spawning.cs +++ b/Content.Server/GameTicking/GameTicker.Spawning.cs @@ -200,7 +200,7 @@ namespace Content.Server.GameTicking } #region Mob Spawning Helpers - private IEntity SpawnPlayerMob(Job job, HumanoidCharacterProfile? profile, StationId station, bool lateJoin = true) + private EntityUid SpawnPlayerMob(Job job, HumanoidCharacterProfile? profile, StationId station, bool lateJoin = true) { var coordinates = lateJoin ? GetLateJoinSpawnPoint(station) : GetJobSpawnPoint(job.Prototype.ID, station); var entity = EntityManager.SpawnEntity(PlayerPrototypeName, coordinates); @@ -213,14 +213,14 @@ namespace Content.Server.GameTicking if (profile != null) { - EntitySystem.Get().UpdateFromProfile(entity, profile); - IoCManager.Resolve().GetComponent(entity).EntityName = profile.Name; + _humanoidAppearanceSystem.UpdateFromProfile(entity, profile); + EntityManager.GetComponent(entity).EntityName = profile.Name; } return entity; } - private IEntity SpawnObserverMob() + private EntityUid SpawnObserverMob() { var coordinates = GetObserverSpawnPoint(); return EntityManager.SpawnEntity(ObserverPrototypeName, coordinates); @@ -228,7 +228,7 @@ namespace Content.Server.GameTicking #endregion #region Equip Helpers - public void EquipStartingGear(IEntity entity, StartingGearPrototype startingGear, HumanoidCharacterProfile? profile) + public void EquipStartingGear(EntityUid entity, StartingGearPrototype startingGear, HumanoidCharacterProfile? profile) { if (IoCManager.Resolve().TryGetComponent(entity, out InventoryComponent? inventory)) { @@ -238,25 +238,25 @@ namespace Content.Server.GameTicking if (!string.IsNullOrEmpty(equipmentStr)) { var equipmentEntity = EntityManager.SpawnEntity(equipmentStr, IoCManager.Resolve().GetComponent(entity).Coordinates); - inventory.Equip(slot, IoCManager.Resolve().GetComponent(equipmentEntity)); + inventory.Equip(slot, EntityManager.GetComponent(equipmentEntity)); } } } - if (IoCManager.Resolve().TryGetComponent(entity, out HandsComponent? handsComponent)) + if (EntityManager.TryGetComponent(entity, out HandsComponent? handsComponent)) { var inhand = startingGear.Inhand; foreach (var (hand, prototype) in inhand) { - var inhandEntity = EntityManager.SpawnEntity(prototype, IoCManager.Resolve().GetComponent(entity).Coordinates); + var inhandEntity = EntityManager.SpawnEntity(prototype, EntityManager.GetComponent(entity).Coordinates); handsComponent.TryPickupEntity(hand, inhandEntity, checkActionBlocker: false); } } } - public void EquipIdCard(IEntity entity, string characterName, JobPrototype jobPrototype) + public void EquipIdCard(EntityUid entity, string characterName, JobPrototype jobPrototype) { - if (!IoCManager.Resolve().TryGetComponent(entity, out InventoryComponent? inventory)) + if (!EntityManager.TryGetComponent(entity, out InventoryComponent? inventory)) return; if (!inventory.TryGetSlotItem(EquipmentSlotDefines.Slots.IDCARD, out ItemComponent? item)) @@ -276,8 +276,7 @@ namespace Content.Server.GameTicking var access = IoCManager.Resolve().GetComponent(card.Owner); var accessTags = access.Tags; accessTags.UnionWith(jobPrototype.Access); - EntityManager.EntitySysManager.GetEntitySystem() - .SetOwner(pdaComponent, characterName); + _pdaSystem.SetOwner(pdaComponent, characterName); } #endregion diff --git a/Content.Server/GameTicking/GameTicker.cs b/Content.Server/GameTicking/GameTicker.cs index 91c0d74492..25fecfc3d5 100644 --- a/Content.Server/GameTicking/GameTicker.cs +++ b/Content.Server/GameTicking/GameTicker.cs @@ -1,6 +1,8 @@ using Content.Server.Administration.Logs; +using Content.Server.CharacterAppearance.Systems; using Content.Server.Chat.Managers; using Content.Server.Maps; +using Content.Server.PDA; using Content.Server.Preferences.Managers; using Content.Server.Roles; using Content.Server.Station; @@ -91,5 +93,7 @@ namespace Content.Server.GameTicking [Dependency] private readonly IGameMapManager _gameMapManager = default!; [Dependency] private readonly StationSystem _stationSystem = default!; [Dependency] private readonly AdminLogSystem _adminLogSystem = default!; + [Dependency] private readonly HumanoidAppearanceSystem _humanoidAppearanceSystem = default!; + [Dependency] private readonly PDASystem _pdaSystem = default!; } } diff --git a/Content.Shared/Hands/Components/SharedHandsComponent.cs b/Content.Shared/Hands/Components/SharedHandsComponent.cs index ea81cc76f4..0eff6297f4 100644 --- a/Content.Shared/Hands/Components/SharedHandsComponent.cs +++ b/Content.Shared/Hands/Components/SharedHandsComponent.cs @@ -102,7 +102,9 @@ namespace Content.Shared.Hands.Components public void UpdateHandVisualizer() { - if (!IoCManager.Resolve().TryGetComponent(Owner, out AppearanceComponent? appearance)) + var entMan = IoCManager.Resolve(); + + if (!entMan.TryGetComponent(Owner, out AppearanceComponent? appearance)) return; var hands = new List(); @@ -111,7 +113,7 @@ namespace Content.Shared.Hands.Components if (hand.HeldEntity == null) continue; - if (!IoCManager.Resolve().TryGetComponent(hand.HeldEntity, out SharedItemComponent? item) || item.RsiPath == null) + if (!entMan.TryGetComponent(hand.HeldEntity.Value, out SharedItemComponent? item) || item.RsiPath == null) continue; var handState = new HandVisualState(item.RsiPath, item.EquippedPrefix, hand.Location, item.Color); @@ -217,7 +219,7 @@ namespace Content.Shared.Hands.Components return hand.HeldEntity != null; } - public bool TryGetHeldEntity(string handName, [NotNullWhen(true)] out IEntity? heldEntity) + public bool TryGetHeldEntity(string handName, [NotNullWhen(true)] out EntityUid? heldEntity) { heldEntity = null; @@ -228,13 +230,13 @@ namespace Content.Shared.Hands.Components return heldEntity != null; } - public bool TryGetActiveHeldEntity([NotNullWhen(true)] out IEntity? heldEntity) + public bool TryGetActiveHeldEntity([NotNullWhen(true)] out EntityUid? heldEntity) { heldEntity = GetActiveHand()?.HeldEntity; return heldEntity != null; } - public bool IsHolding(IEntity entity) + public bool IsHolding(EntityUid entity) { foreach (var hand in Hands) { @@ -244,12 +246,12 @@ namespace Content.Shared.Hands.Components return false; } - public IEnumerable GetAllHeldEntities() + public IEnumerable GetAllHeldEntities() { foreach (var hand in Hands) { if (hand.HeldEntity != null) - yield return hand.HeldEntity; + yield return hand.HeldEntity.Value; } } @@ -269,7 +271,7 @@ namespace Content.Shared.Hands.Components return acc; } - public bool TryGetHandHoldingEntity(IEntity entity, [NotNullWhen(true)] out Hand? handFound) + public bool TryGetHandHoldingEntity(EntityUid entity, [NotNullWhen(true)] out Hand? handFound) { handFound = null; @@ -330,7 +332,7 @@ namespace Content.Shared.Hands.Components /// /// Tries to drop a held entity to the target location. /// - public bool TryDropEntity(IEntity entity, EntityCoordinates coords, bool doMobChecks = true) + public bool TryDropEntity(EntityUid entity, EntityCoordinates coords, bool doMobChecks = true) { if (!TryGetHandHoldingEntity(entity, out var hand)) return false; @@ -356,7 +358,7 @@ namespace Content.Shared.Hands.Components /// /// Attempts to move a held item from a hand into a container that is not another hand, without dropping it on the floor in-between. /// - public bool Drop(IEntity entity, BaseContainer targetContainer, bool checkActionBlocker = true) + public bool Drop(EntityUid entity, BaseContainer targetContainer, bool checkActionBlocker = true) { if (!TryGetHandHoldingEntity(entity, out var hand)) return false; @@ -382,7 +384,7 @@ namespace Content.Shared.Hands.Components /// /// Tries to drop a held entity directly under the player. /// - public bool Drop(IEntity entity, bool checkActionBlocker = true) + public bool Drop(EntityUid entity, bool checkActionBlocker = true) { if (!TryGetHandHoldingEntity(entity, out var hand)) return false; @@ -412,11 +414,11 @@ namespace Content.Shared.Hands.Components /// private bool CanRemoveHeldEntityFromHand(Hand hand) { - var heldEntity = hand.HeldEntity; - - if (heldEntity == null) + if (hand.HeldEntity == null) return false; + var heldEntity = hand.HeldEntity.Value; + var handContainer = hand.Container; if (handContainer == null) return false; @@ -443,11 +445,11 @@ namespace Content.Shared.Hands.Components /// private void RemoveHeldEntityFromHand(Hand hand) { - var heldEntity = hand.HeldEntity; - - if (heldEntity == null) + if (hand.HeldEntity == null) return; + var heldEntity = hand.HeldEntity.Value; + var handContainer = hand.Container; if (handContainer == null) return; @@ -471,11 +473,11 @@ namespace Content.Shared.Hands.Components /// public void DropHeldEntity(Hand hand, EntityCoordinates targetDropLocation) { - var heldEntity = hand.HeldEntity; - - if (heldEntity == null) + if (hand.HeldEntity == null) return; + var heldEntity = hand.HeldEntity.Value; + RemoveHeldEntityFromHand(hand); EntitySystem.Get().DroppedInteraction(Owner, heldEntity); @@ -534,11 +536,11 @@ namespace Content.Shared.Hands.Components private bool CanPutHeldEntityIntoContainer(Hand hand, IContainer targetContainer, bool checkActionBlocker) { - var heldEntity = hand.HeldEntity; - - if (heldEntity == null) + if (hand.HeldEntity == null) return false; + var heldEntity = hand.HeldEntity.Value; + if (checkActionBlocker && !PlayerCanDrop()) return false; @@ -553,11 +555,11 @@ namespace Content.Shared.Hands.Components /// private void PutHeldEntityIntoContainer(Hand hand, IContainer targetContainer) { - var heldEntity = hand.HeldEntity; - - if (heldEntity == null) + if (hand.HeldEntity == null) return; + var heldEntity = hand.HeldEntity.Value; + RemoveHeldEntityFromHand(hand); if (!targetContainer.Insert(heldEntity)) @@ -571,7 +573,7 @@ namespace Content.Shared.Hands.Components #region Pickup - public bool CanPickupEntity(string handName, IEntity entity, bool checkActionBlocker = true) + public bool CanPickupEntity(string handName, EntityUid entity, bool checkActionBlocker = true) { if (!TryGetHand(handName, out var hand)) return false; @@ -585,7 +587,7 @@ namespace Content.Shared.Hands.Components return true; } - public bool CanPickupEntityToActiveHand(IEntity entity, bool checkActionBlocker = true) + public bool CanPickupEntityToActiveHand(EntityUid entity, bool checkActionBlocker = true) { return ActiveHand != null && CanPickupEntity(ActiveHand, entity, checkActionBlocker); } @@ -593,7 +595,7 @@ namespace Content.Shared.Hands.Components /// /// Tries to pick up an entity to a specific hand. /// - public bool TryPickupEntity(string handName, IEntity entity, bool checkActionBlocker = true) + public bool TryPickupEntity(string handName, EntityUid entity, bool checkActionBlocker = true) { if (!TryGetHand(handName, out var hand)) return false; @@ -601,7 +603,7 @@ namespace Content.Shared.Hands.Components return TryPickupEntity(hand, entity, checkActionBlocker); } - public bool TryPickupEntityToActiveHand(IEntity entity, bool checkActionBlocker = true) + public bool TryPickupEntityToActiveHand(EntityUid entity, bool checkActionBlocker = true) { return ActiveHand != null && TryPickupEntity(ActiveHand, entity, checkActionBlocker); } @@ -609,7 +611,7 @@ namespace Content.Shared.Hands.Components /// /// Checks if an entity can be put into a hand's container. /// - protected bool CanInsertEntityIntoHand(Hand hand, IEntity entity) + protected bool CanInsertEntityIntoHand(Hand hand, EntityUid entity) { var handContainer = hand.Container; if (handContainer == null) @@ -636,7 +638,7 @@ namespace Content.Shared.Hands.Components /// /// Puts an entity into the player's hand, assumes that the insertion is allowed. /// - public void PutEntityIntoHand(Hand hand, IEntity entity) + public void PutEntityIntoHand(Hand hand, EntityUid entity) { var handContainer = hand.Container; if (handContainer == null) @@ -660,7 +662,7 @@ namespace Content.Shared.Hands.Components HandsModified(); } - private bool TryPickupEntity(Hand hand, IEntity entity, bool checkActionBlocker = true) + private bool TryPickupEntity(Hand hand, EntityUid entity, bool checkActionBlocker = true) { if (!CanInsertEntityIntoHand(hand, entity)) return false; @@ -712,7 +714,7 @@ namespace Content.Shared.Hands.Components return; await EntitySystem.Get() - .InteractUsing(Owner, activeHeldEntity, heldEntity, EntityCoordinates.Invalid); + .InteractUsing(Owner, activeHeldEntity.Value, heldEntity.Value, EntityCoordinates.Invalid); } public void ActivateItem(bool altInteract = false) @@ -721,7 +723,7 @@ namespace Content.Shared.Hands.Components return; EntitySystem.Get() - .TryUseInteraction(Owner, heldEntity, altInteract); + .TryUseInteraction(Owner, heldEntity.Value, altInteract); } public void ActivateHeldEntity(string handName) @@ -744,14 +746,14 @@ namespace Content.Shared.Hands.Components if (!TryGetHeldEntity(handName, out var heldEntity)) return false; - if (!CanInsertEntityIntoHand(activeHand, heldEntity) || !CanRemoveHeldEntityFromHand(hand)) + if (!CanInsertEntityIntoHand(activeHand, heldEntity.Value) || !CanRemoveHeldEntityFromHand(hand)) return false; if (checkActionBlocker && (!PlayerCanDrop() || !PlayerCanPickup())) return false; RemoveHeldEntityFromHand(hand); - PutEntityIntoHand(activeHand, heldEntity); + PutEntityIntoHand(activeHand, heldEntity.Value); return true; } @@ -760,13 +762,13 @@ namespace Content.Shared.Hands.Components private void DeselectActiveHeldEntity() { if (TryGetActiveHeldEntity(out var entity)) - EntitySystem.Get().HandDeselectedInteraction(Owner, entity); + EntitySystem.Get().HandDeselectedInteraction(Owner, entity.Value); } private void SelectActiveHeldEntity() { if (TryGetActiveHeldEntity(out var entity)) - EntitySystem.Get().HandSelectedInteraction(Owner, entity); + EntitySystem.Get().HandSelectedInteraction(Owner, entity.Value); } private void HandCountChanged() @@ -796,7 +798,7 @@ namespace Content.Shared.Hands.Components /// /// Tries to pick up an entity into the active hand. If it cannot, tries to pick up the entity into each other hand. /// - public bool TryPutInActiveHandOrAny(IEntity entity, bool checkActionBlocker = true) + public bool TryPutInActiveHandOrAny(EntityUid entity, bool checkActionBlocker = true) { return TryPutInAnyHand(entity, GetActiveHand(), checkActionBlocker); } @@ -804,7 +806,7 @@ namespace Content.Shared.Hands.Components /// /// Tries to pick up an entity into the priority hand, if provided. If it cannot, tries to pick up the entity into each other hand. /// - public bool TryPutInAnyHand(IEntity entity, string? priorityHandName = null, bool checkActionBlocker = true) + public bool TryPutInAnyHand(EntityUid entity, string? priorityHandName = null, bool checkActionBlocker = true) { Hand? priorityHand = null; @@ -817,7 +819,7 @@ namespace Content.Shared.Hands.Components /// /// Tries to pick up an entity into the priority hand, if provided. If it cannot, tries to pick up the entity into each other hand. /// - private bool TryPutInAnyHand(IEntity entity, Hand? priorityHand = null, bool checkActionBlocker = true) + private bool TryPutInAnyHand(EntityUid entity, Hand? priorityHand = null, bool checkActionBlocker = true) { if (priorityHand != null) { @@ -833,9 +835,9 @@ namespace Content.Shared.Hands.Components return false; } - protected virtual void OnHeldEntityRemovedFromHand(IEntity heldEntity, HandState handState) { } + protected virtual void OnHeldEntityRemovedFromHand(EntityUid heldEntity, HandState handState) { } - protected virtual void HandlePickupAnimation(IEntity entity) { } + protected virtual void HandlePickupAnimation(EntityUid entity) { } } #region visualizerData @@ -890,7 +892,7 @@ namespace Content.Shared.Hands.Components public IContainer? Container { get; set; } [ViewVariables] - public IEntity? HeldEntity => Container?.ContainedEntities?.FirstOrDefault(); + public EntityUid? HeldEntity => Container?.ContainedEntities?.FirstOrDefault(); public bool IsEmpty => HeldEntity == null; @@ -995,12 +997,12 @@ namespace Content.Shared.Hands.Components public class HandCountChangedEvent : EntityEventArgs { - public HandCountChangedEvent(IEntity sender) + public HandCountChangedEvent(EntityUid sender) { Sender = sender; } - public IEntity Sender { get; } + public EntityUid Sender { get; } } [Serializable, NetSerializable] diff --git a/Content.Shared/Hands/IEquippedHand.cs b/Content.Shared/Hands/IEquippedHand.cs index dd01e37e6c..fc2a67ae52 100644 --- a/Content.Shared/Hands/IEquippedHand.cs +++ b/Content.Shared/Hands/IEquippedHand.cs @@ -22,7 +22,7 @@ namespace Content.Shared.Hands public class EquippedHandEventArgs : UserEventArgs { - public EquippedHandEventArgs(IEntity user, HandState hand) : base(user) + public EquippedHandEventArgs(EntityUid user, HandState hand) : base(user) { Hand = hand; } @@ -39,19 +39,19 @@ namespace Content.Shared.Hands /// /// Entity that equipped the item. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item that was equipped. /// - public IEntity Equipped { get; } + public EntityUid Equipped { get; } /// /// Hand that the item was placed into. /// public HandState Hand { get; } - public EquippedHandEvent(IEntity user, IEntity equipped, HandState hand) + public EquippedHandEvent(EntityUid user, EntityUid equipped, HandState hand) { User = user; Equipped = equipped; diff --git a/Content.Shared/Hands/IHandDeselected.cs b/Content.Shared/Hands/IHandDeselected.cs index 980f3dd489..a038569c18 100644 --- a/Content.Shared/Hands/IHandDeselected.cs +++ b/Content.Shared/Hands/IHandDeselected.cs @@ -17,12 +17,12 @@ namespace Content.Shared.Hands public class HandDeselectedEventArgs : EventArgs { - public HandDeselectedEventArgs(IEntity user) + public HandDeselectedEventArgs(EntityUid user) { User = user; } - public IEntity User { get; } + public EntityUid User { get; } } /// @@ -34,14 +34,14 @@ namespace Content.Shared.Hands /// /// Entity that owns the deselected hand. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item in the hand that was deselected. /// - public IEntity Item { get; } + public EntityUid Item { get; } - public HandDeselectedEvent(IEntity user, IEntity item) + public HandDeselectedEvent(EntityUid user, EntityUid item) { User = user; Item = item; diff --git a/Content.Shared/Hands/IHandSelected.cs b/Content.Shared/Hands/IHandSelected.cs index 5e34cef951..f26e846cc4 100644 --- a/Content.Shared/Hands/IHandSelected.cs +++ b/Content.Shared/Hands/IHandSelected.cs @@ -17,12 +17,12 @@ namespace Content.Shared.Hands public class HandSelectedEventArgs : EventArgs { - public HandSelectedEventArgs(IEntity user) + public HandSelectedEventArgs(EntityUid user) { User = user; } - public IEntity User { get; } + public EntityUid User { get; } } /// @@ -34,14 +34,14 @@ namespace Content.Shared.Hands /// /// Entity that owns the selected hand. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item in the hand that was selected. /// - public IEntity Item { get; } + public EntityUid Item { get; } - public HandSelectedEvent(IEntity user, IEntity item) + public HandSelectedEvent(EntityUid user, EntityUid item) { User = user; Item = item; diff --git a/Content.Shared/Hands/IUnequippedHand.cs b/Content.Shared/Hands/IUnequippedHand.cs index 9abf762e8c..058d2c4276 100644 --- a/Content.Shared/Hands/IUnequippedHand.cs +++ b/Content.Shared/Hands/IUnequippedHand.cs @@ -21,7 +21,7 @@ namespace Content.Shared.Hands public class UnequippedHandEventArgs : UserEventArgs { - public UnequippedHandEventArgs(IEntity user, HandState hand) : base(user) + public UnequippedHandEventArgs(EntityUid user, HandState hand) : base(user) { Hand = hand; } @@ -38,19 +38,19 @@ namespace Content.Shared.Hands /// /// Entity that equipped the item. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item that was unequipped. /// - public IEntity Unequipped { get; } + public EntityUid Unequipped { get; } /// /// Hand that the item is removed from. /// public HandState Hand { get; } - public UnequippedHandEvent(IEntity user, IEntity unequipped, HandState hand) + public UnequippedHandEvent(EntityUid user, EntityUid unequipped, HandState hand) { User = user; Unequipped = unequipped; diff --git a/Content.Shared/Interaction/BeforeInteract.cs b/Content.Shared/Interaction/BeforeInteract.cs index c6a9f63957..ed0bcb1c41 100644 --- a/Content.Shared/Interaction/BeforeInteract.cs +++ b/Content.Shared/Interaction/BeforeInteract.cs @@ -13,32 +13,17 @@ namespace Content.Shared.Interaction /// /// Entity that triggered the interaction. /// - public IEntity User { get; } - - /// - /// Entity that triggered the interaction. - /// - public EntityUid UserUid => User; + public EntityUid User { get; } /// /// Entity that the user used to interact. /// - public IEntity Used { get; } - - /// - /// Entity that the user used to interact. - /// - public EntityUid UsedUid => Used; + public EntityUid Used { get; } /// /// Entity that was interacted on. This can be null if the attack did not click on an entity. /// - public IEntity? Target { get; } - - /// - /// Entity that was interacted on. This can be null if the attack did not click on an entity. - /// - public EntityUid? TargetUid => Target; + public EntityUid? Target { get; } /// /// Location that the user clicked outside of their interaction range. @@ -52,9 +37,9 @@ namespace Content.Shared.Interaction public bool CanReach { get; } public BeforeInteractEvent( - IEntity user, - IEntity used, - IEntity? target, + EntityUid user, + EntityUid used, + EntityUid? target, EntityCoordinates clickLocation, bool canReach) { diff --git a/Content.Shared/Interaction/IActivate.cs b/Content.Shared/Interaction/IActivate.cs index 096c3af5a2..b97e4b7820 100644 --- a/Content.Shared/Interaction/IActivate.cs +++ b/Content.Shared/Interaction/IActivate.cs @@ -24,14 +24,14 @@ namespace Content.Shared.Interaction public class ActivateEventArgs : EventArgs, ITargetedInteractEventArgs { - public ActivateEventArgs(IEntity user, IEntity target) + public ActivateEventArgs(EntityUid user, EntityUid target) { User = user; Target = target; } - public IEntity User { get; } - public IEntity Target { get; } + public EntityUid User { get; } + public EntityUid Target { get; } } /// @@ -43,24 +43,14 @@ namespace Content.Shared.Interaction /// /// Entity that activated the target world entity. /// - public IEntity User { get; } - - /// - /// Entity that activated the target world entity. - /// - public EntityUid UserUid => User; + public EntityUid User { get; } /// /// Entity that was activated in the world. /// - public IEntity Target { get; } + public EntityUid Target { get; } - /// - /// Entity that was activated in the world. - /// - public EntityUid TargetUid => Target; - - public ActivateInWorldEvent(IEntity user, IEntity target) + public ActivateInWorldEvent(EntityUid user, EntityUid target) { User = user; Target = target; diff --git a/Content.Shared/Interaction/IAfterInteract.cs b/Content.Shared/Interaction/IAfterInteract.cs index 76209fdf64..6d85d41f6c 100644 --- a/Content.Shared/Interaction/IAfterInteract.cs +++ b/Content.Shared/Interaction/IAfterInteract.cs @@ -31,12 +31,12 @@ namespace Content.Shared.Interaction public class AfterInteractEventArgs : EventArgs { - public IEntity User { get; } + public EntityUid User { get; } public EntityCoordinates ClickLocation { get; } - public IEntity? Target { get; } + public EntityUid? Target { get; } public bool CanReach { get; } - public AfterInteractEventArgs(IEntity user, EntityCoordinates clickLocation, IEntity? target, bool canReach) + public AfterInteractEventArgs(EntityUid user, EntityCoordinates clickLocation, EntityUid? target, bool canReach) { User = user; ClickLocation = clickLocation; @@ -54,32 +54,17 @@ namespace Content.Shared.Interaction /// /// Entity that triggered the interaction. /// - public IEntity User { get; } - - /// - /// Entity that triggered the interaction. - /// - public EntityUid UserUid => User; + public EntityUid User { get; } /// /// Entity that the user used to interact. /// - public IEntity Used { get; } - - /// - /// Entity that the user used to interact. - /// - public EntityUid UsedUid => Used; + public EntityUid Used { get; } /// /// Entity that was interacted on. This can be null if the attack did not click on an entity. /// - public IEntity? Target { get; } - - /// - /// Entity that was interacted on. This can be null if the attack did not click on an entity. - /// - public EntityUid? TargetUid => Target; + public EntityUid? Target { get; } /// /// Location that the user clicked outside of their interaction range. @@ -92,7 +77,7 @@ namespace Content.Shared.Interaction /// public bool CanReach { get; } - public AfterInteractEvent(IEntity user, IEntity used, IEntity? target, + public AfterInteractEvent(EntityUid user, EntityUid used, EntityUid? target, EntityCoordinates clickLocation, bool canReach) { User = user; diff --git a/Content.Shared/Interaction/IDropped.cs b/Content.Shared/Interaction/IDropped.cs index 8158524eaa..5fdcd071ae 100644 --- a/Content.Shared/Interaction/IDropped.cs +++ b/Content.Shared/Interaction/IDropped.cs @@ -17,12 +17,12 @@ namespace Content.Shared.Interaction public class DroppedEventArgs : EventArgs { - public DroppedEventArgs(IEntity user) + public DroppedEventArgs(EntityUid user) { User = user; } - public IEntity User { get; } + public EntityUid User { get; } } /// diff --git a/Content.Shared/Interaction/IInteractUsing.cs b/Content.Shared/Interaction/IInteractUsing.cs index 3a7ebeec7d..c3a380e414 100644 --- a/Content.Shared/Interaction/IInteractUsing.cs +++ b/Content.Shared/Interaction/IInteractUsing.cs @@ -30,7 +30,7 @@ namespace Content.Shared.Interaction public class InteractUsingEventArgs : EventArgs, ITargetedInteractEventArgs { - public InteractUsingEventArgs(IEntity user, EntityCoordinates clickLocation, IEntity @using, IEntity target) + public InteractUsingEventArgs(EntityUid user, EntityCoordinates clickLocation, EntityUid @using, EntityUid target) { User = user; ClickLocation = clickLocation; @@ -38,10 +38,10 @@ namespace Content.Shared.Interaction Target = target; } - public IEntity User { get; } + public EntityUid User { get; } public EntityCoordinates ClickLocation { get; } - public IEntity Using { get; } - public IEntity Target { get; } + public EntityUid Using { get; } + public EntityUid Target { get; } } /// @@ -53,39 +53,24 @@ namespace Content.Shared.Interaction /// /// Entity that triggered the interaction. /// - public IEntity User { get; } - - /// - /// Entity that triggered the interaction. - /// - public EntityUid UserUid => User; + public EntityUid User { get; } /// /// Entity that the user used to interact. /// - public IEntity Used { get; } - - /// - /// Entity that the user used to interact. - /// - public EntityUid UsedUid => Used; + public EntityUid Used { get; } /// /// Entity that was interacted on. /// - public IEntity Target { get; } - - /// - /// Entity that was interacted on. - /// - public EntityUid TargetUid => Target; + public EntityUid Target { get; } /// /// The original location that was clicked by the user. /// public EntityCoordinates ClickLocation { get; } - public InteractUsingEvent(IEntity user, IEntity used, IEntity target, EntityCoordinates clickLocation) + public InteractUsingEvent(EntityUid user, EntityUid used, EntityUid target, EntityCoordinates clickLocation) { User = user; Used = used; diff --git a/Content.Shared/Interaction/ITargetedInteractEventArgs.cs b/Content.Shared/Interaction/ITargetedInteractEventArgs.cs index 1b52dbed2c..13f415e5e9 100644 --- a/Content.Shared/Interaction/ITargetedInteractEventArgs.cs +++ b/Content.Shared/Interaction/ITargetedInteractEventArgs.cs @@ -7,11 +7,11 @@ namespace Content.Shared.Interaction /// /// Performer of the attack /// - IEntity User { get; } + EntityUid User { get; } /// /// Target of the attack /// - IEntity Target { get; } + EntityUid Target { get; } } } diff --git a/Content.Shared/Interaction/IUse.cs b/Content.Shared/Interaction/IUse.cs index 648336a052..5cdb81931d 100644 --- a/Content.Shared/Interaction/IUse.cs +++ b/Content.Shared/Interaction/IUse.cs @@ -22,12 +22,12 @@ namespace Content.Shared.Interaction public class UseEntityEventArgs : EventArgs { - public UseEntityEventArgs(IEntity user) + public UseEntityEventArgs(EntityUid user) { User = user; } - public IEntity User { get; } + public EntityUid User { get; } } /// @@ -39,24 +39,14 @@ namespace Content.Shared.Interaction /// /// Entity holding the item in their hand. /// - public IEntity User { get; } - - /// - /// Entity holding the item in their hand. - /// - public EntityUid UserUid => User; + public EntityUid User { get; } /// /// Item that was used. /// - public IEntity Used { get; } + public EntityUid Used { get; } - /// - /// Item that was used. - /// - public EntityUid UsedUid => Used; - - public UseInHandEvent(IEntity user, IEntity used) + public UseInHandEvent(EntityUid user, EntityUid used) { User = user; Used = used; diff --git a/Content.Shared/Interaction/SharedInteractionSystem.cs b/Content.Shared/Interaction/SharedInteractionSystem.cs index 447d8f79ca..34ad79f71c 100644 --- a/Content.Shared/Interaction/SharedInteractionSystem.cs +++ b/Content.Shared/Interaction/SharedInteractionSystem.cs @@ -90,11 +90,11 @@ namespace Content.Shared.Interaction MapCoordinates origin, MapCoordinates other, int collisionMask = (int) CollisionGroup.Impassable, - IEntity? ignoredEnt = null) + EntityUid? ignoredEnt = null) { var predicate = ignoredEnt == null ? null - : (Ignored) (e => e == ignoredEnt?.Uid); + : (Ignored) (e => e == ignoredEnt); return UnobstructedDistance(origin, other, collisionMask, predicate); } @@ -204,15 +204,15 @@ namespace Content.Shared.Interaction /// True if the two points are within a given range without being obstructed. /// public bool InRangeUnobstructed( - IEntity origin, - IEntity other, + EntityUid origin, + EntityUid other, float range = InteractionRange, CollisionGroup collisionMask = CollisionGroup.Impassable, Ignored? predicate = null, bool ignoreInsideBlocker = false, bool popup = false) { - predicate ??= e => e == origin.Uid || e == other.Uid; + predicate ??= e => e == origin || e == other; return InRangeUnobstructed(origin, IoCManager.Resolve().GetComponent(other).MapPosition, range, collisionMask, predicate, ignoreInsideBlocker, popup); } @@ -249,7 +249,7 @@ namespace Content.Shared.Interaction /// True if the two points are within a given range without being obstructed. /// public bool InRangeUnobstructed( - IEntity origin, + EntityUid origin, IComponent other, float range = InteractionRange, CollisionGroup collisionMask = CollisionGroup.Impassable, @@ -293,7 +293,7 @@ namespace Content.Shared.Interaction /// True if the two points are within a given range without being obstructed. /// public bool InRangeUnobstructed( - IEntity origin, + EntityUid origin, EntityCoordinates other, float range = InteractionRange, CollisionGroup collisionMask = CollisionGroup.Impassable, @@ -337,7 +337,7 @@ namespace Content.Shared.Interaction /// True if the two points are within a given range without being obstructed. /// public bool InRangeUnobstructed( - IEntity origin, + EntityUid origin, MapCoordinates other, float range = InteractionRange, CollisionGroup collisionMask = CollisionGroup.Impassable, @@ -346,7 +346,7 @@ namespace Content.Shared.Interaction bool popup = false) { var originPosition = IoCManager.Resolve().GetComponent(origin).MapPosition; - predicate ??= e => e == origin.Uid; + predicate ??= e => e == origin; var inRange = InRangeUnobstructed(originPosition, other, range, collisionMask, predicate, ignoreInsideBlocker); @@ -360,9 +360,9 @@ namespace Content.Shared.Interaction } public bool InteractDoBefore( - IEntity user, - IEntity used, - IEntity? target, + EntityUid user, + EntityUid used, + EntityUid? target, EntityCoordinates clickLocation, bool canReach) { @@ -376,7 +376,7 @@ namespace Content.Shared.Interaction /// Finds components with the InteractUsing interface and calls their function /// NOTE: Does not have an InRangeUnobstructed check /// - public async Task InteractUsing(IEntity user, IEntity used, IEntity target, EntityCoordinates clickLocation) + public async Task InteractUsing(EntityUid user, EntityUid used, EntityUid target, EntityCoordinates clickLocation) { if (!_actionBlockerSystem.CanInteract(user)) return; @@ -407,7 +407,7 @@ namespace Content.Shared.Interaction /// /// We didn't click on any entity, try doing an AfterInteract on the click location /// - public async Task InteractDoAfter(IEntity user, IEntity used, IEntity? target, EntityCoordinates clickLocation, bool canReach) + public async Task InteractDoAfter(EntityUid user, EntityUid used, EntityUid? target, EntityCoordinates clickLocation, bool canReach) { var afterInteractEvent = new AfterInteractEvent(user, used, target, clickLocation, canReach); RaiseLocalEvent(used, afterInteractEvent, false); @@ -431,15 +431,15 @@ namespace Content.Shared.Interaction /// Activates the IActivate behavior of an object /// Verifies that the user is capable of doing the use interaction first /// - public void TryInteractionActivate(IEntity? user, IEntity? used) + public void TryInteractionActivate(EntityUid? user, EntityUid? used) { if (user == null || used == null) return; - InteractionActivate(user, used); + InteractionActivate(user.Value, used.Value); } - protected void InteractionActivate(IEntity user, IEntity used) + protected void InteractionActivate(EntityUid user, EntityUid used) { if (IoCManager.Resolve().TryGetComponent(used, out var delayComponent)) { @@ -486,7 +486,7 @@ namespace Content.Shared.Interaction /// /// /// - public void TryUseInteraction(IEntity user, IEntity used, bool altInteract = false) + public void TryUseInteraction(EntityUid user, EntityUid used, bool altInteract = false) { if (user != null && used != null && _actionBlockerSystem.CanUse(user)) { @@ -501,7 +501,7 @@ namespace Content.Shared.Interaction /// Activates the IUse behaviors of an entity without first checking /// if the user is capable of doing the use interaction. /// - public void UseInteraction(IEntity user, IEntity used) + public void UseInteraction(EntityUid user, EntityUid used) { if (IoCManager.Resolve().TryGetComponent(used, out var delayComponent)) { @@ -533,7 +533,7 @@ namespace Content.Shared.Interaction /// /// Uses the context menu verb list, and acts out the highest priority alternative interaction verb. /// - public void AltInteract(IEntity user, IEntity target) + public void AltInteract(EntityUid user, EntityUid target) { // Get list of alt-interact verbs var verbs = _verbSystem.GetLocalVerbs(target, user, VerbType.Alternative)[VerbType.Alternative]; @@ -547,7 +547,7 @@ namespace Content.Shared.Interaction /// Calls Thrown on all components that implement the IThrown interface /// on an entity that has been thrown. /// - public void ThrownInteraction(IEntity user, IEntity thrown) + public void ThrownInteraction(EntityUid user, EntityUid thrown) { var throwMsg = new ThrownEvent(user, thrown); RaiseLocalEvent(thrown, throwMsg); @@ -574,7 +574,7 @@ namespace Content.Shared.Interaction /// Calls Equipped on all components that implement the IEquipped interface /// on an entity that has been equipped. /// - public void EquippedInteraction(IEntity user, IEntity equipped, EquipmentSlotDefines.Slots slot) + public void EquippedInteraction(EntityUid user, EntityUid equipped, EquipmentSlotDefines.Slots slot) { var equipMsg = new EquippedEvent(user, equipped, slot); RaiseLocalEvent(equipped, equipMsg); @@ -594,7 +594,7 @@ namespace Content.Shared.Interaction /// Calls Unequipped on all components that implement the IUnequipped interface /// on an entity that has been equipped. /// - public void UnequippedInteraction(IEntity user, IEntity equipped, EquipmentSlotDefines.Slots slot) + public void UnequippedInteraction(EntityUid user, EntityUid equipped, EquipmentSlotDefines.Slots slot) { var unequipMsg = new UnequippedEvent(user, equipped, slot); RaiseLocalEvent(equipped, unequipMsg); @@ -615,7 +615,7 @@ namespace Content.Shared.Interaction /// Calls EquippedHand on all components that implement the IEquippedHand interface /// on an item. /// - public void EquippedHandInteraction(IEntity user, IEntity item, HandState hand) + public void EquippedHandInteraction(EntityUid user, EntityUid item, HandState hand) { var equippedHandMessage = new EquippedHandEvent(user, item, hand); RaiseLocalEvent(item, equippedHandMessage); @@ -634,7 +634,7 @@ namespace Content.Shared.Interaction /// Calls UnequippedHand on all components that implement the IUnequippedHand interface /// on an item. /// - public void UnequippedHandInteraction(IEntity user, IEntity item, HandState hand) + public void UnequippedHandInteraction(EntityUid user, EntityUid item, HandState hand) { var unequippedHandMessage = new UnequippedHandEvent(user, item, hand); RaiseLocalEvent(item, unequippedHandMessage); @@ -656,7 +656,7 @@ namespace Content.Shared.Interaction /// Activates the Dropped behavior of an object /// Verifies that the user is capable of doing the drop interaction first /// - public bool TryDroppedInteraction(IEntity user, IEntity item) + public bool TryDroppedInteraction(EntityUid user, EntityUid item) { if (user == null || item == null || !_actionBlockerSystem.CanDrop(user)) return false; @@ -668,7 +668,7 @@ namespace Content.Shared.Interaction /// Calls Dropped on all components that implement the IDropped interface /// on an entity that has been dropped. /// - public void DroppedInteraction(IEntity user, IEntity item) + public void DroppedInteraction(EntityUid user, EntityUid item) { var dropMsg = new DroppedEvent(user, item); RaiseLocalEvent(item, dropMsg); @@ -696,7 +696,7 @@ namespace Content.Shared.Interaction /// Calls HandSelected on all components that implement the IHandSelected interface /// on an item entity on a hand that has just been selected. /// - public void HandSelectedInteraction(IEntity user, IEntity item) + public void HandSelectedInteraction(EntityUid user, EntityUid item) { var handSelectedMsg = new HandSelectedEvent(user, item); RaiseLocalEvent(item, handSelectedMsg); @@ -716,7 +716,7 @@ namespace Content.Shared.Interaction /// Calls HandDeselected on all components that implement the IHandDeselected interface /// on an item entity on a hand that has just been deselected. /// - public void HandDeselectedInteraction(IEntity user, IEntity item) + public void HandDeselectedInteraction(EntityUid user, EntityUid item) { var handDeselectedMsg = new HandDeselectedEvent(user, item); RaiseLocalEvent(item, handDeselectedMsg); diff --git a/Content.Shared/Inventory/IEquipped.cs b/Content.Shared/Inventory/IEquipped.cs index 9021190108..b8e3bad7f7 100644 --- a/Content.Shared/Inventory/IEquipped.cs +++ b/Content.Shared/Inventory/IEquipped.cs @@ -23,9 +23,9 @@ namespace Content.Shared.Inventory public abstract class UserEventArgs : EventArgs { - public IEntity User { get; } + public EntityUid User { get; } - protected UserEventArgs(IEntity user) + protected UserEventArgs(EntityUid user) { User = user; } @@ -33,7 +33,7 @@ namespace Content.Shared.Inventory public class EquippedEventArgs : UserEventArgs { - public EquippedEventArgs(IEntity user, EquipmentSlotDefines.Slots slot) : base(user) + public EquippedEventArgs(EntityUid user, EquipmentSlotDefines.Slots slot) : base(user) { Slot = slot; } @@ -50,19 +50,19 @@ namespace Content.Shared.Inventory /// /// Entity that equipped the item. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item that was equipped. /// - public IEntity Equipped { get; } + public EntityUid Equipped { get; } /// /// Slot that the item was placed into. /// public EquipmentSlotDefines.Slots Slot { get; } - public EquippedEvent(IEntity user, IEntity equipped, EquipmentSlotDefines.Slots slot) + public EquippedEvent(EntityUid user, EntityUid equipped, EquipmentSlotDefines.Slots slot) { User = user; Equipped = equipped; diff --git a/Content.Shared/Inventory/IUnequipped.cs b/Content.Shared/Inventory/IUnequipped.cs index 2a3985231e..5981ca1dd2 100644 --- a/Content.Shared/Inventory/IUnequipped.cs +++ b/Content.Shared/Inventory/IUnequipped.cs @@ -23,7 +23,7 @@ namespace Content.Shared.Inventory public class UnequippedEventArgs : UserEventArgs { - public UnequippedEventArgs(IEntity user, EquipmentSlotDefines.Slots slot) : base(user) + public UnequippedEventArgs(EntityUid user, EquipmentSlotDefines.Slots slot) : base(user) { Slot = slot; } @@ -40,19 +40,19 @@ namespace Content.Shared.Inventory /// /// Entity that equipped the item. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item that was unequipped. /// - public IEntity Unequipped { get; } + public EntityUid Unequipped { get; } /// /// Slot that the item was removed from. /// public EquipmentSlotDefines.Slots Slot { get; } - public UnequippedEvent(IEntity user, IEntity unequipped, EquipmentSlotDefines.Slots slot) + public UnequippedEvent(EntityUid user, EntityUid unequipped, EquipmentSlotDefines.Slots slot) { User = user; Unequipped = unequipped; diff --git a/Content.Shared/Throwing/IThrown.cs b/Content.Shared/Throwing/IThrown.cs index 03e308232d..6d26a0d8b9 100644 --- a/Content.Shared/Throwing/IThrown.cs +++ b/Content.Shared/Throwing/IThrown.cs @@ -17,12 +17,12 @@ namespace Content.Shared.Throwing public class ThrownEventArgs : EventArgs { - public ThrownEventArgs(IEntity user) + public ThrownEventArgs(EntityUid user) { User = user; } - public IEntity User { get; } + public EntityUid User { get; } } /// @@ -34,14 +34,14 @@ namespace Content.Shared.Throwing /// /// Entity that threw the item. /// - public IEntity User { get; } + public EntityUid User { get; } /// /// Item that was thrown. /// - public IEntity Thrown { get; } + public EntityUid Thrown { get; } - public ThrownEvent(IEntity user, IEntity thrown) + public ThrownEvent(EntityUid user, EntityUid thrown) { User = user; Thrown = thrown; diff --git a/Content.Shared/Verbs/SharedVerbSystem.cs b/Content.Shared/Verbs/SharedVerbSystem.cs index 2d1037d74e..236adf6f9c 100644 --- a/Content.Shared/Verbs/SharedVerbSystem.cs +++ b/Content.Shared/Verbs/SharedVerbSystem.cs @@ -20,7 +20,7 @@ namespace Content.Shared.Verbs /// Raises a number of events in order to get all verbs of the given type(s) defined in local systems. This /// does not request verbs from the server. /// - public virtual Dictionary> GetLocalVerbs(IEntity target, IEntity user, VerbType verbTypes, bool force = false) + public virtual Dictionary> GetLocalVerbs(EntityUid target, EntityUid user, VerbType verbTypes, bool force = false) { Dictionary> verbs = new(); @@ -41,17 +41,17 @@ namespace Content.Shared.Verbs // call ActionBlocker checks, just cache it for the verb request. var canInteract = force || _actionBlockerSystem.CanInteract(user); - IEntity? @using = null; - if (IoCManager.Resolve().TryGetComponent(user, out SharedHandsComponent? hands) && (force || _actionBlockerSystem.CanUse(user))) + EntityUid? @using = null; + if (EntityManager.TryGetComponent(user, out SharedHandsComponent? hands) && (force || _actionBlockerSystem.CanUse(user))) { hands.TryGetActiveHeldEntity(out @using); // Check whether the "Held" entity is a virtual pull entity. If yes, set that as the entity being "Used". // This allows you to do things like buckle a dragged person onto a surgery table, without click-dragging // their sprite. - if (@using != null && IoCManager.Resolve().TryGetComponent(@using, out var pull)) + if (@using != null && EntityManager.TryGetComponent(@using.Value, out var pull)) { - @using = IoCManager.Resolve().GetEntity(pull.BlockingEntity); + @using = EntityManager.GetEntity(pull.BlockingEntity); } } @@ -127,7 +127,7 @@ namespace Content.Shared.Verbs !EntityManager.TryGetEntity(targetUid, out var target)) return; - IEntity? used = null; + EntityUid? used = null; if (usedUid != null) EntityManager.TryGetEntity(usedUid.Value, out used); diff --git a/Content.Shared/Verbs/VerbEvents.cs b/Content.Shared/Verbs/VerbEvents.cs index b1b30ab3e8..e11386c36b 100644 --- a/Content.Shared/Verbs/VerbEvents.cs +++ b/Content.Shared/Verbs/VerbEvents.cs @@ -81,7 +81,7 @@ namespace Content.Shared.Verbs /// public class GetInteractionVerbsEvent : GetVerbsEvent { - public GetInteractionVerbsEvent(IEntity user, IEntity target, IEntity? @using, SharedHandsComponent? hands, + public GetInteractionVerbsEvent(EntityUid user, EntityUid target, EntityUid? @using, SharedHandsComponent? hands, bool canInteract, bool canAccess) : base(user, target, @using, hands, canInteract, canAccess) { } } @@ -97,7 +97,7 @@ namespace Content.Shared.Verbs /// public class GetActivationVerbsEvent : GetVerbsEvent { - public GetActivationVerbsEvent(IEntity user, IEntity target, IEntity? @using, SharedHandsComponent? hands, + public GetActivationVerbsEvent(EntityUid user, EntityUid target, EntityUid? @using, SharedHandsComponent? hands, bool canInteract, bool canAccess) : base(user, target, @using, hands, canInteract, canAccess) { } } @@ -110,7 +110,7 @@ namespace Content.Shared.Verbs /// public class GetAlternativeVerbsEvent : GetVerbsEvent { - public GetAlternativeVerbsEvent(IEntity user, IEntity target, IEntity? @using, SharedHandsComponent? hands, + public GetAlternativeVerbsEvent(EntityUid user, EntityUid target, EntityUid? @using, SharedHandsComponent? hands, bool canInteract, bool canAccess) : base(user, target, @using, hands, canInteract, canAccess) { } } @@ -123,7 +123,7 @@ namespace Content.Shared.Verbs /// public class GetOtherVerbsEvent : GetVerbsEvent { - public GetOtherVerbsEvent(IEntity user, IEntity target, IEntity? @using, SharedHandsComponent? hands, + public GetOtherVerbsEvent(EntityUid user, EntityUid target, EntityUid? @using, SharedHandsComponent? hands, bool canInteract, bool canAccess) : base(user, target, @using, hands, canInteract, canAccess) { } } @@ -149,12 +149,12 @@ namespace Content.Shared.Verbs /// /// The entity being targeted for the verb. /// - public readonly IEntity Target; + public readonly EntityUid Target; /// /// The entity that will be "performing" the verb. /// - public readonly IEntity User; + public readonly EntityUid User; /// /// Can the user physically interact? @@ -181,14 +181,9 @@ namespace Content.Shared.Verbs /// This is only ever not null when is true and the user /// has hands. /// - public readonly IEntity? Using; + public readonly EntityUid? Using; - // for eventual removal of IEntity. - public EntityUid UserUid => User; - public EntityUid TargetUid => Target; - public EntityUid? UsingUid => Using; - - public GetVerbsEvent(IEntity user, IEntity target, IEntity? @using, SharedHandsComponent? hands, bool canInteract, bool canAccess) + public GetVerbsEvent(EntityUid user, EntityUid target, EntityUid? @using, SharedHandsComponent? hands, bool canInteract, bool canAccess) { User = user; Target = target;