Beispiel #1
0
 public void AddClue(string clueToAdd, GuestParams guestParams)
 {
     if (!CompareStrings(clueToAdd, _clueList))
     {
         _clueList.Add(clueToAdd);
         _guestParams.Add(guestParams);
         StartCoroutine(ClueNotificationCoroutine());
     }
 }
Beispiel #2
0
    private void CreateGuest(GuestParams guestParams)
    {
        var go        = Instantiate(guestParams.Prefab, _guestContainer);
        var guestView = go.GetComponent <GuestView>();

        go.SetActive(false);

        _guests.Add(guestParams, guestView);
    }
Beispiel #3
0
    IEnumerator ClueTriggerCoroutine(string clueToAdd, float duration, GuestParams guestParams)
    {
        ClueTrigger clueTrigger = _clueTrigger.GetComponent <ClueTrigger>();

        clueTrigger.Connect(clueToAdd, guestParams);
        yield return(new WaitForSeconds(duration));

        clueTrigger.Utilize();
    }
Beispiel #4
0
    public void AddClue(string clueToAdd, GuestParams guestParams)
    {
        if (CompareStrings(clueToAdd))
        {
            return;
        }

        foreach (var tab in _clueTabs)
        {
            if (tab.name == "Conclusions" && CheckForConclusion(clueToAdd))
            {
                AddToTab(clueToAdd, tab.transform);
                tab.CheckForSummary(clueToAdd);
            }

            if (guestParams.Name == tab.name)
            {
                AddToTab(clueToAdd, tab.transform);
                tab.CheckForSummary(clueToAdd);
            }
        }
    }
Beispiel #5
0
 public GuestView GetGuestView(GuestParams commandGuestParams)
 {
     return(_guests[commandGuestParams]);
 }
Beispiel #6
0
 public static void CallOnClueGet(string clueToAdd, GuestParams guestParams)
 {
     OnClueGet?.Invoke(clueToAdd, guestParams);
 }
Beispiel #7
0
 public void Connect(string clueToAdd, GuestParams guestParams)
 {
     _lastClue    = clueToAdd;
     _guestParams = guestParams;
     gameObject.SetActive(true);
 }
Beispiel #8
0
 public void TryToGetClue(string clueToAdd, float duration, GuestParams guestParams)
 {
     StartCoroutine(ClueTriggerCoroutine(clueToAdd, duration, guestParams));
 }