Beispiel #1
0
 // Use this for initialization
 void Start()
 {
     xml = new XMLPlayer();
     GameObject.Find("/Canvas/Record").GetComponent <Text>().text = "" + xml.getRecord() + " m.";
     for (int i = 0; i < xml.getNumLogros(); i++)
     {
         if (xml.getLogro(i + 1))
         {
             string path = "/Canvas/Logros/Nivell" + (i + 1);
             GameObject.Find(path).SetActive(true);
         }
     }
 }
Beispiel #2
0
    // Use this for initialization
    void Awake()
    {
        xml            = new XMLPlayer();
        pantallaNivell = GameObject.Find("/Canvas/PantallaNivell");
        pantallaNivell.SetActive(false);

        for (int i = 0; i < xml.getNumLogros(); i++)
        {
            if (xml.getLogro(i + 1))
            {
                GameObject.Find("/Canvas/ScrollRect/Nivells/" + (i + 1)).GetComponent <Image>().sprite = nivells[i];
            }
        }
    }