jump-game/Jump Game/Assets/Scripts/World/Winner.cs
2020-04-30 00:04:48 +03:00

16 lines
330 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class Winner : MonoBehaviour
{
void OnCollisionEnter2D(Collision2D collision)
{
if (collision.gameObject.tag == "Player")
{
SceneManager.LoadScene(3);
}
}
}