예제 #1
0
    protected override void DrawReaction()
    {
        serializedObject.Update();

        CheckAndCreateSubEditors(interactableCallback.conditionCollectionsText);

        for (int i = 0; i < subEditors.Length; i++)
        {
            subEditors[i].OnInspectorGUI();
            EditorGUILayout.Space();
        }

        EditorGUILayout.BeginHorizontal();
        GUILayout.FlexibleSpace();
        if (GUILayout.Button("Add Collection", GUILayout.Width(collectionButtonWidth)))
        {
            ConditionCollectionText newCollection = ConditionCollectionTextEditor.CreateConditionCollection();
            collectionsProperty.AddToObjectArray(newCollection);
        }
        EditorGUILayout.EndHorizontal();

        EditorGUILayout.Space();



        serializedObject.ApplyModifiedProperties();
    }