示例#1
0
        public void SetYachtType(YachtType type)
        {
            switch (type)
            {
            case YachtType.none: ComboBYachtType.SelectedIndex = 0; break;

            case YachtType.cruise: ComboBYachtType.SelectedIndex = 1; break;

            case YachtType.sport: ComboBYachtType.SelectedIndex = 2; break;
            }
        }
示例#2
0
    public void setViewImage(YachtType type)
    {
        Vector2 _imageSize = Vector2.zero;

        switch (type)
        {
        case YachtType.DEFAULT:
            shipBodyImage.sprite = shipBodyViewSprite[0];
            shipSailImage.sprite = shipSailViewSprite[0];
            _imageSize           = new Vector2(180, 220);
            break;

        case YachtType.TYPE_A:
            shipBodyImage.sprite = shipBodyViewSprite[1];
            shipSailImage.sprite = shipSailViewSprite[1];
            _imageSize           = new Vector2(210, 220);
            break;
        }

        shipBodyImage.GetComponent <RectTransform>().sizeDelta = _imageSize;
        shipSailImage.GetComponent <RectTransform>().sizeDelta = _imageSize;
    }
示例#3
0
 public bool isContainYacth(YachtType yachtType)
 {
     return(yachtHaveList.Contains(yachtType));
 }
示例#4
0
 public void addYachtHaveList(YachtType yachtType)
 {
     yachtHaveList.Add(yachtType);
 }