30 lines
743 B
C#
30 lines
743 B
C#
|
|
using System.Collections;
|
|||
|
|
using DarkTonic.MasterAudio;
|
|||
|
|
using DG.Tweening;
|
|||
|
|
using UnityEngine;
|
|||
|
|
using UnityEngine.SceneManagement;
|
|||
|
|
using UnityEngine.UI;
|
|||
|
|
|
|||
|
|
public class WorldMap : MonoBehaviour
|
|||
|
|
{
|
|||
|
|
|
|||
|
|
public void LoadNextScene()
|
|||
|
|
{
|
|||
|
|
MasterAudio.PlaySound("SFX_Click", 1f, null);
|
|||
|
|
// <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>̵<EFBFBD>
|
|||
|
|
StartCoroutine(LoadSceneAfterDelay(5, 0.1f));
|
|||
|
|
}
|
|||
|
|
public void LoadBeforeScene()
|
|||
|
|
{
|
|||
|
|
MasterAudio.PlaySound("SFX_UI_Back", 1f, null);
|
|||
|
|
// <20><><EFBFBD><EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20>̵<EFBFBD>
|
|||
|
|
StartCoroutine(LoadSceneAfterDelay(3, 0.1f));
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
private IEnumerator LoadSceneAfterDelay(int sceneIndex, float delay)
|
|||
|
|
{
|
|||
|
|
yield return new WaitForSeconds(delay);
|
|||
|
|
SceneManager.LoadScene(sceneIndex);
|
|||
|
|
}
|
|||
|
|
|
|||
|
|
}
|