diff options
| author | MusicOnline <[email protected]> | 2018-10-05 18:19:18 +0800 |
|---|---|---|
| committer | MusicOnline <[email protected]> | 2018-10-05 18:19:18 +0800 |
| commit | 5ec3875ec80ba601b4295a565b93b2af1f6dd0b6 (patch) | |
| tree | d923cb09d586322353e49e1e20e1fbe4754ec2e7 /docs/faq.rst | |
| parent | Fix up Guild.create_custom_emoji docstring. (diff) | |
| download | discord.py-5ec3875ec80ba601b4295a565b93b2af1f6dd0b6.tar.xz discord.py-5ec3875ec80ba601b4295a565b93b2af1f6dd0b6.zip | |
Update set "Playing" status FAQ
Diffstat (limited to 'docs/faq.rst')
| -rw-r--r-- | docs/faq.rst | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/docs/faq.rst b/docs/faq.rst index 506a4d43..aab42fbd 100644 --- a/docs/faq.rst +++ b/docs/faq.rst @@ -74,11 +74,18 @@ General questions regarding library usage belong here. How do I set the "Playing" status? ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -There is a method for this under :class:`Client` called :meth:`Client.change_presence`. The relevant aspect of this is its -``game`` keyword argument which takes in a :class:`Game` object. Putting both of these pieces of info together, you get the -following: :: +There is a method for this under :class:`Client` called :meth:`Client.change_presence`. +The relevant aspect of this is its ``activity`` keyword argument which takes in an :class:`Activity` object. - await client.change_presence(game=discord.Game(name='my game')) +The status type (playing, listening, streaming, watching) can be set using the :class:`ActivityType` enum. +For memory optimisation purposes, some activities are offered in slimmed down versions: + +- :class:`Game` +- :class:`Streaming` + +Putting both of these pieces of info together, you get the following: :: + + await client.change_presence(activity=discord.Game(name='my game')) How do I send a message to a specific channel? ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |