Beispiel #1
0
 private void sendButton_Click(object sender, EventArgs e)
 {
     if (messageTextBox.Text != string.Empty)
     {
         BotEntry.HandleMessage(BotEntry.client, new ChannelMessageEventArgs(BotEntry.Channel, "Console", messageTextBox.Text, new Badge {
             mod = true, sub = true, DisplayName = "Console"
         }));
         AddMessage();
     }
 }
Beispiel #2
0
 private void MessageTextBox_PreviewKeyDown(object sender, PreviewKeyDownEventArgs e)
 {
     if (e.KeyCode == Keys.Enter && messageTextBox.Text != string.Empty)
     {
         BotEntry.HandleMessage(BotEntry.client, new ChannelMessageEventArgs(BotEntry.Channel, "Console", messageTextBox.Text, new Badge {
             mod = true, sub = true, DisplayName = "Console"
         }));
         AddMessage();
     }
 }