Esempio n. 1
0
        override public void OnGUI(MaterialEditor materialEditor, MaterialProperty[] properties)
        {
            material = materialEditor.target as Material;

            if (tools == null)
            {
                tools = new EditorTools("GlassMaterialEditor" + material.GetInstanceID());
            }

            tools.Label("It is recommended that you edit Glass objects in their Glass inspector panel rather than directly within the Materials they use.", true);

            tools.Divider();

            tools.Label("The settings below are not currently documented and editing them may result in adverse effects.", true);

            tools.Divider();

            if (tools.ShowSection("I Understand - Show The Settings", ref showAdvancedSettings))
            {
                base.OnGUI(materialEditor, properties);

                tools.EndSection();
            }
        }
Esempio n. 2
0
    public override void OnInspectorGUI()
    {
        base.OnInspectorGUI();

        var dood = (Dood)target;

        if (Application.isPlaying && dood.behaviourTree != null)
        {
            EditorTools.Label("<b>Behaviour tree details:</b>");
            EditorTools.Label("<b>Current behaviour tree input:</b>");
            EditorTools.Label(dood.behaviourTree.data.ToString());
            EditorTools.Divider();

            EditorTools.Label(dood.behaviourTree.command.ToString());

            EditorTools.Divider();

            EditorTools.Label("<b>Behaviour tree:</b>");
            BehaviourTreeDrawer <Dood.DoodAIInput, Dood.DoodAIOutput> .Draw(dood.behaviourTree);
        }
    }