public override void OnInspectorGUI() { TweenBase item = (TweenBase)target; if (item.WarnCurveLooping(item)) { EditorGUILayout.HelpBox("Curve is set to clamp, but tween is set to looping.", MessageType.Warning); } if (item.WarningRendererVisibilityCheck(item)) { EditorGUILayout.HelpBox("Auto Paused : Check PAUSE OFFSCREEN setting", MessageType.Warning); } if (Application.isPlaying) { if (GUILayout.Button("Play")) { item.ResetToStart(); item.PlayFromCurrentState(); } } //DoDrawDefaultInspector(this.serializedObject); base.OnInspectorGUI(); }