Compare commits
No commits in common. "eae4e958036a94d3c0d32660221570bbabace9e0" and "a7ccb08d43a5819165dec35d4af34d4ad6252526" have entirely different histories.
eae4e95803
...
a7ccb08d43
|
@ -99,7 +99,7 @@ bot.once("spawn", () => {
|
||||||
inventory: require('./plugins/inventory'),
|
inventory: require('./plugins/inventory'),
|
||||||
eater: require('./plugins/eater'),
|
eater: require('./plugins/eater'),
|
||||||
finder: require('./plugins/finder'),
|
finder: require('./plugins/finder'),
|
||||||
// miner: require('./plugins/miner.js'),
|
miner: require('./plugins/miner'),
|
||||||
// statemachine: require('./plugins/statemachine'),
|
// statemachine: require('./plugins/statemachine'),
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,18 +16,12 @@ let movements = []
|
||||||
|
|
||||||
|
|
||||||
function initMoves(bot = bot, mcData = require('minecraft-data')(bot.version)) {
|
function initMoves(bot = bot, mcData = require('minecraft-data')(bot.version)) {
|
||||||
console.info(movements)
|
|
||||||
if (movements.length > 0) {
|
|
||||||
bot.pathfinder.setMovements(defaultMove)
|
|
||||||
return console.warn("movements already initialized!")
|
|
||||||
}
|
|
||||||
let defaultMove = new Movements(bot, mcData)
|
let defaultMove = new Movements(bot, mcData)
|
||||||
defaultMove.canDig = false
|
defaultMove.canDig = false
|
||||||
defaultMove.scafoldingBlocks.push(mcData.blocksByName.slime_block.id)
|
defaultMove.scafoldingBlocks.push(mcData.blocksByName.slime_block.id)
|
||||||
// defaultMove.blocksCantBreak.add(mcData.blocksByName.glass.id)
|
// defaultMove.blocksCantBreak.add(mcData.blocksByName.glass.id)
|
||||||
// defaultMove.blocksToAvoid.add(mcData.blocksByName.magma.id)
|
// defaultMove.blocksToAvoid.add(mcData.blocksByName.magma.id)
|
||||||
movements.push(defaultMove)
|
movements.defaultMove = defaultMove
|
||||||
movements.defaultMove = movements[0]
|
|
||||||
|
|
||||||
bot.pathfinder.setMovements(defaultMove)
|
bot.pathfinder.setMovements(defaultMove)
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,7 +27,7 @@ function sleep(quiet) {
|
||||||
if (bed && bedstatus == "") {
|
if (bed && bedstatus == "") {
|
||||||
bot.lookAt(bed.position)
|
bot.lookAt(bed.position)
|
||||||
bot.waitForChunksToLoad(() => {
|
bot.waitForChunksToLoad(() => {
|
||||||
cfg.plugins.mover.moveNear(bed.position)
|
cfg.plugins.moveNear(bed.position)
|
||||||
bot.sleep(bed, (err) => {
|
bot.sleep(bed, (err) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
!quiet && bot.chat(`can't sleep: ${err.message}`)
|
!quiet && bot.chat(`can't sleep: ${err.message}`)
|
||||||
|
|
|
@ -42,6 +42,7 @@
|
||||||
"prismarine-block": "^1",
|
"prismarine-block": "^1",
|
||||||
"prismarine-chat": "^1",
|
"prismarine-chat": "^1",
|
||||||
"prismarine-entity": "^1.1.0",
|
"prismarine-entity": "^1.1.0",
|
||||||
|
"prismarine-gameplay": "github:TheDudeFromCI/prismarine-gameplay#crafting",
|
||||||
"prismarine-item": "^1.5.0",
|
"prismarine-item": "^1.5.0",
|
||||||
"prismarine-nbt": "^1.3",
|
"prismarine-nbt": "^1.3",
|
||||||
"prismarine-recipe": "^1",
|
"prismarine-recipe": "^1",
|
||||||
|
|
Loading…
Reference in New Issue
Block a user