Exemple #1
0
 // ------------------------------------------------------------------------
 // Functions
 // ------------------------------------------------------------------------
 protected override void OnClick()
 {
     if (SpiritSO.VisitedChat)
     {
         ChatRunner.StartConversation(SpiritSO.SecondChat);
     }
     else
     {
         ChatRunner.StartConversation(SpiritSO.Chat);
     }
 }
Exemple #2
0
    // ------------------------------------------------------------------------
    // Functions
    // ------------------------------------------------------------------------
    protected override void OnClick()
    {
        bool success = Inventory.ItemSOs.All(CorrectOffering.Contains) &&
                       Inventory.Items.Count == CorrectOffering.Count;

        Inventory.ClearInventory();

        if (!success)
        {
            ChatRunner.StartConversation(FailureChat);
        }
        else if (GameController.GetWasDialoguePositive())
        {
            ChatRunner.MarkWaitingForGameEnd();
            ChatRunner.StartConversation(SuccessChat);
            AudioController.EndGame(true);
        }
        else
        {
            ChatRunner.MarkWaitingForGameEnd();
            ChatRunner.StartConversation(NegativeChat);
            AudioController.EndGame(false);
        }
    }