I have looked through the documentation and have not been able to find a way to reset permissions or remove a users permissions for a voice channel. using this code:
member_permissions = channel.overwrites_for(member)
member_permissions.manage_channels = False
member_permissions.move_members = False
member_permissions.mute_members = False
await channel.set_permissions(member, overwrite=member_permissions)
this code sets all permissions to False, but I want it to remove the users permissions because when you set it to false it still shows in the voice channel permissions.
basically how to use this button in discord.py:
From the docs:
If the
overwrite
parameter isNone
, then the permission overwrites are deleted.
So simply:
await channel.set_permissions(member, overwrite=None)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.