private void InteractionEditing(int loop)
        {
            int indexer = 0;

            for (int i = 1; i < interactionOptions.Length; i++)
            {
                if (serializedObject.FindProperty(string.Format(InteractionDataAccess, loop)).stringValue == interactionOptions[i])
                {
                    indexer = i;
                    break;
                }
            }

            if (CustomGUI.ChangeCheckingPopup(ref indexer, interactionOptions, Simulation.Strings.InteractionLabelToExtend(loop + 1)))
            {
                serializedObject.FindProperty(string.Format(InteractionDataAccess, loop)).stringValue = interactionOptions[indexer];
            }

            EditorGUILayout.BeginHorizontal();
            {
                EditorExtensionSettings.LargeMargin();
                EditorExtensionSettings.LargeMargin();
                EditorExtensionSettings.LargeMargin();
                EditorExtensionSettings.LargeMargin();
                EditorExtensionSettings.LargeMargin();
                EditorExtensionSettings.LargeMargin();
                EditorExtensionSettings.MediumMargin();

                if (GUILayout.Button("Edit interactions"))
                {
                    NEEDSIMEditor.CustomMainWindow.MainWindowInit(CustomMainWindow.Screens.Interactions);
                }
            }
            EditorGUILayout.EndHorizontal();
        }
        private void SmartObjectGUI()
        {
            EditorGUILayout.BeginVertical();
            {
                EditorExtensionSettings.StandardMargin();
                //This can be used if you want to have more than one interaction on a NEEDSIM Node, but we do not yet officially
                //support this.

                /*EditorGUILayout.BeginHorizontal();
                 * {
                 *  EditorGUILayout.LabelField(Simulation.Strings.InspectorNumberOfInteractionsLabel, EditorSettings.StandardEditorFieldWidth);
                 *  CustomGUI.LargeMargin();
                 *  EditorGUI.BeginChangeCheck();
                 *  serializedObject.FindProperty(InteractionDataLength).intValue
                 *      = EditorGUILayout.IntSlider(serializedObject.FindProperty(InteractionDataLength).intValue,
                 *                                  1,
                 *                                  EditorSettings.MaxNumberOfInteractionPerSmartObject,
                 *                                  EditorSettings.StandardEditorFieldWidth);
                 * } EditorGUILayout.EndHorizontal();
                 * CustomGUI.LargeMargin();*/

                if (serializedObject.FindProperty(InteractionDataLength).intValue < 1)
                {
                    serializedObject.FindProperty(InteractionDataLength).intValue = 1;
                }

                for (int i = 0; i < serializedObject.FindProperty(InteractionDataLength).intValue; i++)
                {
                    InteractionEditing(i);
                }

                EditorExtensionSettings.StandardMargin();
                IsAgent.boolValue = EditorGUILayout.ToggleLeft(Simulation.Strings.IsAgentLabel, IsAgent.boolValue, EditorExtensionSettings.StandardEditorFieldWidth);
                if (IsAgent.boolValue)
                {
                    AgentEditing();
                }

                EditorExtensionSettings.MediumMargin();
                if (territorySettings = EditorGUILayout.Foldout(territorySettings, Simulation.Strings.TerritoryControlHeadline))
                {
                    SlotEditing();
                }
            }
            EditorGUILayout.EndVertical();
        }