diff --git a/bots/andy/survive.json b/bots/andy/survive.json index 159bc0b..4f34cc1 100644 --- a/bots/andy/survive.json +++ b/bots/andy/survive.json @@ -7,7 +7,7 @@ "torch", "stone_pickaxe", "stone_sword", - "leather_tunic", + "leather_chestplate", "iron_pickaxe", "iron_sword", "iron_helmet", diff --git a/src/agent/item_goal.js b/src/agent/item_goal.js index c130c07..e476f76 100644 --- a/src/agent/item_goal.js +++ b/src/agent/item_goal.js @@ -192,7 +192,6 @@ class ItemWrapper { this.methods.push(method); } - createChildren() { let recipes = mc.getItemCraftingRecipes(this.name); if (recipes) { @@ -302,7 +301,8 @@ export class ItemGoal { let next = goal.getNext(); // Prevent unnecessary attempts to obtain blocks that are not nearby - if (next.type === 'block' && !world.getNearbyBlockTypes(this.agent.bot).includes(next.source)) { + if (next.type === 'block' && !world.getNearbyBlockTypes(this.agent.bot).includes(next.source) || + next.type === 'hunt' && !world.getNearbyEntityTypes(this.agent.bot).includes(next.source)) { next.fails += 1; await new Promise((resolve) => setTimeout(resolve, 500)); this.agent.bot.emit('idle'); diff --git a/src/utils/mcdata.js b/src/utils/mcdata.js index 613d563..b026be2 100644 --- a/src/utils/mcdata.js +++ b/src/utils/mcdata.js @@ -172,7 +172,9 @@ export function getItemAnimalSource(itemName) { raw_mutton: 'sheep', raw_porkchop: 'pig', raw_rabbit: 'rabbit', - raw_salmon: 'salmon' + raw_salmon: 'salmon', + leather: 'cow', + wool: 'sheep' }[itemName]; }