640 {
641 if( GetInventory().CanAddAttachment( item ) )
642 {
644 }
645 else
646 {
647 GameInventory inventory = GetInventory();
648 GameInventory itemInventory = item.GetInventory();
650 {
651 int slot_id = itemInventory.
GetSlotId(i);
654 {
656 }
657 }
658 }
659 return false;
660 }
override bool PredictiveTakeEntityAsAttachment(notnull EntityAI item)
bool PredictiveSwapEntities(notnull EntityAI item1, notnull EntityAI item2)
static bool CanSwapEntitiesEx(notnull EntityAI item1, notnull EntityAI item2)
proto native int GetSlotId(int index)
attachments
proto native int GetSlotIdCount()
proto native EntityAI FindAttachment(int slot)
Returns attached entity in slot (you can use InventorySlots.GetSlotIdFromString(name) to get slot id)