Question by
SaoMaster11211 · Feb 05, 2016 at 11:01 PM ·
c#levelendgamenext level
how to make level go to next
so i made a coin but i need some code to make the coin load the next level`using UnityEngine; using UnityEngine.SceneManagement; using System.Collections; public class NewBehaviourScript : MonoBehaviour { %|106996266_1|% { %|438338939_3|% %|657953855_4|% }`
Comment
opps using UnityEngine; using UnityEngine.Scene$$anonymous$$anagement; using System.Collections; public class NewBehaviourScript : $$anonymous$$onoBehaviour { OnTriggerEnter() { Scene$$anonymous$$anager.LoadScene("2nd"); } }
Answer by heino-heinrich · Feb 06, 2016 at 12:30 PM
try
Mono Behaviour {
OnTriggerEnter (Collider){
SceneManager.LoadScene("2nd")
}
}
should work