public override void OnInspectorGUI() { TemplateObject t = (TemplateObject)target; showJSON = EditorGUILayout.Foldout(showJSON, "GFF Template JSON"); if (showJSON) { scroll = EditorGUILayout.BeginScrollView(scroll, GUILayout.Height(200)); EditorGUILayout.TextArea(t.GetJSON()); EditorGUILayout.EndScrollView(); } anim = EditorGUILayout.TextField("Animation", anim); if (GUILayout.Button("Play Current Animation")) { ((TemplateObject)target).GetComponent <Animation>().Play(anim); } }