mineflayer-quarry
Quarry operations for Mineflayer
Last updated a year ago by safazi .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install mineflayer-quarry 
SYNC missed versions from official npm registry.

mineflayer-quarry

NPM version Quarry operation for mineflayer

This plugin requires mineflayer-navigate.

Usage

Mineflayer = require 'mineflayer'
Quarry = (require 'mineflayer-quarry') Mineflayer

Bot = Mineflayer.createBot
	username: "Digger"

# Inject Quarry
Quarry Bot

Bot.on 'chat', (User, Msg) ->
	return if User == Bot.username
	if Msg == 'shaft'
		# Dig a 5x5 centered around the player
		Player = Bot.players[User]
		if Player.entity
			Corners = Bot.quarry.getCorners Player.entity.position, 5
			Bot.chat 'Starting quarry'
			Result = Bot.quarry.shaft
				Corners: Corners
			if Result.status != 'ok'
				Bot.chat 'Error: ' + Result.message

		else
			Bot.chat 'Error: You\'re too far away!'

Bot.once 'spawn', -> Bot.chat 'Please ensure I have a pickaxe to mine with'

Current Tags

  • 0.0.1                                ...           latest (a year ago)

1 Versions

  • 0.0.1                                ...           a year ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (3)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |