UserFlags.js
1.38 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
'use strict';
const BitField = require('./BitField');
/**
* Data structure that makes it easy to interact with a {@link User#flags} bitfield.
* @extends {BitField}
*/
class UserFlags extends BitField {}
/**
* @name UserFlags
* @kind constructor
* @memberof UserFlags
* @param {BitFieldResolvable} [bits=0] Bit(s) to read from
*/
/**
* Bitfield of the packed bits
* @type {number}
* @name UserFlags#bitfield
*/
/**
* Numeric user flags. All available properties:
* * `DISCORD_EMPLOYEE`
* * `PARTNERED_SERVER_OWNER`
* * `HYPESQUAD_EVENTS`
* * `BUGHUNTER_LEVEL_1`
* * `HOUSE_BRAVERY`
* * `HOUSE_BRILLIANCE`
* * `HOUSE_BALANCE`
* * `EARLY_SUPPORTER`
* * `TEAM_USER`
* * `BUGHUNTER_LEVEL_2`
* * `VERIFIED_BOT`
* * `EARLY_VERIFIED_BOT_DEVELOPER`
* * `DISCORD_CERTIFIED_MODERATOR`
* * `BOT_HTTP_INTERACTIONS`
* @type {Object}
* @see {@link https://discord.com/developers/docs/resources/user#user-object-user-flags}
*/
UserFlags.FLAGS = {
DISCORD_EMPLOYEE: 1 << 0,
PARTNERED_SERVER_OWNER: 1 << 1,
HYPESQUAD_EVENTS: 1 << 2,
BUGHUNTER_LEVEL_1: 1 << 3,
HOUSE_BRAVERY: 1 << 6,
HOUSE_BRILLIANCE: 1 << 7,
HOUSE_BALANCE: 1 << 8,
EARLY_SUPPORTER: 1 << 9,
TEAM_USER: 1 << 10,
BUGHUNTER_LEVEL_2: 1 << 14,
VERIFIED_BOT: 1 << 16,
EARLY_VERIFIED_BOT_DEVELOPER: 1 << 17,
DISCORD_CERTIFIED_MODERATOR: 1 << 18,
BOT_HTTP_INTERACTIONS: 1 << 19,
};
module.exports = UserFlags;