Class Context
Used to determine the current context in which the game is running.
Hierarchy
Index
Methods
- GetIsEmbedded
- GetIsHost
- GetIsP2P
Methods
Static GetIsEmbedded
GetIsEmbedded(): boolean
- Defined in TableRealms.ts:210
- This returns true when the context is embedded mode which means an embedded QR code was scanned and the game expects to be played inside the TableRealms app.
Returns boolean
Static GetIsHost
GetIsHost(): boolean
- Defined in TableRealms.ts:196
- The host is responsible for running the game code and can be thought of as the true state of the game. Clients merely observe the state of the host. This function returns true when the context is console mode, or P2P mode and this game is host.
Returns boolean
Static GetIsP2P
GetIsP2P(): boolean
- Defined in TableRealms.ts:203
- This returns true when the context is P2P mode which means a P2P QR code was scanned and the game expects to be played in multiplayer.
Returns boolean