概要
using UnityEditor; using UnityEditor.Experimental.SceneManagement; using UnityEngine; public static class Example { [MenuItem( "Tools/Hoge" )] public static void Hoge() { var isPrefabMode = PrefabStageUtility.GetCurrentPrefabStage() != null; Debug.Log( isPrefabMode ); } }