You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
484 B

3 months ago
using System;
using UnityEngine;
using UnityEngine.UI;
3 months ago
public class Goal : MonoBehaviour
{
public GameObject WinUI;
3 months ago
public AudioClip Win;
3 months ago
private void OnTriggerEnter(Collider other)
{
if (other.tag == "IceBlock")
{
Debug.Log("Win");
WinUI.SetActive(true);
3 months ago
}
if (WinUI.activeSelf)
{
3 months ago
BackgroundManager.StopBG();
BackgroundManager.PlayBG(false,Win);
3 months ago
}
}
}