public override void OnDrawOutport(int outportIndex, OutportContainer outportContainer)
        {
            base.OnDrawOutport(outportIndex, outportContainer);

            SerializedProperty conditionalProp = TargetProperty
                                                 .FindPropertyRelative(BlackboardConditional.ConditionalsVarName)
                                                 .GetArrayElementAtIndex(outportIndex);


            outportContainer.OutportBody.Add(new Label(BlackboardConditional.GetOutportLabel(conditionalProp)));
        }
        private void ValidateBlackboardElement(int undoGroup = -1)
        {
            TargetProperty.serializedObject.Update();

            if (undoGroup == -1)
            {
                undoGroup = Undo.GetCurrentGroup();
            }

            BlackboardConditional target = (Target as BlackboardConditional);

            if (BlackboardProperties.GetElementById(target.BlackboardElementId) == null)
            {
                TargetProperty.FindPropertyRelative(BlackboardConditional.BlackboardElementIdVarName).stringValue = "";
                SerializedProperty conditionalsList = TargetProperty.FindPropertyRelative(BlackboardConditional.ConditionalsVarName);
                NodeGraph.RemoveAllOutportsFromNode(TargetProperty);
                conditionalsList.arraySize = 0;
                TargetProperty.serializedObject.ApplyModifiedProperties();
            }
            Undo.CollapseUndoOperations(undoGroup);
            TargetProperty.serializedObject.Update();
        }