Fork of Poseidon providing Bukkit #1060 to older Beta versions (b1.0-b1.7.3)
1package org.bukkit.entity;
2
3public interface Tameable {
4
5 /**
6 * Check if this is tamed
7 * <p>
8 * If something is tamed then a player can not tame it through normal methods, even if it does not belong to anyone in particular.
9 *
10 * @return true if this has been tamed
11 */
12 public boolean isTamed();
13
14 /**
15 * Sets if this has been tamed. Not necessary if the method setOwner has been used, as it tames automatically.
16 * <p>
17 * If something is tamed then a player can not tame it through normal methods, even if it does not belong to anyone in particular.
18 *
19 * @param tame true if tame
20 */
21 public void setTamed(boolean tame);
22
23 /**
24 * Gets the current owning AnimalTamer
25 *
26 * @return the owning AnimalTamer, or null if not owned
27 */
28 public AnimalTamer getOwner();
29
30 /**
31 * Set this to be owned by given AnimalTamer.
32 * If the owner is not null, this will be tamed and will have any current path it is following removed.
33 * If the owner is set to null, this will be untamed, and the current owner removed.
34 *
35 * @param tamer the AnimalTamer who should own this
36 */
37 public void setOwner(AnimalTamer tamer);
38
39}