mirror of
https://github.com/ChomeNS/chomens-bot-mc.git
synced 2024-11-14 02:44:53 -05:00
core fix(?) + remove / from fill command
This commit is contained in:
parent
3199b5f696
commit
37b6aa341b
1 changed files with 3 additions and 1 deletions
|
@ -7,6 +7,8 @@ const relativePosition = new Vec3(0, 0, 0)
|
|||
function inject (bot, dcclient, config) {
|
||||
const mcData = require('minecraft-data')(bot.version)
|
||||
const core = {
|
||||
start: new Vec3(null, null, null),
|
||||
end: new Vec3(null, null, null),
|
||||
isCore (position) {
|
||||
return position.x >= core.start.x && position.x <= core.end.x && position.y >= core.start.y && position.y <= core.end.y && position.z >= core.start.z && position.z <= core.end.z
|
||||
},
|
||||
|
@ -58,7 +60,7 @@ function inject (bot, dcclient, config) {
|
|||
|
||||
function placeCore () {
|
||||
try {
|
||||
const fillCommand = `/minecraft:fill ${core.start.x} ${core.start.y} ${core.start.z} ${core.end.x} ${core.end.y} ${core.end.z} command_block{CustomName:'${JSON.stringify(config.core.customName)}'}`
|
||||
const fillCommand = `minecraft:fill ${core.start.x} ${core.start.y} ${core.start.z} ${core.end.x} ${core.end.y} ${core.end.z} command_block{CustomName:'${JSON.stringify(config.core.customName)}'}`
|
||||
const location = { x: Math.floor(bot.position.x), y: Math.floor(bot.position.y) - 1, z: Math.floor(bot.position.z) }
|
||||
|
||||
bot.write('set_creative_slot', {
|
||||
|
|
Loading…
Reference in a new issue