public static bool OnGUIStandardButtons(ControlContext context , DebugViewContext debugContext , bool resetAllowed) { NavmeshBuild build = context.Build; if (!build) return false; TileBuildData tdata = build.BuildData; GUILayout.FlexibleSpace(); // Note: It is assumed that you should't get any debug display options unless // you can reset the build. So they are inside this condition. if (resetAllowed) { if (build.BuildState == NavmeshBuildState.Buildable || build.HasInputData) // One or more debug display options are allowed. GUILayout.Label("Show"); // Always call these. debugContext.OnGUIMeshDisplayOptions(); debugContext.OnGUIDebugExtras(); GUILayout.Space(MarginSize); GUIStyle style = (tdata != null && tdata.NeedsBakingCount() == 0) ? ControlUtil.HighlightedButton : GUI.skin.button; return OnGUIResetButton(context, debugContext, style); } return false; }
public static bool OnGUIStandardButtons(ControlContext context , DebugViewContext debugContext , bool resetAllowed) { NavmeshBuild build = context.Build; if (!build) { return(false); } TileBuildData tdata = build.BuildData; GUILayout.FlexibleSpace(); // Note: It is assumed that you should't get any debug display options unless // you can reset the build. So they are inside this condition. if (resetAllowed) { if (build.BuildState == NavmeshBuildState.Buildable || build.HasInputData) { // One or more debug display options are allowed. GUILayout.Label("Show"); } // Always call these. debugContext.OnGUIMeshDisplayOptions(); debugContext.OnGUIDebugExtras(); GUILayout.Space(MarginSize); GUIStyle style = (tdata != null && tdata.NeedsBakingCount() == 0) ? ControlUtil.HighlightedButton : GUI.skin.button; return(OnGUIResetButton(context, debugContext, style)); } return(false); }