How can I make a working aggressive mob?

Started by icantlogin on Wed, 10/27/2021 - 19:00

Topic category: Help with modding (Java Edition)

Last seen on 19:11, 3. Nov 2021
Joined Oct 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
How can I make a working aggressive mob?
Wed, 10/27/2021 - 19:00

I simply want an aggressive mob that attacks friendly creatures. But when I use "attack entities of type 'Creature entity" it also attacks its own species even if it's a mob. How can I fix this so it attacks every friendly creature except itself?

Last seen on 09:30, 5. Dec 2021
Joined Mar 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
You can't unless you select…
Thu, 10/28/2021 - 05:55

You can't unless you select in AI each single creature he must attack and not only "creature"

That's the best solution otherwise you can use trigger entity attacked and if same type then cancel trigger but in this case they will stand still looking at each other

Last seen on 19:11, 3. Nov 2021
Joined Oct 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
I used animal entities…
Thu, 10/28/2021 - 08:10

I used animal entities instead and now it works actually. 

Last seen on 09:30, 5. Dec 2021
Joined Mar 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • Tracker tickets:
  • MCreator plugins:
  • Comments:
Now it attacks only animals…
Thu, 10/28/2021 - 10:06

Now it attacks only animals as per what you say....so if you have a pacific creature which is not animal it will not attack it