mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-09-08 10:53:10 +00:00
Added hypesquad house functionality
This commit is contained in:
@ -29,7 +29,7 @@ from enum import Enum, IntEnum
|
||||
__all__ = ['ChannelType', 'MessageType', 'VoiceRegion', 'VerificationLevel',
|
||||
'ContentFilter', 'Status', 'DefaultAvatar', 'RelationshipType',
|
||||
'AuditLogAction', 'AuditLogActionCategory', 'UserFlags',
|
||||
'ActivityType', ]
|
||||
'ActivityType', 'HypeSquadHouse']
|
||||
|
||||
class ChannelType(Enum):
|
||||
text = 0
|
||||
@ -214,6 +214,9 @@ class UserFlags(Enum):
|
||||
staff = 1
|
||||
partner = 2
|
||||
hypesquad = 4
|
||||
hypesquad_bravery = 64
|
||||
hypesquad_brilliance = 128
|
||||
hypesquad_balance = 256
|
||||
|
||||
class ActivityType(IntEnum):
|
||||
unknown = -1
|
||||
@ -222,6 +225,10 @@ class ActivityType(IntEnum):
|
||||
listening = 2
|
||||
watching = 3
|
||||
|
||||
class HypeSquadHouse(Enum):
|
||||
bravery = 1
|
||||
brilliance = 2
|
||||
balance = 3
|
||||
|
||||
def try_enum(cls, val):
|
||||
"""A function that tries to turn the value into enum ``cls``.
|
||||
|
Reference in New Issue
Block a user