コード例 #1
0
ファイル: TestPlugin.cs プロジェクト: Sugrob57/vkBotCore
 private static void UITest1(CommandContext context)
 {
     if (context.Sender.IsAppAdmin)
     {
         var k = new Keyboard("test")
         {
             OneTime = true
         };
         k.Add(new KeyboardTextButton("test button 1", (c, u, b, p) => c.SendMessageAsync("Used by " + u.GetMentionLine()))
         {
             Color = ButtonColor.Red
         });
         k.AddOnNewLine(new KeyboardTextButton("test button 2", (c, u, b, p) => c.SendMessageAsync("Used by " + u.GetMentionLine()))
         {
             Color = ButtonColor.Green
         });
         k.Add(new KeyboardTextButton("test button 3", (c, u, b, p) => c.SendMessageAsync("Used by " + u.GetMentionLine()))
         {
             Color = ButtonColor.Blue
         });
         context.Chat.SendKeyboardAsync(k);
     }
 }