Python 如何让discord机器人播放mp3文件

Python 如何让discord机器人播放mp3文件,python,discord.py,Python,Discord.py,我在互联网上搜索过,但我似乎只找到了关于如何让它播放声音的陈旧/过时的教程/指南 这是我的密码: import discord import time import asyncio import schedule from discord.ext import commands client = commands.Bot(command_prefix="-ff ") Client = discord.Client() @client.command() async def

我在互联网上搜索过,但我似乎只找到了关于如何让它播放声音的陈旧/过时的教程/指南

这是我的密码:

import discord
import time
import asyncio
import schedule

from discord.ext import commands

client = commands.Bot(command_prefix="-ff ")
Client = discord.Client()
@client.command()
async def hello(message):
    await message.channel.send('Hello!')

@client.command()
async def join(ctx):
    channel = ctx.author.voice.channel
    await channel.connect()
@client.command()
async def leave(ctx):
    await ctx.voice_client.disconnect()

@client.event
async def on_ready():
    print(f'{client.user} has connected to Discord!')

client.run('NoneOfYourBuissnes')