Files
racesm/Assets/Scripts/BackToStart.cs
2024-04-25 15:08:17 +02:00

18 lines
403 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class BackToStart : MonoBehaviour
{
public void returnToStart()
{
Destroy(GameObject.Find("Car Data"));
Destroy(GameObject.Find("SkyboxManager"));
Destroy(GameObject.Find("GameManager"));
SceneManager.LoadScene(0);
}
}