How to make a mob avoid a block?

Started by TheCatalystGaming on

Topic category: Advanced modding

Last seen on 19:36, 13. Nov 2022
Joined Nov 2015
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to make a mob avoid a block?

As the title says, is there a way to make a mob avoid/run away from a block?

Last seen on 22:39, 22. Aug 2022
Joined Jan 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
when entity moves check if…
Fri, 05/14/2021 - 23:13

when entity moves check if touching or distance to nearest block representing block of [x] type if the distance is closer than [int] do something

This is the way I'd do it but I don't know the procedures for it. 

Check this forum page.