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: 9 months ago
JSON representation
Placeholders for displaying information about the server
- Host: GitHub
- URL: https://github.com/mefrreex/queryplaceholders
- Owner: MEFRREEX
- License: gpl-3.0
- Created: 2023-11-08T04:11:58.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-12T18:50:02.000Z (almost 2 years ago)
- Last Synced: 2025-01-23T20:32:43.015Z (11 months ago)
- Topics: nukkit, nukkit-plugin, nukkit-plugins, pnx, pnx-plugin
- Language: Java
- Homepage: https://cloudburstmc.org/resources/queryplaceholders.960/
- Size: 44.9 KB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
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
```