private void AddSelectedEventToState() { if (this.selectedEvent == null || SkillEditor.SelectedFsm == null || SkillEditor.SelectedFsm.HasEvent(this.selectedEvent.get_Name())) { return; } EditorCommands.AddEvent(this.selectedEvent.get_Name()); SkillEditor.Inspector.ResetView(); }
private void AddEvent(string eventName) { if (eventName.Replace(" ", "") == "") { EditorApplication.Beep(); EditorUtility.DisplayDialog(Strings.get_Label_Add_Event(), Strings.get_Error_Invalid_Name(), Strings.get_OK()); return; } EditorCommands.AddEvent(eventName); this.Reset(); }