Exemplo n.º 1
0
 public GalaxyFeature(string _name, GalaxyFeatureType _featureType, Color _iconColor)
 {
     name        = _name;
     featureType = _featureType;
     iconColor   = new Color(_iconColor.r * 0.5f, _iconColor.g * 0.5f, _iconColor.b * 0.5f);
     icon        = SpriteLoader.GetFeatureSprite(featureType.ToString());
 }
Exemplo n.º 2
0
 private void ShowFeatures(GalaxyFeatureType t)
 {
     foreach (Sector s in allSectors)
     {
         s.ShowFeatures(t);
     }
 }
Exemplo n.º 3
0
    public void ShowFeatures(GalaxyFeatureType t)
    {
        List <GalaxyFeature> f = sectorData.features.FindAll(i => i.featureType == t);

        if (f.Count != 0)
        {
            Debug.Log("Feature Found!");
            foregroundImage.gameObject.SetActive(true);
            foregroundImage.sprite = f[0].icon;
            foregroundImage.color  = f[0].iconColor;
        }
        else
        {
            foregroundImage.gameObject.SetActive(false);
        }
    }