Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: Cannot read properties of undefined (reading 'blocksByName') #3362

Closed
1 task done
Krstf01 opened this issue Apr 28, 2024 · 1 comment
Closed
1 task done
Labels
possible bug Stage1 just created by someone new to the project, we don't know yet if it deserves an implementation / a f

Comments

@Krstf01
Copy link

Krstf01 commented Apr 28, 2024

  • The FAQ doesn't contain a resolution to my issue

Versions

  • mineflayer: 4.20.1 (latest)
  • server: vanilla/spigot/paper 1.20.2 (Purpur)
  • node: 20.9.0

Detailed description of a problem

The bot is not even able to load.

What did you try yet?

I tried to use the pathfinder plugin, but it thrown this error: "TypeError: Cannot read properties of undefined (reading 'blocksByName')"

Your current code

const defaultMove = new Movements(bot)

Expected behavior

No errors at start or at any point.

Additional context

The other parts of my code worked without the line i highlited before.

@Krstf01 Krstf01 added possible bug Stage1 just created by someone new to the project, we don't know yet if it deserves an implementation / a f labels Apr 28, 2024
@extremeheat
Copy link
Member

You did not provide any code, so it's not possible to say more without looking at it. You are likely not waiting for the correct events. Copy the code from https://github.com/PrismarineJS/mineflayer/blob/master/examples/pathfinder/gps.js

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
possible bug Stage1 just created by someone new to the project, we don't know yet if it deserves an implementation / a f
Projects
None yet
Development

No branches or pull requests

2 participants