Custom Inspector

To create a custom inspector, you can

// Declare type of Custom Editor
[CustomEditor(typeof(TankController))]
public class TankControllerEditor : Editor 
{
    // OnInspector GUI is called whenever the object is selected or changed
    public override void OnInspectorGUI()
    {
        base.DrawDefaultInspector(); // shows the default editor
    }
}

Elements

Button

Docu

if (GUILayout.Button("This is my button"))
{
    // Do something
}

Tutorials

Brackeys Tutorial