API Display Modes - Senither/Lilypad-Minigame-Hook GitHub Wiki
Display Modes
Display modes are used to determine if the server should be displayed in lobby servers or not, for example, some minigames might not want people joining if the server is full or if the game has already started.
Servers who haven't sent any messages to a lobby server in the last three seconds will be assumed offline by the Minigame Lobby plugin, and automatically hidden from any game boards.
How to
Set display status
Setting the display status can be done by using the setDisplay
method, setting the status to true
will display the server on gameboards as long as the server is online and the status is not changed again, setting the display status to false
will hide the server from all gameboards.
Type | Name | Description |
---|---|---|
Boolean | value | The value that should be set as the display status. |
Example Usage
LilypadMinigameAPI.setDisplay(true); // Shows the server on gameboards.
LilypadMinigameAPI.setDisplay(false); // Hides the server on gameboards.
Get display status
The display status can be accessed via the isDisplay
method which will return true
if the server is being displayed on game boards, and false
if the server is being hidden from game boards.
Example Usage
LilypadMinigameAPI.isDisplay(); // Returns true or false, depending on the display mode.