using UnityEngine;
using UnityEngine.SceneManagement;
public class GoNextStage : MonoBehaviour
{
int item;
void PickUpIntem()
{
item++;
if (!(item < 15)) Loader();
}
void Loader()
{
SceneManager.LoadScene("Second"); //<=Название след сцены
}
private void OnTriggerEnter(Collider other)
{
if (other.tag == "Item")
{
other.gameObject.SetActive(false);
PickUpIntem();
}
}
}