Exemplo n.º 1
0
    /// <summary>
    /// create references to the needed scripts and collects data where n eeded on startup
    /// </summary>
    private void Awake()
    {
        GetBounds();
        GameObject tGameobject = GameObject.FindGameObjectWithTag("GameData");

        _gameData   = tGameobject.GetComponent <GameData>();
        _itemSpawer = ItemSpawer.Instance;
    }
Exemplo n.º 2
0
    /// <summary>
    /// Sets variables
    /// </summary>
    private void Awake()
    {
        handTransform = transform;
        GameObject tGameobject = GameObject.FindGameObjectWithTag("GameData");

        _gameData    = tGameobject.GetComponent <GameData>();
        tGameobject  = GameObject.FindGameObjectWithTag("ItemSpawner");
        _itemSpawner = tGameobject.GetComponent <ItemSpawer>();
    }