How to use mob's conditions?

Started by ShAdOw112 on

Topic category: Help with modding (Java Edition)

Last seen on 12:01, 16. Feb 2023
Joined Mar 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
How to use mob's conditions?

Hi! I created a custom mob and gave him AI. It should attack everyone except for entities whose have a tag. Is it possible to make it? If so, how to do this in mob's conditions?

Last seen on 05:42, 27. Mar 2022
Joined May 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Well I don't know how to…
Mon, 11/30/2020 - 05:29

Well I don't know how to explain this but...

First do you need to create the tag entity and put in that all the entities do you want, then create the procedure:

if (put the entity tag)  =  true

      return false

return true

In procedures with logic type you need to put "return true" under the condition. Well then go to your entity and make for the AI that can attack living entities or mobs (mobs are agressive entities), then in conditions of that put your procedure in the first condition and it's done. If you can't make tags entities you can put in the condition subtypes of the entities you want, put all of them like: [(subtype 1) or (subtype 2) ] = true

Last seen on 12:01, 16. Feb 2023
Joined Mar 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I did it like this: if this…
Mon, 11/30/2020 - 19:25

I did it like this:
if this entity has NBT tag "A"
do: Return: False
Return: False
But it still keeps beating me and I tried to change its target to Mob, Creature and AmbientCreature but it didn't even notice me (I didn't turn on the condition. What should I do?

Last seen on 12:01, 16. Feb 2023
Joined Mar 2017
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
P.S. In the last 'Return' I…
Mon, 11/30/2020 - 19:26

P.S. In the last 'Return' I used "True"

Last seen on 05:42, 27. Mar 2022
Joined May 2020
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
You need to put  if this…
Mon, 11/30/2020 - 19:53

You need to put 

if this entity has NBT tag "A"  = true

 

Last seen on 15:38, 1. Dec 2022
Joined Oct 2019
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Return ( not ( Get NBT tag …
Sat, 02/20/2021 - 20:06

Return ( not ( Get NBT tag "A" ) )

Do you mean this?

Last seen on 17:09, 11. Mar 2024
Joined Mar 2018
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
I did as you explained but…
Thu, 08/18/2022 - 19:40

I did as you explained but it doesn't work(TestProc

Last seen on 13:56, 19. Dec 2022
Joined Feb 2022
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Instead do "return (your…
Thu, 08/18/2022 - 20:58

Instead do "return (your condition)"

Last seen on 22:27, 16. Jan 2024
Joined Dec 2021
Points:

User statistics:

  • Modifications:
  • Forum topics:
  • Wiki pages:
  • MCreator plugins:
  • Comments:
Use Get entity [Event entity…
Tue, 07/25/2023 - 17:20

Use Get entity [Event entity] is targeting for attack Which is in the entity data tab.

Put it where event entity is in your procedure

Hope this helps.