2017-11-22 9 views
2

私はdiscord.pyに付属のhelpコマンドを使用するときに、コマンドの説明を変更しようとしています。Discord botヘルプコマンド

しかし、私はちょうど実際にこの記述をどのように、どこに置くか分からないようです。

また、ヘルプリストで音楽のような異なるカテゴリを作成しようとしていますが、どこから始めたらいいのか分かりません。

私は、Pythonには本当に新しいですが、

私のコードはかなり長いですが、ここでその一部である

client = commands.Bot(command_prefix=commands.when_mentioned_or('?'), 
description='Help List', pm_help = True) 
client.add_cog(Music(client)) 

path = 'Blacklist.txt' 

bl = open(path, 'r') 

@client.event 
async def on_ready(): 
    print('---------------------------------------------------------------------------------------') 
    print('') 
    print('Logged in as '+client.user.name+' (ID:'+client.user.id+') | Connected to '+str(len(client.servers))+' servers | Connected to '+str(len(set(client.get_all_members())))+' users') 
    print('') 
    print('---------------------------------------------------------------------------------------') 
    print('') 
    print('Current Discord.py Version: {} | Current Python Version: {}'.format(discord.__version__, platform.python_version())) 
    print('') 
    print('---------------------------------------------------------------------------------------') 

@client.command() 
async def ping(*args): 
    await client.say(":ping_pong: Pong!") 

前に、私は他のプログラミング言語を扱ってきたのは、私が追加したいとしましょうpingコマンドの説明。どこで私はそれをどうやってやりますか?

答えて

1
@client.command(description="Some ping command") #here 
async def ping(*args): 
    await client.say(":ping_pong: Pong!") 
関連する問題