Solved Making zombies *not* attack?

Discussion in 'Plugin Development' started by thok13, Feb 18, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    thok13

    So for specific zombies I'm spawning I want them not to attack. This is because they are supposed to be like pets. One easy way I could do this would be to make their seeing distance 0, but I get the feeling this is not a good approach. Any help?
     
  2. This cannot be done for certain zombies. If you somehow manage to get a constant amount of entities, you could do it by entityNumber, however that is impossible. You could do it for the whole zombie race, but I am not sure how.Perhaps you need a servermod for this.
     
  3. Offline

    mastermustard

    you wouldn't need a server mod to do it to all zombies.

    Use EntityDamageByEntityEvent then check if the entity being attacked is being attacked by a zombie then cancel it
    http://jd.bukkit.org/rb/doxygen/df/...t_1_1entity_1_1EntityDamageByEntityEvent.html
     
  4. Offline

    chasechocolate

    thok13 and MrBluebear3 like this.
Thread Status:
Not open for further replies.

Share This Page