public bool Contains(Interactable interactable)
 {
     if (interactable == null)
     {
         return(false);
     }
     return(EnteredObjects.ContainsKey(interactable));
 }
 private bool AddToDictionary(Interactable interactable)
 {
     if (EnteredObjects.ContainsKey(interactable))
     {
         EnteredObjects[interactable]++;
         return(false);
     }
     else
     {
         EnteredObjects.Add(interactable, 1);
         return(true);
     }
 }
    private bool RemoveFromDictionary(Interactable interactable)
    {
        if (EnteredObjects.ContainsKey(interactable))
        {
            EnteredObjects[interactable]--;

            if (EnteredObjects[interactable] == 0)
            {
                EnteredObjects.Remove(interactable);
                return(true);
            }
        }
        else
        {
            Logger.Warning("Object exited invalid amount of times: " + interactable.name);
        }

        return(false);
    }