Topic category: Help with Minecraft modding (Java Edition)
Hello! I'm trying to recreate a similar attack condition to the Enderman and pumpkin helmet with my own custom entity. Basically, I want the entity to attack the player all the time, except if they're wearing a specific helmet.
I've began by adding an "additional start condition" to the entity AI player attack block and started working on the procedure. After various tests, I found out that the "Get entity (event/target entity) is targeting for attack" was not working, because even when I tried performing simple commands on it it didn't do anything.
I've tried using a method that I found here on the Mcreator forum, by adding an if block that checks if the entity being attacked is (sub)type of Living entity, but it still didn't work.
Does anyone know how to fix this?
NOTE: the entity is a Geckolib animated entity, probably not relevant at all, but might be worth mentioning.