game: run completion/failure trigger scripts

This commit is contained in:
sippy-thinks 2024-08-11 13:11:17 +08:00
parent a00f8c9b7c
commit d5e7a9970a
5 changed files with 2522 additions and 0 deletions

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,20 @@
/*
* author: sai puay
* date: 11/8/2024
* description: game run completion trigger collision
*/
using System;
using UnityEngine;
/// <summary>
/// game run completion trigger collision class
/// </summary>
public class RunCompletionTrigger : MonoBehaviour
{
private void OnTriggerEnter(Collider other)
{
GameManager.Instance.SetDisplayState(GameManager.DisplayState.OverlayCompleteUnderTimeMenu);
}
}

View file

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 770ec800e73f4df89e7c6a433fdf29a4
timeCreated: 1723352274

View file

@ -0,0 +1,19 @@
/*
* author: sai puay
* date: 11/8/2024
* description: game run failure trigger collision
*/
using System;
using UnityEngine;
/// <summary>
/// game run failure trigger collision
/// </summary>
public class RunFailureTrigger : MonoBehaviour
{
private void OnTriggerEnter(Collider other)
{
GameManager.Instance.SetDisplayState(GameManager.DisplayState.OverlayFailedOverTimeMenu);
}
}

View file

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: ade9f10562b4490b8142692ad54654c3
timeCreated: 1723352378