Neg_Utils/NEG/UI/UnityUi/Buttons/OpenWindow.cs

19 lines
509 B
C#

using NEG.UI.UnityUi.Window;
using NEG.UI.UnityUi.WindowSlot;
using System;
using UnityEngine;
using NEG.UI.Window;
using NEG.UI.WindowSlot;
namespace NEG.UI.UnityUi.Buttons
{
[RequireComponent(typeof(BaseButton))]
public class OpenWindow : ButtonReaction
{
[SerializeField] private MonoWindow window;
[Header("Open on default area slot if empty")]
[SerializeField] private MonoWindowSlot slot;
protected override void OnClicked() => window.Open(slot);
}
}