mirror of
https://github.com/tribufu/node-gamedig
synced 2026-05-18 09:35:50 +00:00
Additional async rewrite
This commit is contained in:
parent
efe12a00aa
commit
29ce0b82d0
24 changed files with 654 additions and 470 deletions
|
|
@ -2,9 +2,13 @@ const Core = require('./core'),
|
|||
Varint = require('varint');
|
||||
|
||||
class Minecraft extends Core {
|
||||
constructor() {
|
||||
super();
|
||||
this.srvRecord = "_minecraft._tcp";
|
||||
}
|
||||
async run(state) {
|
||||
const portBuf = Buffer.alloc(2);
|
||||
portBuf.writeUInt16BE(this.options.port_query,0);
|
||||
portBuf.writeUInt16BE(this.options.port,0);
|
||||
|
||||
const addressBuf = Buffer.from(this.options.host,'utf8');
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue