void Start() { casIgre = timeIgre; if (!PlayerPrefs.HasKey("score")) { PlayerPrefs.SetInt("score", 0); } menuSkript = GameObject.Find("Main Camera").GetComponent <menuSkripta>(); zmaga(); hisoDodaj = GameObject.Find("dodajHiso"); cilj = GetComponent <RectTransform>().localPosition.y; //hpText.text = "HP " + hp; colStanje = -1; //seznamDaril = new GameObject[darila.Length * 2]; //for (int i = 0; i < darila.Length; i++) //{ // for(int j = 0; j < 2; j++) // { // seznamDaril[i*2 + j] = Instantiate(darila[i], new Vector3(30000, 20000 + Random.value * 2000), Quaternion.Euler(0, 0, 0)) as GameObject; // } //} seznamDaril = shuffle(seznamDaril); GetComponent <RectTransform>().localPosition = new Vector3(212 - 1000, 13, 0); }
void Start() { casIgre = timeIgre; if (!PlayerPrefs.HasKey("score")) { PlayerPrefs.SetInt("score", 0); } menuSkript = GameObject.Find("Main Camera").GetComponent<menuSkripta>(); zmaga(); hisoDodaj = GameObject.Find("dodajHiso"); cilj = GetComponent<RectTransform>().localPosition.y; //hpText.text = "HP " + hp; colStanje = -1; //seznamDaril = new GameObject[darila.Length * 2]; //for (int i = 0; i < darila.Length; i++) //{ // for(int j = 0; j < 2; j++) // { // seznamDaril[i*2 + j] = Instantiate(darila[i], new Vector3(30000, 20000 + Random.value * 2000), Quaternion.Euler(0, 0, 0)) as GameObject; // } //} seznamDaril = shuffle(seznamDaril); GetComponent<RectTransform>().localPosition = new Vector3(212 - 1000, 13, 0); }