mirror of
https://github.com/Fluffy-Bean/Again.git
synced 2025-05-19 01:44:56 +00:00
:3
This commit is contained in:
parent
90cf5a6112
commit
24501eac1e
13 changed files with 83 additions and 208 deletions
|
@ -5,24 +5,12 @@ using UnityEngine.SceneManagement;
|
|||
|
||||
public class endTrigger : MonoBehaviour
|
||||
{
|
||||
|
||||
private void OnTriggerEnter(Collider other)
|
||||
private void OnTriggerEnter(Collider other)
|
||||
{
|
||||
if (other.gameObject.CompareTag("Player"))
|
||||
{
|
||||
if (other.gameObject.CompareTag("Player"))
|
||||
{
|
||||
SceneManager.LoadScene("end");
|
||||
}
|
||||
}
|
||||
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
SceneManager.LoadScene("end");
|
||||
SceneManager.UnloadSceneAsync("game");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue