Make it so mobs can't hit certain mobs? (friendly fire)

Started by BMAgamer on

Topic category: Help with Minecraft modding (Java Edition)

Joined Aug 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Make it so mobs can't hit certain mobs? (friendly fire)

So i'm making a mod, where there are these turret things, but sometimes they shoot each other. They are not hostile to each other, but if they are trying to shoot a mob, and another turret is right in front of it, the projectile will hit that turret. How can I make it so there is no friendly fire between these mobs.

Joined Dec 2023
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Maybe you can make them…
Sat, 03/23/2024 - 03:19

Maybe you can make them immune to the damage that their projectile deal in the behavior page.