How do you make entity1 not attack entity2 if entity2 has a certain potion effect?

Started by PeskySpyCrab on

Topic category: Help with modding (Java Edition)

Last seen on 18:39, 16. Jan 2021
Joined Jan 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How do you make entity1 not attack entity2 if entity2 has a certain potion effect?

I'm working on a xenomorph mod for fun but I don't want the xenos to attack entities that have a chestburster

Last seen on 20:00, 16. Apr 2024
Joined Dec 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
you should add a condition…
Thu, 02/11/2021 - 15:01

you should add a condition on the "attack entities of type" AI procedure block

Should be like this:

IF Has (Source Entity) active potion: (*your potion*)

    Do

    Return: false

Return: true

 

Hope this helps.