UnityGameProjectsCode / DiceAndMenGame / UICommands.cs
UICommands.cs
Raw
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.SceneManagement;

public class UICommands : MonoBehaviour
{
    public void LoadSelectedScene(int sceneID)
    {
        SceneManager.LoadScene(sceneID);
    }

    public void SetOppositeState(GameObject targetObject)
    {
        targetObject.SetActive(!targetObject.activeSelf);
    }

    public void QuitGame()
    {
        Application.Quit();
    }
}