mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-05-16 02:39:01 +00:00
Add Permissions.stream
Add stream to Permissions classmethods
This commit is contained in:
parent
497894e756
commit
84e86ff666
@ -133,7 +133,7 @@ class Permissions:
|
|||||||
def all(cls):
|
def all(cls):
|
||||||
"""A factory method that creates a :class:`Permissions` with all
|
"""A factory method that creates a :class:`Permissions` with all
|
||||||
permissions set to True."""
|
permissions set to True."""
|
||||||
return cls(0b01111111111101111111110111111111)
|
return cls(0b01111111111101111111111111111111)
|
||||||
|
|
||||||
@classmethod
|
@classmethod
|
||||||
def all_channel(cls):
|
def all_channel(cls):
|
||||||
@ -166,7 +166,7 @@ class Permissions:
|
|||||||
def voice(cls):
|
def voice(cls):
|
||||||
"""A factory method that creates a :class:`Permissions` with all
|
"""A factory method that creates a :class:`Permissions` with all
|
||||||
"Voice" permissions from the official Discord UI set to True."""
|
"Voice" permissions from the official Discord UI set to True."""
|
||||||
return cls(0b00000011111100000000000100000000)
|
return cls(0b00000011111100000000001100000000)
|
||||||
|
|
||||||
def update(self, **kwargs):
|
def update(self, **kwargs):
|
||||||
r"""Bulk updates this permission object.
|
r"""Bulk updates this permission object.
|
||||||
@ -301,7 +301,14 @@ class Permissions:
|
|||||||
def priority_speaker(self, value):
|
def priority_speaker(self, value):
|
||||||
self._set(8, value)
|
self._set(8, value)
|
||||||
|
|
||||||
# 1 unused
|
@property
|
||||||
|
def stream(self):
|
||||||
|
"""Returns ``True`` if a user can stream in a voice channel."""
|
||||||
|
return self._bit(9)
|
||||||
|
|
||||||
|
@stream.setter
|
||||||
|
def stream(self, value):
|
||||||
|
self._set(9, value)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def read_messages(self):
|
def read_messages(self):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user