Example #1
0
    public void Set(BoardGame.Player player)
    {
        if (null == player)
        {
            Log.Error("not found player");
            return;
        }

        _player = player;

        switch (_player.Owner)
        {
        case BoardGame.Cell.EOwner.User:
            Text.gameObject.SetActive(true);
            _button.interactable = true;
            break;

        case BoardGame.Cell.EOwner.AI:
            Text.gameObject.SetActive(false);
            _button.interactable = false;
            break;

        default:
            Log.Error("invalid player");
            break;
        }
    }
    public void Set(BoardGame.Player player)
    {
        _player = player;

        int numCard = _cardArray.Length;

        for (int i = 0; i < numCard; ++i)
        {
            _cardArray[i].Set(player);
            _cardArray[i].Hide();
        }
    }
Example #3
0
    public void Set(BoardGame.Player player)
    {
        if (null != PlayerCardListPanel)
        {
            PlayerCardListPanel.Set(player);
        }
        else
        {
            Log.Error("not found player card list panel");
        }

        if (null != DrawCardPanel)
        {
            DrawCardPanel.Set(player);
        }
        else
        {
            Log.Error("not found draw card panel");
        }
    }
Example #4
0
    public void Set(BoardGame.Player player)
    {
        if (null == player)
        {
            Log.Error("not found player");
            return;
        }

        _player = player;

        BoardGamePlayer p = Manager.Instance.DT.BoardGamePlayer[_player.Id];

        setImage(p.idle);

        if (BoardGame.Cell.EOwner.User == _player.Owner)
        {
            RectTransform rect = GetComponent <RectTransform>();
            rect.rotation = new Quaternion(0.0f, 180.0f, 0.0f, 0.0f);
        }
    }
Example #5
0
    public void Set(BoardGame.EValuationBasis valuationBasis, BoardGame.Player player)
    {
        if (null == player)
        {
            Log.Error("not found player");
            return;
        }

        setNameText(player.Name);

        switch (valuationBasis)
        {
        case BoardGame.EValuationBasis.Tricker:
            setTrickerStats(player);
            break;

        case BoardGame.EValuationBasis.Politician:
            setPolticianStats(player);
            break;

        default:
            break;
        }
    }
Example #6
0
    public void Set(BoardGame.Player player)
    {
        _player = player;

        Hide();
    }
Example #7
0
 private void setPolticianStats(BoardGame.Player player)
 {
     _statPanelArray[0].Set(EStat.GRACE, player.Grace);
     _statPanelArray[1].Set(EStat.MORALITY, player.Morality);
     _statPanelArray[2].Set(EStat.GOODNESS, player.Goodness);
 }
Example #8
0
 private void setTrickerStats(BoardGame.Player player)
 {
     _statPanelArray[0].Set(EStat.INTELLECT, player.Intellect);
     _statPanelArray[1].Set(EStat.TACTIC, player.Tactic);
     _statPanelArray[2].Set(EStat.LEADERSHIP, player.Leadership);
 }