Started by
HerobrineXGami…
on
Topic category: Help with Minecraft modding (Java Edition)
hello so the mod im making, i want the mob in it to sprint after a player when it sees it/comes into range of it, how wowld i do this?
Topic category: Help with Minecraft modding (Java Edition)
hello so the mod im making, i want the mob in it to sprint after a player when it sees it/comes into range of it, how wowld i do this?
Im using Geckolib btw
What do you mean exactly by sprint?? I would just give the entity a speed effect, and maybe add another animation that would be overlayed over the walking. Although adding speed and just a complete other entity which has a different running animation to spawn and get it is simpler
i dont know if you still need help but i had the same problem and here is how to fix it (atleast in my case):
-in the mobs AI choose the AI templates "mob aggressive towards player" then in the "attack with speed factor" choose the speed factor of your entity (this will change its speed when it targets the player).
-if you want to change the entities walking animation when it targets the player then set its sprinting or aggressive animation (i dont know how you called it) as the aggressive animation in the animations tab instead of the sprinting animation and it should be done.
Now your entity will have a different speed and walking animation when it targets the player
(i would give some screen shots here but i don't know how to yet)