Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/python-3.x/17.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python Pypresence不是';Don’不要改变我不和谐的表情_Python_Python 3.x_Discord - Fatal编程技术网

Python Pypresence不是';Don’不要改变我不和谐的表情

Python Pypresence不是';Don’不要改变我不和谐的表情,python,python-3.x,discord,Python,Python 3.x,Discord,因此,有一种称为discord rich presence的东西,它可以显示一些东西,比如某个人正在玩什么游戏,如果游戏支持它()。但是,当我使用一个名为。代码直接来自pypresence文档() 代码: from pypresence import Presence import time client_id = 'my_client_id' # I put my client id in here, but I removed it for pretty obvious reasons r

因此,有一种称为discord rich presence的东西,它可以显示一些东西,比如某个人正在玩什么游戏,如果游戏支持它()。但是,当我使用一个名为。代码直接来自pypresence文档()

代码:

from pypresence import Presence
import time

client_id = 'my_client_id' # I put my client id in here, but I removed it for pretty obvious reasons
rpc = Presence(client_id)
rpc.connect()

rpc.update(state='Rich Presence using pypresence!')

while True:
    time.sleep(15)