TamePrevention

public class TamePrevention implements Listener

Prevents players from taming EliteMob entities (e.g. WOLF-type bosses such as Snoopy).

Wolf-type elites are kept angry/targeted by KeepNeutralsAngry, but vanilla still allows a player to tame a Wolf with a bone during the brief window in which the wolf has no target (e.g. right after it kills its current target, before KeepNeutralsAngry's 1-second poll re-asserts a target). Taming fires EntityTameEvent, which nothing else cancels, so the boss would become a player pet.

This is safe for the Summon Wolf enchantment: summoned wolves are made owned via Wolf.setOwner(...), which does NOT fire EntityTameEvent. Only the player-feeds-a-bone tame path fires this event, which is exactly what we want to block.

Constructors

Link copied to clipboard
public void TamePrevention()

Functions

Link copied to clipboard
public void onTame(EntityTameEvent event)