Ejemplo n.º 1
0
 private void Start()
 {
     input          = player.GetComponent <InputComponent>();
     input.OnPause += PauseGame;
     statVendor     = GameObject.Find("Stat Vendor NPC").GetComponent <StatVendor>();
     StartCoroutine(UpdateUI());
     //pausePanel = GameObject.Find("PausePanel");
 }
Ejemplo n.º 2
0
    // When a new scene is loaded, run this code
    void OnLevelFinishedLoading(Scene scene, LoadSceneMode mode)
    {
        player.GetComponent <Inventory>().PopulateInventory();

        if (scene.name.Equals("Hub"))
        {
            statVendor = GameObject.Find("Stat Vendor NPC").GetComponent <StatVendor>();
        }
    }