Hello!
I need help, need get something like that in my inspector with Editor script Without using “defaultInspector()”
Script in MonoBehaviour :
using UnityEngine;
using System.Collections;
public enum StateSide{ left, right}
[System.Serializable]
public class Rotation{
public Vector3 relativeRot;
public int amount = 1;
public StateSide side;
}
public class Test2 : MonoBehaviour{
public Rotation rotation;
void Update () {
// Update logic here...
}
}

Script in Editor:
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
[CustomEditor(typeof(Test2))]
public class Rotate_Inspector : Editor {
Test2 m_target;
void OnEnable () {
m_target = (Test2)target;
}
public override void OnInspectorGUI () {
GUILayout.Label("How i to do?");
}
}
