diff options
Diffstat (limited to 'discord/emoji.hpp')
-rw-r--r-- | discord/emoji.hpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/discord/emoji.hpp b/discord/emoji.hpp new file mode 100644 index 0000000..e4839f2 --- /dev/null +++ b/discord/emoji.hpp @@ -0,0 +1,22 @@ +#pragma once +#include <string> +#include <vector> +#include "json.hpp" +#include "snowflake.hpp" +#include "user.hpp" + +struct Emoji { + Snowflake ID; // null + std::string Name; // null (in reactions) + std::vector<Snowflake> Roles; // opt + User Creator; // opt + bool NeedsColons = false; // opt + bool IsManaged = false; // opt + bool IsAnimated = false; // opt + bool IsAvailable = false; // opt + + friend void from_json(const nlohmann::json &j, Emoji &m); + + std::string GetURL() const; + static std::string URLFromID(std::string emoji_id); +}; |