コード例 #1
0
        private void AddPositionalTools()
        {
#if UNITY_EDITOR
            _target.UpdateData();
#endif
            _serializedObject = new SerializedObject(_target.data);

            GUILayout.Label("Positional Objects");

            EditorGUILayout.BeginHorizontal();
            {
                AddCrateButton();
                AddUpdateAllPosButton();
                AddDeleteButton();
            }
            EditorGUILayout.EndHorizontal();
        }
コード例 #2
0
        public override void OnInspectorGUI()
        {
            base.OnInspectorGUI();

            _target = (EditSpawnPoints)target;
#if UNITY_EDITOR
            _target.UpdateData();
#endif
            if (_target.data == null)
            {
                return;
            }

            GUILayout.Space(10);

            AddPositionalTools();

            GUILayout.Space(10);

            OpenEditor();
        }