Comments (2)
The dynamic goals can emit the goal_reached event multiple time, that would not fit well with callbacks. The choice of using events was made to work with all types of goals.
It is easy enough to wrap the plugin to use callback in your code:
function gotoGoalCallback(goal, callback) {
bot.pathfinder.setGoal(goal)
bot.once('goal_reached', callback)
}
from mineflayer-pathfinder.
Forgive me, I was unaware that .once
could be used like that. That actually makes all of mineflayer a lot easier 😅
thank you
from mineflayer-pathfinder.
Related Issues (20)
- Bot randomly fails to place blocks when scaffolding HOT 4
- The bot does not enter the server (fabric)
- Bot can't go through doors HOT 2
- Bot never goes under layer 0 HOT 2
- Not working with Mineflayer 4.5.1? HOT 8
- Saying the the mcdata script in the Movements script is undefinded in the code this.blocksCantBreak.add(mcData.blocksByName.chest.id) HOT 3
- Typo HOT 8
- Bot tries to open fence gate that is already open HOT 4
- Bot thinks it can travel diagonally when blocked by other blocks HOT 4
- Bot trying to open the chest?¿? when he's walking on the chest HOT 3
- Bot goes to unexpected ways HOT 1
- (python) TypeError: Cannot read properties of null (reading 'blocksByName') HOT 2
- Stuck in dripstone HOT 1
- The code that is completely identical to the example that used to work normally does not work. HOT 8
- Bot Constantly Stuck or Halts with GoalFollow - HOT 2
- Failed to find path including bottom slabs
- GoalPlaceBlock ask HOT 1
- [Feature request] Creative/Flight navigation HOT 1
- goal_reached doesnt activate at all
- VulcanAC vs mineflayer pathfinding
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mineflayer-pathfinder.