This commit is contained in:
fluttershy 2025-01-20 15:07:30 +05:00
parent 830f2129b4
commit 8e506ecd22

View File

@ -2,11 +2,11 @@
#include <includes.h>
int main(int argc, char* argv[]) {
if (argc != 3) return -1;
WebSocket* bot = &WebSocket::getInstance(argv[2], GatewayIntents::AllIntents, false);
bot->on(GatewayEvents::READY, [](const Discord<Message, User>a) {
WebSocket* bot = &WebSocket::getInstance(argv[2], GatewayIntents::AllIntents);
bot->on(GatewayEvents::READY, [](const Discord<Message, User>& a) {
cout << DiscordEndpoints::details::latest << endl;
});
bot->on(GatewayEvents::MESSAGE_CREATE, [](const Discord <Message, User, Author> msg) {
bot->on(GatewayEvents::MESSAGE_CREATE, [](const Discord<Message, User, Author>& msg) {
g(0, msg.net)->send("939957962972229634", j("content", g(2, msg.net)->content()));
});
bot->start();