aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorleovoel <[email protected]>2016-11-14 22:57:21 -0200
committerleovoel <[email protected]>2016-11-14 22:57:21 -0200
commitcb370a0ca0dd29eb6717b81fae80a7e9c72f9411 (patch)
tree2489fed641524933dcaac2f5f4cc15ef62c96683
parentSupport message editing with rich embeds. (diff)
downloaddiscord.py-cb370a0ca0dd29eb6717b81fae80a7e9c72f9411.tar.xz
discord.py-cb370a0ca0dd29eb6717b81fae80a7e9c72f9411.zip
Add FAQ entry about reactions
-rw-r--r--docs/faq.rst17
1 files changed, 17 insertions, 0 deletions
diff --git a/docs/faq.rst b/docs/faq.rst
index aff1a61f..b3e5988b 100644
--- a/docs/faq.rst
+++ b/docs/faq.rst
@@ -130,6 +130,23 @@ The second is by passing the file name directly: ::
await client.send_file(channel, 'my_image.png')
+How can I add a reaction to a message?
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+
+You use the :meth:`Client.add_reaction` method.
+
+If you want to use unicode emoji, you must pass a valid unicode code point in a string. In your code, you can write this in a few different ways:
+
+- ``'👍'``
+- ``'\U0001F44D'``
+- ``'\N{THUMBS UP SIGN}'``
+
+In case you want to use emoji that come from a message, you already get their code points in the content without needing to do anything special.
+You **cannot** send ``':thumbsup:'`` style shorthands.
+
+For custom emoji, you should pass an instance of :class:`discord.Emoji`. You can also pass a ``'name:id'`` string, but if you can use said emoji,
+you should be able to use :meth:`Client.get_all_emojis`/:attr:`Server.emojis` to find the one you're looking for.
+
How do I pass a coroutine to the player's "after" function?
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~