diff --git a/languages/locale_en.hpp b/languages/locale_en.hpp index aacc39f..e7b7131 100644 --- a/languages/locale_en.hpp +++ b/languages/locale_en.hpp @@ -1,5 +1,20 @@ +// Bot info +#define BOT_NAME "The Bartender bot" +#define BOT_VERSION "v0.2" + #define CURRENCY_NAME "Night Coin" +// Command ping +#define COMMAND_PING_DESCRIPTION "Ping-pong test" + +// Command about +#define COMMAND_ABOUT_DESCRIPTION "Info about the bot" +#define COMMAND_ABOUT_RESPONSE \ + "## " BOT_NAME " " BOT_VERSION \ + "\n-> Written by <@!607952795794145281>.\n-> Source code " \ + "https://git.thenight.club/cat/BartenderBot.\n-> Made with " \ + "[D++](https://dpp.dev/) and tears." + // Command balance/bal #define COMMAND_BALANCE_DESCRIPTION "See someone's balance of " CURRENCY_NAME #define COMMAND_BALANCE_USER_DESCRIPTION \ diff --git a/settings.hpp.empty b/settings.hpp.empty index 156efb2..fa0664f 100644 --- a/settings.hpp.empty +++ b/settings.hpp.empty @@ -8,3 +8,4 @@ // Replace locale_en with any available one #include "languages/locale_en.hpp" + diff --git a/src/CommandManagement.hpp b/src/CommandManagement.hpp index f52f9c2..97fb25a 100644 --- a/src/CommandManagement.hpp +++ b/src/CommandManagement.hpp @@ -13,7 +13,10 @@ void deleteCommands(const dpp::ready_t &event, dpp::cluster &bot) { void createCommands(const dpp::ready_t &event, dpp::cluster &bot) { bot.global_command_create( - dpp::slashcommand("ping", "Ping-pong test", bot.me.id)); + dpp::slashcommand("ping", COMMAND_PING_DESCRIPTION, bot.me.id)); + + bot.guild_command_create( + dpp::slashcommand("about", COMMAND_ABOUT_DESCRIPTION, bot.me.id), GUILD); // Money related stuff bot.guild_command_create( diff --git a/src/Commands/OtherCommands.cpp b/src/Commands/OtherCommands.cpp index 31a58ab..f577447 100644 --- a/src/Commands/OtherCommands.cpp +++ b/src/Commands/OtherCommands.cpp @@ -1,4 +1,7 @@ +#include "../../settings.hpp" #include void commandPing(const dpp::slashcommand_t &event) { event.reply("Pong"); } -void commandAbout(const dpp::slashcommand_t &event) { event.reply("Pong"); } +void commandAbout(const dpp::slashcommand_t &event) { + event.reply(COMMAND_ABOUT_RESPONSE); +}