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.
 
 
 
 

34 lines
653 B

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;
public class MainMenu : MonoBehaviour
{
public GameObject menu;
public GameObject credits;
// Start is called before the first frame update
void Start()
{
menu.SetActive(true);
credits.SetActive(false);
}
public void SwapCanvas()
{
menu.SetActive(!menu.activeSelf);
credits.SetActive(!credits.activeSelf);
}
public void StartGame()
{
SceneManager.LoadScene(1);
}
// Update is called once per frame
void Update()
{
}
}