feat: add port and givenPortOnly flags to the simple example

This commit is contained in:
CosminPerRam 2024-01-22 23:09:55 +02:00
parent b1912505f9
commit 86d9590d11
1 changed files with 3 additions and 1 deletions

View File

@ -3,7 +3,9 @@ import { GameDig } from '../lib/index.js'
GameDig.query({
type: 'minecraft',
host: 'mc.hypixel.net'
host: 'mc.hypixel.net',
port: 25565, // let us explicitly specify the port
givenPortOnly: true // gamedig will try to attempt multiple ports to ensure success, disable that with this option
}).then((state) => {
console.log(state)
}).catch((error) => {