mirror of
https://github.com/kolbytn/mindcraft.git
synced 2025-06-06 01:05:56 +02:00
change cowardice range
This commit is contained in:
parent
51f401e62d
commit
0f18dd9f12
1 changed files with 2 additions and 2 deletions
|
@ -70,11 +70,11 @@ const modes = [
|
|||
on: true,
|
||||
active: false,
|
||||
update: async function (agent) {
|
||||
const enemy = world.getNearestEntityWhere(agent.bot, entity => mc.isHostile(entity), 8);
|
||||
const enemy = world.getNearestEntityWhere(agent.bot, entity => mc.isHostile(entity), 16);
|
||||
if (enemy && await world.isClearPath(agent.bot, enemy)) {
|
||||
agent.bot.chat(`Aaa! A ${enemy.name}!`);
|
||||
execute(this, agent, async () => {
|
||||
await skills.avoidEnemies(agent.bot, 16);
|
||||
await skills.avoidEnemies(agent.bot, 24);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue