i'm making a 2D game and my Menu panels are showing when i press play on unity they show as opened is there anyway to make them closed and only show when i press on menu button. this is the picture from the game:
And this is the script for panel opener when i press the menu button:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class PanelOpener : MonoBehaviour
{
public GameObject Panel;
public void OpenPanle()
{
if (Panel != null)
{
bool isActive = Panel.activeSelf;
Panel.SetActive(!isActive);
}
}
}
