Пример #1
0
        public bool DropItem(GameObject prefab, Vector3 position)
        {
            if (_Inventory == null)
            {
                return(false);
            }

            _Inventory.Spawn(prefab, position);
            _Inventory = null;

            return(true);
        }
Пример #2
0
        public bool PickItem(PickupableItem item)
        {
            if (item == null || _Inventory != null)
            {
                return(false);
            }

            _Inventory = item;
            _Inventory.Despawn();

            return(true);
        }
Пример #3
0
        public void Init(PickupableItem item)
        {
            if (_IsInitialized || item == null)
            {
                return;
            }

            item.Body    = this;
            MainSprite   = item.MainSprite;
            TopSprite    = item.TopSprite;
            BottomSprite = item.BottomSprite;

            base.Init(item);
        }
Пример #4
0
 public bool PickItem(PickupableItem item)
 {
     return(_ActivityManager.PickItem(item));
 }