buddy

node MVC discord bot
Log | Files | Refs | README

ActivityFlags.js (798B)


      1 'use strict';
      2 
      3 const BitField = require('./BitField');
      4 
      5 /**
      6  * Data structure that makes it easy to interact with an {@link Activity#flags} bitfield.
      7  * @extends {BitField}
      8  */
      9 class ActivityFlags extends BitField {}
     10 
     11 /**
     12  * @name ActivityFlags
     13  * @kind constructor
     14  * @memberof ActivityFlags
     15  * @param {BitFieldResolvable} [bits=0] Bit(s) to read from
     16  */
     17 
     18 /**
     19  * Numeric activity flags. All available properties:
     20  * * `INSTANCE`
     21  * * `JOIN`
     22  * * `SPECTATE`
     23  * * `JOIN_REQUEST`
     24  * * `SYNC`
     25  * * `PLAY`
     26  * @type {Object}
     27  * @see {@link https://discordapp.com/developers/docs/topics/gateway#activity-object-activity-flags}
     28  */
     29 ActivityFlags.FLAGS = {
     30   INSTANCE: 1 << 0,
     31   JOIN: 1 << 1,
     32   SPECTATE: 1 << 2,
     33   JOIN_REQUEST: 1 << 3,
     34   SYNC: 1 << 4,
     35   PLAY: 1 << 5,
     36 };
     37 
     38 module.exports = ActivityFlags;