Darthfett / helperbot

A mineflayer bot that helps you do things in minecraft.
57 stars 14 forks source link

windows.InventoryWindow is not a constructor #47

Open crashback-exe opened 4 years ago

crashback-exe commented 4 years ago

Gives me this error while executing node helpebot.js <serverip> ` bot.inventory = new windows.InventoryWindow(0, "Inventory", 44); ^

TypeError: windows.InventoryWindow is not a constructor`

TooterTutor commented 1 year ago

I get the same error when trying to run the following command: node helperbot.js localhost My_Friend --masters=TooterTutor

C:\Users\TooterTutor\Code\NodeJS\helper-bot\node_modules\mineflayer\lib\plugins\inventory.js:23
  bot.inventory = new windows.InventoryWindow(0, "Inventory", 44);
                  ^

TypeError: windows.InventoryWindow is not a constructor
    at Object.inject [as inventory] (C:\Users\TooterTutor\Code\NodeJS\helper-bot\node_modules\mineflayer\lib\plugins\inventory.js:23:19)
    at Bot.connect (C:\Users\TooterTutor\Code\NodeJS\helper-bot\node_modules\mineflayer\index.js:84:24)
    at Object.createBot (C:\Users\TooterTutor\Code\NodeJS\helper-bot\node_modules\mineflayer\index.js:57:7)
    at init (C:\Users\TooterTutor\Code\NodeJS\helper-bot\helperbot.js:116:18)
    at Object.<anonymous> (C:\Users\TooterTutor\Code\NodeJS\helper-bot\helperbot.js:111:5)
    at Module._compile (node:internal/modules/cjs/loader:1239:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1293:10)
    at Module.load (node:internal/modules/cjs/loader:1096:32)
    at Module._load (node:internal/modules/cjs/loader:935:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:84:12)

Node.js v19.4.0

Does anyone have an idea on why this won't run correctly? I've installed the necessary libraries to run, but it's always throwing out this error.

Also, on a side-note, I have already double and triple checked that my entire directory tree does not reveal any private information.