Started by
ShAdOw112
on
Topic category: Help with Minecraft modding (Java Edition)
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?
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
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?
P.S. In the last 'Return' I used "True"
You need to put
if this entity has NBT tag "A" = true
Return ( not ( Get NBT tag "A" ) )
Do you mean this?
I did as you explained but it doesn't work(
Instead do "return (your condition)"
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.