public override void OnInspectorGUI()
    {
        base.OnInspectorGUI();

        if (GUILayout.Button("Add Points"))
        {
            //add called function
            curve.AddPoints();
        }
    }