Beispiel #1
0
 public void DistributeSides()
 {
     //Debug.Log("Left width = " + left.GetWidth());
     left.transform.localPosition = new Vector3(divider.transform.localPosition.x,
                                                divider.transform.localPosition.y,
                                                0f);
     right.transform.localPosition = new Vector3(divider.transform.localPosition.x,
                                                 divider.transform.localPosition.y,
                                                 0f);
     left.DistributeColumns();
     right.DistributeColumns();
 }
Beispiel #2
0
    public void FreeChildCards()
    {
        List <CardController> cards = card.GetChildCards();

        card.FreeChildren();
        Destroy(card.gameObject);
        SetCard(cards[0]);
        cards[0].SetColumn(this);
        cards[0].transform.localPosition = Vector3.zero;
        //Debug.Log("cards[0] = " + cards[0].name + "; column = " + cards[0].GetColumn());
        for (int i = 1; i < cards.Count; i++)
        {
            side.InsertCardAfter(cards[i - 1].GetColumn(), cards[i]);
        }
        side.DistributeColumns();
    }