FECipherVit.CardPic.CardPic C# (CSharp) Method

CardPic() public method

public CardPic ( Card card, string type, FECipherVit Owner ) : System
card Card
type string
Owner FECipherVit
return System
        public CardPic(Card card, string type, FECipherVit Owner)
        {
            this.Owner = Owner;
            NumberInDeck = card.NumberInDeck;
            SerialNo = card.SerialNo;
            SizeMode = PictureBoxSizeMode.StretchImage;
            ratio = Owner.ratio;
            WIDTH = (int)(80 * Owner.ratio);
            HEIGHT = (int)(112 * Owner.ratio);
            Width = WIDTH;
            Height = HEIGHT;
            if (File.Exists(@"img/thumbnails/" + ratio.ToString()+"/(" + Owner.CardData[SerialNo][1] + ")" + Owner.CardData[SerialNo][2] + ".jpg"))
            {
                Image = Image.FromFile(@"img/thumbnails/" + ratio.ToString()+"/(" + Owner.CardData[SerialNo][1] + ")" + Owner.CardData[SerialNo][2] + ".jpg");
            }
            else if (File.Exists(@"img/(" + Owner.CardData[SerialNo][1] + ")" + Owner.CardData[SerialNo][2] + ".jpg"))
            {
                Image = Image.FromFile(@"img/(" + Owner.CardData[SerialNo][1] + ")" + Owner.CardData[SerialNo][2] + ".jpg");
            }
            else
            {
                Image = ErrorImage;
            }
            thisCard = card;
            Type = type;
            FrontShown = card.FrontShown;
            IsHorizontal = card.IsHorizontal;
            Visible = card.Visible;
        }