#ProxyAgent is not a constructor

1 messages · Page 1 of 1 (latest)

tropic aurora
#

I'm getting this error, and I don't know what to do, I'll provide that snippet of code in my next message.

#

ProxyAgent is not a constructor

#
const bots = [];
for (const account of accounts) {
  setTimeout( async () => {
    await sleep(3000)
    const bot = mineflayer.createBot({
      host: 'hypixel.net',
      port: 25565,
      version: "1.8.9",
      username: account.username,
      password: account.password,
      auth: 'microsoft',
      agent: new ProxyAgent(account.proxy),
    });
    bots.push(bot);