diff options
author | ouwou <26526779+ouwou@users.noreply.github.com> | 2020-12-22 02:24:09 -0500 |
---|---|---|
committer | ouwou <26526779+ouwou@users.noreply.github.com> | 2020-12-22 02:24:09 -0500 |
commit | 81d3ab2f86e79fc07895f8a288eb3366fc4bddcb (patch) | |
tree | 9a6ab59551562db8188be71b81cb40d8a17712da /discord/user.cpp | |
parent | 8a2f13795ddb13f6a6bb6d67ea409a628fe1d03b (diff) | |
download | abaddon-portaudio-81d3ab2f86e79fc07895f8a288eb3366fc4bddcb.tar.gz abaddon-portaudio-81d3ab2f86e79fc07895f8a288eb3366fc4bddcb.zip |
animated avatars on hover
Diffstat (limited to 'discord/user.cpp')
-rw-r--r-- | discord/user.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/discord/user.cpp b/discord/user.cpp index 01efe45..580f2ac 100644 --- a/discord/user.cpp +++ b/discord/user.cpp @@ -5,6 +5,10 @@ bool User::HasAvatar() const { return Avatar.size() > 0; } +bool User::HasAnimatedAvatar() const { + return Avatar.size() > 0 && Avatar[0] == 'a' && Avatar[1] == '_'; +} + std::string User::GetAvatarURL(std::string ext, std::string size) const { return "https://cdn.discordapp.com/avatars/" + std::to_string(ID) + "/" + Avatar + "." + ext + "?size=" + size; } |