示例#1
0
 public static InventoryItem ToInventoryItem(GroundedItem groundedItem, bool autoDestroyGroundedItem = false)
 {
     if (autoDestroyGroundedItem)
     {
         Object.Destroy(groundedItem.gameObject);
     }
     return(new InventoryItem(groundedItem.ItemData));
 }
示例#2
0
 public static InventoryWeapon ToInventoryWeapon(GroundedItem groundedItem, bool autoDestroyGroundedItem = false)
 {
     return(ToInventoryWeapon(ToInventoryItem(groundedItem, autoDestroyGroundedItem)));
 }