node-srcds-rcon
node-srcds-rcon copied to clipboard
TypeError: r.createConnection is not a function
Hi, I keep getting this error on connection, if I log the object there is no pproblem, maybe I'm missing some dependencies?
Here is my code:
let Rcon = require('srcds-rcon') let rcon = Rcon({ address: this.servers[index].ip, port: this.servers[index].port, password: this.servers[index].rcon_password }) console.log(rcon) rcon.connect().then(() => { console.log('connected') }).catch(console.error)