fixed door placement

This commit is contained in:
MaxRobinsonTheGreat 2024-06-22 16:04:49 -05:00
parent 7e71f12026
commit fb587d759a

View file

@ -532,7 +532,7 @@ export async function placeBlock(bot, blockType, x, y, z, placeOn='bottom', dont
let msg = '/setblock ' + Math.floor(x) + ' ' + Math.floor(y) + ' ' + Math.floor(z) + ' ' + blockType;
bot.chat(msg);
if (blockType.includes('door'))
bot.chat('/setblock ' + Math.floor(x) + ' ' + Math.floor(y+1) + ' ' + Math.floor(z) + ' ' + blockType + '[half=top]');
bot.chat('/setblock ' + Math.floor(x) + ' ' + Math.floor(y+1) + ' ' + Math.floor(z) + ' ' + blockType + '[half=upper]');
if (blockType.includes('bed'))
bot.chat('/setblock ' + Math.floor(x) + ' ' + Math.floor(y) + ' ' + Math.floor(z-1) + ' ' + blockType + '[part=head]');
log(bot, `Used /setblock to place ${blockType} at ${target_dest}.`);