Example #1
0
    void Start()
    {
        item = GetComponent <itemCount>();

        zanki = new GameObject[4];
        for (int i = 0; i < 4; i++)
        {
            zanki[i] = GameObject.Find("Zanki" + (i));
        }
    }
Example #2
0
    void Start()
    {
        plyr     = GameObject.Find("player");
        enemy    = GameObject.Find("RedEnemy");
        enemy1   = GameObject.Find("PinkEnemy");
        textCntr = GameObject.Find("TextController");

        player      = plyr.GetComponent <playerScr>();
        playerSpeed = plyr.GetComponent <playerMoveScr>();
        item        = plyr.GetComponent <itemCount>();
        text        = textCntr.GetComponent <textScr>();
    }