How to use the mineflayer.vec3 function in mineflayer

To help you get started, we’ve selected a few mineflayer examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github vogonistic / mineflayer-voxel / server.js View on Github external
var mineflayer = require('mineflayer');
var vec3 = mineflayer.vec3;
var navigatePlugin = require('mineflayer-navigate')(mineflayer);
var voxelPlugin = require('./mineflayer-voxel.js')(mineflayer);
var bot = mineflayer.createBot();

navigatePlugin(bot);
voxelPlugin(bot, {port: 13333});

bot.navigate.on('pathPartFound', function (path) {
  bot.chat("Going " + path.length + " meters in the general direction for now.");
});
bot.navigate.on('pathFound', function (path) {
  bot.chat("I can get there in " + path.length + " moves.");
});
bot.navigate.on('cannotFind', function () {
  bot.chat("unable to find path");
});

mineflayer

create minecraft bots with a stable, high level API

MIT
Latest version published 9 days ago

Package Health Score

84 / 100
Full package analysis

Similar packages