Esempio n. 1
0
 public void InteractObject(InteractableWrapper interactable)
 {
     interactable.Interact();
     if (CurrentGame.CurrentRoom != null)
     {
         CurrentGame.CurrentRoom.RecalculateInteractableVisibility();
     }
     CurrentGame.RefreshAll();
     MainViewModel.GetMainViewModelStatic().CurrentGame.RunActiveEvents();
 }
Esempio n. 2
0
 public void SetExploreMode()
 {
     ExploreMode      = true;
     InventoryMode    = false;
     EquipmentMode    = false;
     ConversationMode = false;
     if (CurrentGame.CurrentRoom != null)
     {
         CurrentGame.CurrentRoom.RecalculateInteractableVisibility();
     }
     CurrentGame.RefreshAll();
     MainViewModel.GetMainViewModelStatic().CurrentGame.RunActiveEvents();
 }
Esempio n. 3
0
 public void UnequipItem()
 {
     if (SelectedEquippedItem != null)
     {
         var i = SelectedEquippedItem;
         if (CurrentGame.TryUnequipItem(SelectedEquippedItem))
         {
             CurrentGame.PlayerInventory.Add(i);
         }
         CurrentGame.RefreshAll();
         RefreshEquippableItems();
         ViewEquipment();
         SelectedEquippedItem = null;
         MainViewModel.GetMainViewModelStatic().CurrentGame.RunActiveEvents();
     }
 }
Esempio n. 4
0
        public void EquipItem()
        {
            if (SelectedEquippableItem != null)
            {
                var unequipped = CurrentGame.TryEquipItem(SelectedEquippableItem);

                CurrentGame.RefreshAll();
                foreach (var a in unequipped)
                {
                    CurrentGame.PlayerInventory.Add(a);
                }
                RefreshEquippableItems();
                ViewEquipment();
                SelectedEquippableItem = null;


                MainViewModel.GetMainViewModelStatic().CurrentGame.RunActiveEvents();
            }
        }