Files
test/Assets/Editor/DebuggableInspector.cs
T
CuongNV 470113b8fe Revert "bnmb"
This reverts commit 5d1a386148.
2026-05-25 10:36:26 +07:00

24 lines
605 B
C#

using UnityEditor;
using UnityEngine;
namespace BrewMonster
{
[CustomEditor(typeof(MonoBehaviour), true)]
public class DebuggableInspector : Editor
{
public override void OnInspectorGUI()
{
var targetMb = target as MonoBehaviour;
if (targetMb != null && DebugRegistry.IsEnabled(targetMb))
{
GUI.backgroundColor = Color.yellow;
EditorGUILayout.HelpBox("DEBUG ENABLED", MessageType.Info);
GUI.backgroundColor = Color.white;
}
DrawDefaultInspector();
}
}
}