fix: numplayers not having a default value

This commit is contained in:
CosminPerRam 2024-01-17 00:23:29 +02:00
parent ec708d7219
commit b481425dbf
2 changed files with 2 additions and 0 deletions

View File

@ -30,6 +30,7 @@
* `deno run --allow-net bin/gamedig.js --type tf2 127.0.0.1`
* Added code examples.
* New stable field: `queryPort` - this number indicates what was the port that the query was done on, 0 indicates none if not applicable.
* Fixed `numplayers` not having a default value.
* New option: `stripColors` (defaults to `true`) for protocols that strips colors: unreal2, savage2, quake3, nadeo, gamespy2, doom3, armagetron.
* New option: `requestRulesRequired` (defaults to `false`) Valve games only. `requestRules` is always required to have a response or the query will timeout.
* New option: `requestPlayersRequired` (defaults to `false`) Valve games only. Querying players is always required to have a response or the query will timeout. Some [games](GAMES_LIST.md) may not provide a players response.

View File

@ -27,6 +27,7 @@ export class Results {
raw = {}
maxplayers = 0
numplayers = 0
players = new Players()
bots = new Players()