v0.9.0
Added wavelink.WavelinkMixin
to be used in conjunction with a discord.py commands.Cog
. This class allows for the registration of the new wavelink listeners:
on_node_ready
on_track_start
on_track_end
on_track_stuck
on_track_exception
on_websocket_closed
All listeners must be decorated with the wavelink.WavelinkMixin.listener()
decorator.
All listeners must be in a wavelink.WavelinkMixin
class.
Listeners can be stacked.
Docs
Example
class Music(commands.Cog, wavelink.WavelinkMixin):
@wavelink.WavelinkMixin.listener()
async def on_node_ready(self, node):
print(f'Node {node.identifier} is ready!')