• Guides
  • Api Documentation
  • Discord.Addons.MpGame
  • MpGameService<TGame, TPlayer>.MpGameData
Show / Hide Table of Contents
  • Discord.Addons.MpGame
    • CurrentlyPlaying
    • GameBase<TPlayer>
    • IMpGameData
    • MpGameModuleBase<TService, TGame, TPlayer>
    • MpGameService<TGame, TPlayer>
    • MpGameService<TGame, TPlayer>.MpGameData
    • Player
  • Discord.Addons.MpGame.Collections
    • CircularLinkedList<T>
    • Hand<T>
    • IWrapper<T>
    • Node<T>
    • Pile<T>
    • WrappingPile<T, TWrapper>
  • Discord.Addons.Preconditions
    • Measure
    • MinimumOnlineUsersAttribute
    • RatelimitAttribute
    • RatelimitFlags
    • RequireLowerHierarchyAttribute
    • RequireRoleAttribute
    • UserMustBeInVoiceAttribute

Class MpGameService<TGame, TPlayer>.MpGameData

Contains metadata about a game given a command context.

Inheritance
Object
MpGameService<TGame, TPlayer>.MpGameData
Implements
IMpGameData
Namespace: Discord.Addons.MpGame
Assembly: Discord.Addons.MpGame.dll
Syntax
public sealed class MpGameData : IMpGameData

Properties

| Improve this Doc View Source

Game

The instance of the game being played (if active).

Declaration
public TGame Game { get; }
Property Value
Type Description
TGame
| Improve this Doc View Source

GameInProgress

Determines if a game in the current channel is in progress or not.

Declaration
public CurrentlyPlaying GameInProgress { get; }
Property Value
Type Description
CurrentlyPlaying
| Improve this Doc View Source

JoinedUsers

Declaration
public IReadOnlyCollection<IUser> JoinedUsers { get; }
Property Value
Type Description
IReadOnlyCollection<IUser>
Remarks
note

This is an immutable snapshot, it is not updated until the next time an instance of this class is created.

| Improve this Doc View Source

OpenToJoin

Determines if a game in the current channel is open to join or not.

Declaration
public bool OpenToJoin { get; }
Property Value
Type Description
Boolean
| Improve this Doc View Source

Player

The player object that wraps the user executing this command (if a game is active AND the user is a player in that game).

Declaration
public TPlayer Player { get; }
Property Value
Type Description
TPlayer

Explicit Interface Implementations

| Improve this Doc View Source

IMpGameData.GameChannelId

Id of the public-facing channel of this game.

Declaration
ulong? IMpGameData.GameChannelId { get; }
Returns
Type Description
Nullable<UInt64>
| Improve this Doc View Source

IMpGameData.JoinedUsers

The list of users ready to play.

Declaration
IReadOnlyCollection<ulong> IMpGameData.JoinedUsers { get; }
Returns
Type Description
IReadOnlyCollection<UInt64>
| Improve this Doc View Source

IMpGameData.PlayerUserId

Id of the player invoking this command.

Declaration
ulong? IMpGameData.PlayerUserId { get; }
Returns
Type Description
Nullable<UInt64>

Implements

IMpGameData
  • Improve this Doc
  • View Source
Back to top Generated by DocFX