Ejemplo n.º 1
0
 public Color GetColor()
 {
     if (localizedName == "Air")
     {
         return(Color.Transparent);
     }
     else if (material.mapColor == "")
     {
         return(Color.Black);
     }
     else
     {
         return(Color.FromArgb(NumberTransfer.HexString2Int(material.mapColor.Substring(0, 2)), NumberTransfer.HexString2Int(material.mapColor.Substring(2, 2)), NumberTransfer.HexString2Int(material.mapColor.Substring(4, 2))));
     }
 }
Ejemplo n.º 2
0
 public Color GetColor()
 {
     if (transparent)
     {
         return(Color.Transparent);
     }
     else if (color == "")
     {
         return(Color.Black);
     }
     else
     {
         return(Color.FromArgb(NumberTransfer.HexString2Int(color.Substring(0, 2)), NumberTransfer.HexString2Int(color.Substring(2, 2)), NumberTransfer.HexString2Int(color.Substring(4, 2))));
     }
 }