static public void newOfficer(Chat.ChatLanguageSpecificEventArgs arg) { if (GuildAlert) { if (File.Exists(SoundfileWisper)) { new SoundPlayer(SoundfileWisper).Play(); } else { Logging.WriteDiagnostic(Colors.Red, "Alert playing SoundfileWisper failes"); } } Logging.Write(Colors.Lime, "Officermessage: {0}: {1} - Timestamp: {2}: {3}", arg.Author, arg.Message, DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString()); }
/// <summary> /// Sends Yell Messages /// </summary> /// <param name="e"></param> private static void YellMessage(Chat.ChatLanguageSpecificEventArgs eg) { try { if (!Filtered(eg.Message)) { return; //Skip } var title = FormatIt("{0} Yelled!", eg.Author); SendNotification(eg.Message, title); } catch (Exception ex) { Logging.WriteException(ex); } }
/// <summary> /// Makes Noise at Guild Officer Message and Logs it /// </summary> public void newOfficer(Chat.ChatLanguageSpecificEventArgs arg) { if (Rarekiller.Settings.Guild) { if (File.Exists(Rarekiller.Settings.SoundfileGuild)) { new SoundPlayer(Rarekiller.Settings.SoundfileGuild).Play(); } else if (File.Exists(Rarekiller.Soundfile2)) { new SoundPlayer(Rarekiller.Soundfile2).Play(); } else { Logging.WriteDiagnostic(Colors.MediumPurple, "Rarekiller: playing Soundfile failes"); } Logging.Write(Colors.Lime, "Rarekiller: Officermessage: {0}: {1} - Timestamp: {2}: {3}", arg.Author, arg.Message, DateTime.Now.ToShortDateString(), DateTime.Now.ToShortTimeString()); } }
private void Chat_Officer(Chat.ChatLanguageSpecificEventArgs e) { PrintChatMessage(e.Message, e.Author, e.EventName); }