public void show(int randomizedIndex) { gc = GameObject.Find("GameController"); fcgc = gc.GetComponent <fcGameController> (); img.GetComponent <showImage> ().show(randomizedIndex.ToString()); uiTxtHindiName.text = fcgc.flashCards.cardList [randomizedIndex].hindiName; uiTxtEnglishName.text = fcgc.flashCards.cardList [randomizedIndex].englishName; uiTxtHindiRomanName.text = fcgc.flashCards.cardList [randomizedIndex].hindiRomanName; }
// Use this for initialization void Start() { GameObject go = GameObject.Find("GameController"); if (go != null) { gameControllerScript = go.GetComponent <fcGameController>(); } if (gameControllerScript == null) { Debug.Log("Cannot find 'GameController' script"); } }
void Start() { targetRotation = transform.rotation; GameObject gameControllerObject = GameObject.Find("GameController"); if (gameControllerObject != null) { gameController = gameControllerObject.GetComponent <fcGameController>(); } if (gameController == null) { Debug.Log("Cannot find 'GameController' script"); } }
// Use this for initialization void Start() { GameObject go = GameObject.Find("GameController"); if (go != null) { gameControllerScript = go.GetComponent <fcGameController> (); } if (gameControllerScript == null) { Debug.Log("Cannot find 'GameController' script"); } maxMove = gameControllerScript.getPH2().transform.position.y - gameControllerScript.getPH3().transform.position.y; maxMove = 0.40f * Mathf.Abs(maxMove); touchRect = new Rect(0, 0, Screen.width, Screen.height * 0.80f); }
void Start() { gc = GameObject.Find("GameController"); fcgc = gc.GetComponent <fcGameController> (); }