Merge remote-tracking branch 'upstream/stable' into ed-08-07-2025-upstream
# Conflicts: # Content.Server/Audio/ContentAudioSystem.cs # Content.Server/Medical/HealthAnalyzerSystem.cs # Content.Server/Shuttles/Systems/ShuttleSystem.cs # Resources/Locale/en-US/navmap-beacons/station-beacons.ftl
This commit is contained in:
@@ -73,10 +73,10 @@ public sealed class SmartEquipSystem : EntitySystem
|
||||
return;
|
||||
|
||||
// early out if we don't have any hands or a valid inventory slot
|
||||
if (!TryComp<HandsComponent>(uid, out var hands) || hands.ActiveHand == null)
|
||||
if (!TryComp<HandsComponent>(uid, out var hands) || hands.ActiveHandId == null)
|
||||
return;
|
||||
|
||||
var handItem = hands.ActiveHand.HeldEntity;
|
||||
var handItem = _hands.GetActiveItem((uid, hands));
|
||||
|
||||
// can the user interact, and is the item interactable? e.g. virtual items
|
||||
if (!_actionBlocker.CanInteract(uid, handItem))
|
||||
@@ -89,7 +89,7 @@ public sealed class SmartEquipSystem : EntitySystem
|
||||
}
|
||||
|
||||
// early out if we have an item and cant drop it at all
|
||||
if (handItem != null && !_hands.CanDropHeld(uid, hands.ActiveHand))
|
||||
if (handItem != null && !_hands.CanDropHeld(uid, hands.ActiveHandId))
|
||||
{
|
||||
_popup.PopupClient(Loc.GetString("smart-equip-cant-drop"), uid, uid);
|
||||
return;
|
||||
@@ -130,7 +130,7 @@ public sealed class SmartEquipSystem : EntitySystem
|
||||
return;
|
||||
}
|
||||
|
||||
_hands.TryDrop(uid, hands.ActiveHand, handsComp: hands);
|
||||
_hands.TryDrop((uid, hands), hands.ActiveHandId!);
|
||||
_inventory.TryEquip(uid, handItem.Value, equipmentSlot, predicted: true, checkDoafter:true);
|
||||
return;
|
||||
}
|
||||
@@ -158,7 +158,7 @@ public sealed class SmartEquipSystem : EntitySystem
|
||||
return;
|
||||
}
|
||||
|
||||
_hands.TryDrop(uid, hands.ActiveHand, handsComp: hands);
|
||||
_hands.TryDrop((uid, hands), hands.ActiveHandId!);
|
||||
_storage.Insert(slotItem, handItem.Value, out var stacked, out _);
|
||||
|
||||
// if the hand item stacked with the things in inventory, but there's no more space left for the rest
|
||||
|
||||
Reference in New Issue
Block a user