Ejemplo n.º 1
0
        public void UpdateInventoryCategories()
        {
            MediPack.Clear();
            Weapons.Clear();
            Currency.Clear();
            Clue.Clear();

            foreach (var gameItem in _inventory)
            {
                if (gameItem is Potion)
                {
                    MediPack.Add(gameItem);
                }
                if (gameItem is Weapon)
                {
                    Weapons.Add(gameItem);
                }
                if (gameItem is Coin)
                {
                    Currency.Add(gameItem);
                }
                if (gameItem is Clues)
                {
                    Clue.Add(gameItem);
                }
            }
        }
Ejemplo n.º 2
0
 private void ProcessMediPackUse(MediPack mediPack)
 {
     _player.Health += mediPack.HealthChange;
     _player.Lives  += mediPack.LivesChange;
     _player.RemoveGameItemFromInventory(_currentGameItem);
 }