Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/mefrreex/queryplaceholders

Placeholders for displaying information about the server
https://github.com/mefrreex/queryplaceholders

nukkit nukkit-plugin nukkit-plugins pnx pnx-plugin

Last synced: about 1 month ago
JSON representation

Placeholders for displaying information about the server

Awesome Lists containing this project

README

        

## ๐ŸŽฎ How to use
You can use query placeholders in any plugin that has PlaceholderAPI support

**Player count placeholder**
In this placeholder you can specify multiple servers for online summation
Example: `%query_player_count%`

## ๐Ÿ–จ๏ธ Placeholders
`%query_player_count%` - Placeholder for display the number of players

`%query_max_players%` - Placeholder for display the maximum number of players

`%query_motd%` - Placeholder for display server motd

`%query_minecraft_version%` - Placeholder for display minecraft server version

## โš™๏ธ Plugin ัonfiguration
```yml
# Timeout time for query request
timeout: 2000 # In milliseconds

# Interval for updating query information
update: 1200 # In ticks

# Servers for query
servers:
zeqa: # Server name
address: "zeqa.net" # Server address
port: 19132 # Server port
nethergames:
address: "play.nethergames.org"
port: 19132
```

## ๐Ÿงฉ Addons
- [QueryPlaceholders-OnlineSummator](https://github.com/MEFRREEX/QueryPlaceholders-OnlineSummator)

## ๐Ÿ›  API
Getting QueryPlaceholders class
```java
QueryPlaceholders queryPlaceholders = QueryPlaceholders.getInstance();
```
Getting query of server
```java
BedrockQueryResponse query = queryPlaceholders.getQuery("server_name");
```
Getting ServerEntry class by name
```java
ServerEntry serverEntry = queryPlaceholders.getServer("server_name");
```
Getting BedrockQuery class
```java
BedrockQuery bedrockQuery = BedrockQueryFactory.getBedrockQuery();
```

## ๐Ÿ”Œ Maven
Repository
```xml


jitpack.io
https://jitpack.io

```
Dependency
```xml

com.github.MEFRREEX
QueryPlaceholders
1.2

```