Ejemplo n.º 1
0
    public void ShowScores(List <ScorePair> list, bool isHalf)
    {
        GameObject newOb = Instantiate(ScoreBoardPrefab);

        ActiveScoreBoardUI = newOb.GetComponent <ScoreboardBehavior>();
        ActiveScoreBoardUI.UpdateScores(list, isHalf);
    }
Ejemplo n.º 2
0
    public void OnNewRound(List <Card> newCards, string trickLeaderName, bool isIndianRound)
    {
        cardHandBehavior.SetCards(newCards, isIndianRound);
        GameObject bidUIObj = Instantiate(bidUIPrefab);

        ActiveBidUI = bidUIObj.GetComponent <BidUIBehavior>();
        ActiveBidUI.SetupBidUI(newCards.Count, trickLeaderName, isIndianRound);

        ActiveBidUI.BidEvent.AddListener(OnBidChosen);
        myAudioSource.PlayOneShot(DealSound);
        if (ActiveScoreBoardUI != null)
        {
            Destroy(ActiveScoreBoardUI.gameObject);
            ActiveScoreBoardUI = null;
        }
        if (ActiveRoundScore != null)
        {
            Destroy(ActiveRoundScore);
            ActiveRoundScore = null;
        }
    }