From 7ab47c223bc75a5a8c96d164ebf3d623ac6300da Mon Sep 17 00:00:00 2001 From: DerpyChap Date: Sun, 17 Feb 2019 17:10:08 +0000 Subject: [PATCH] Add self_video property to VoiceState --- discord/member.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/discord/member.py b/discord/member.py index c5aa897af..1c0b19df7 100644 --- a/discord/member.py +++ b/discord/member.py @@ -49,6 +49,8 @@ class VoiceState: Indicates if the user is currently muted by their own accord. self_deaf: :class:`bool` Indicates if the user is currently deafened by their own accord. + self_video: :class:`bool` + Indicates if the user is currently broadcasting video. afk: :class:`bool` Indicates if the user is currently in the AFK channel in the guild. channel: :class:`VoiceChannel` @@ -57,7 +59,7 @@ class VoiceState: """ __slots__ = ('session_id', 'deaf', 'mute', 'self_mute', - 'self_deaf', 'afk', 'channel') + 'self_video', 'self_deaf', 'afk', 'channel') def __init__(self, *, data, channel=None): self.session_id = data.get('session_id') @@ -66,13 +68,14 @@ class VoiceState: def _update(self, data, channel): self.self_mute = data.get('self_mute', False) self.self_deaf = data.get('self_deaf', False) + self.self_video = data.get('self_video', False) self.afk = data.get('suppress', False) self.mute = data.get('mute', False) self.deaf = data.get('deaf', False) self.channel = channel def __repr__(self): - return ''.format(self) + return ''.format(self) def flatten_user(cls): for attr, value in itertools.chain(BaseUser.__dict__.items(), User.__dict__.items()):