using UnityEngine; using UnityEngine.SceneManagement; public class Test_Retry : MonoBehaviour { // 이 함수는 버튼에 연결될 함수입니다. public void RestartCurrentScene() { // 현재 활성화된 씬의 이름을 가져옵니다. string currentSceneName = SceneManager.GetActiveScene().name; // 씬을 다시 로드합니다. SceneManager.LoadScene(currentSceneName); } }