Game
Retrieve the current number of online players in your game server, compatible with more than 320 games.
The Game counter queries your game server and shows how many players are online right now. It uses node-gamedig, so Minecraft, Rust, ARK and many other games work. The full list is the node-gamedig game list.
Availability: every bot. It needs no privileged intents. A self-hosted bot must be able to reach the game server's query port outbound.

Options
Game
Which game the server runs, and therefore which query protocol the bot speaks.
Required. Type in the box to search the list. This field only takes an entry from the list or a counter, never a game ID typed by hand.
Address
The host of the game server: an IP such as 1.2.3.4 or a domain such as mc.example.com.
Required. Do not add the port here, it has its own field.
Port (or query port)
The port the query is sent to.
Required. Picking a game fills in a default port, but only while the field is still empty. Only numbers are accepted.
Display label
A custom name for this counter's chip in the editor. It does not change the channel output.
Optional. Open it with the Edit display label button.
All three query options accept another counter instead of a typed value. The gear button on the nested counter's row tells you what it has to return. See Nested counters.
Query port or game port
This is the most common reason a Game counter does not work. Many games answer status queries on a different port from the one players connect to, and this field wants the query port. Minecraft uses the same port for both, 25565. ARK does not.
Picking a game fills in that game's query port if node-gamedig knows one, and its connect port otherwise, so check the number. If you change the game later, the old port stays and you have to correct it yourself. When you are not sure, look up the query port in your host's control panel or in your server configuration.
What it returns
The number of players online, and nothing else. Maximum players, the map name, the server name and the player list are not available from this counter.
There is no fallback option. If the server is offline, the address is wrong, the query port is closed or the game type does not match, the counter fails and the bot renames the channel (or rewrites the topic) to ERROR! until the next successful update. The real message is shown on the counter in the dashboard. See Troubleshooting.
Formatting
The result is a number, so the Format settings block applies: Use compact notation, Override default locale and Override default digits. Without compact notation the number is printed plain, with no thousands separator. Custom digits only reach text and announcement channel topics; voice and category channel names never show them. See Formatting counters.
Refresh and caching
Nothing is cached. Every channel update sends a fresh query: every 10 minutes on the public bot, every 5 minutes on the legacy premium bot, custom bots and self-hosted bots. See How counters update.
A server that does not answer makes the counter time out.
Examples
Game
Minecraft (ID minecraft)
Address
mc.example.com
Port (or query port)
25565
Written in the template as Online: followed by the counter, the channel reads Online: plus the player count.

Online: , and the Game panel it opensGame
Ark: Survival Evolved (ID ase)
Address
ark.example.com
Port (or query port)
27015
7777 is the port players connect to. Use 27015, the query port, which the editor fills in for you when you pick this game.

Add one Game counter per server inside a Math counter whose Operation type is Addition to show the players across your whole network in one channel, or wrap a counter in Concat to build a sentence around it.
For a server type node-gamedig does not support but that has a public status API, use the HTTP counter instead.
Errors
The bot checks the address first, then the port, then the game, so a counter with nothing filled in reports the address message first.
The game counter requires a server address.
Fill Address with the host, without the port.
The game counter requires a server port.
Fill Port (or query port).
A game ID must be provided for the game counter.
Pick a game in Game.
The evaluation took too long and timed out.
Check the query port and the address, and make sure the server is still running.
The result for the channel name is less than 2 characters long.
Put some text around the counter.
Any other failure comes from the query itself: the server is offline, the query port is closed or blocked by a firewall, or the game type does not match what the server runs. Check the port first, then the address. More in Troubleshooting.
Last updated