fix: readme example and add more options to the simple example

This commit is contained in:
CosminPerRam 2024-01-22 23:17:07 +02:00
parent e89cb125b2
commit 16e9454beb
2 changed files with 6 additions and 4 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, // lets us explicitly specify the query port of this server
givenPortOnly: true // the library will attempt multiple ports in order to ensure success, to avoid this pass this option
}).then((state) => {
console.log(state)
}).catch((error) => {