From 6136631d2dcd9b1f561fa589acabcda7de8e2f36 Mon Sep 17 00:00:00 2001 From: Cara Salter Date: Sat, 10 Jun 2023 00:06:07 -0400 Subject: mail: Init mail module Also bind the slash command and form submit events properly Change-Id: I8d01cb0075945c79c6bf991fa4d64f5227dd5f86 --- include/142bot/bot.hpp | 2 ++ include/142bot/modules.hpp | 4 ++++ 2 files changed, 6 insertions(+) (limited to 'include') diff --git a/include/142bot/bot.hpp b/include/142bot/bot.hpp index 1fdb042..dc709ef 100644 --- a/include/142bot/bot.hpp +++ b/include/142bot/bot.hpp @@ -68,6 +68,8 @@ public: void onVoiceStateUpdate (const dpp::voice_state_update_t &event); void onVoiceServerUpdate (const dpp::voice_server_update_t &event); void onWebhooksUpdate (const dpp::webhooks_update_t &event); + void onSlashCommand (const dpp::slashcommand_t &event); + void onFormSubmit (const dpp::form_submit_t &event); }; #endif diff --git a/include/142bot/modules.hpp b/include/142bot/modules.hpp index 37f4401..617d5af 100644 --- a/include/142bot/modules.hpp +++ b/include/142bot/modules.hpp @@ -55,6 +55,8 @@ enum Events I_OnVoiceServerUpdate, I_OnWebhooksUpdate, I_OnCommand, + I_OnSlashCommand, + I_OnFormSubmit, I_END }; @@ -202,6 +204,8 @@ public: virtual bool OnVoiceServerUpdate(const dpp::voice_server_update_t &obj); virtual bool OnWebhooksUpdate(const dpp::webhooks_update_t &obj); virtual bool OnCommand(const dpp::message_create_t &message, const std::string &command, const std::vector& params); + virtual bool OnSlashCommand(const dpp::slashcommand_t &event); + virtual bool OnFormSubmit(const dpp::form_submit_t &event); void EmbedSimple(const std::string &message, int64_t channelID); void EmbedError(int64_t channelId, std::exception &e); void EmbedError(const std::string &message, int64_t channelId); -- cgit v1.2.3