using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;

public class backMenu : MonoBehaviour
{
    public AudioSource aso;
    public AudioClip music;
    
    void Start()
    {
        PlaySound();
    }

    // Update is called once per frame
    void Update()
    {
        if (Input.GetKeyDown(KeyCode.Space))
        {
            SceneManager.LoadScene(1);
        }
    }

    public void PlaySound()
    {
        if (music != null)
        {
            aso.clip = music;
            aso.Play();
        }
    }
}
