Example #1
0
    // Use this for initialization
    void Start()
    {
        // Get the game manager
        GM = GameObject.Find("__GM").GetComponent <FB_GameManager>();
        // Get UI components
        CountDown    = transform.Find("Countdown").gameObject.GetComponent <Text>();
        Score_player = transform.Find("Score_player").gameObject.GetComponent <Text>();
        Score_enemy  = transform.Find("Score_enemy").gameObject.GetComponent <Text>();
        Replay_game  = transform.Find("Replay game").gameObject;
        Replay_boss  = transform.Find("Replay boss").gameObject;

        Curtain = transform.Find("Curtain").gameObject.GetComponent <Image>();
    }
Example #2
0
 // Use this for initialization
 void Start()
 {
     RB = GetComponent <Rigidbody>();
     GM = GameObject.Find("__GM").GetComponent <FB_GameManager>();
 }