Created the global.h listener
This commit is contained in:
parent
55b4925b2a
commit
735d4aa827
29
src/listeners/global.h
Normal file
29
src/listeners/global.h
Normal file
@ -0,0 +1,29 @@
|
||||
#ifndef BOT_GLOBAL_H
|
||||
#define BOT_GLOBAL_H
|
||||
|
||||
#include <dpp/dpp.h>
|
||||
#include <mariadb/conncpp.hpp>
|
||||
|
||||
class global {
|
||||
|
||||
public:
|
||||
/**
|
||||
* @brief Sends a message to the webhook
|
||||
* @param url The webhook url
|
||||
* @param bot The bot
|
||||
* @param event The event
|
||||
*/
|
||||
static void send(const std::string &url, dpp::cluster &bot, const dpp::message_create_t &event);
|
||||
|
||||
/**
|
||||
* @brief Executes the global listener
|
||||
* @param con The database connection
|
||||
* @param bot The bot
|
||||
* @param event The event
|
||||
*/
|
||||
static void execute(sql::Connection &con, dpp::cluster &bot, const dpp::message_create_t &event);
|
||||
|
||||
};
|
||||
|
||||
|
||||
#endif //BOT_GLOBAL_H
|
Loading…
x
Reference in New Issue
Block a user