summaryrefslogtreecommitdiffstats
path: root/src/main/java/org/bukkit/block
diff options
context:
space:
mode:
authorTravis Watkins <amaranth@ubuntu.com>2014-04-10 20:06:14 -0500
committerTravis Watkins <amaranth@ubuntu.com>2014-04-11 22:29:37 -0500
commit126cab926ac23825a2817012da61b8eadaca2380 (patch)
tree0a4431085c31afbfac7c047e67dbb0a3064ffc1d /src/main/java/org/bukkit/block
parent609f137230ae4e07aa71ba676c66118454b6f55d (diff)
downloadbukkit-126cab926ac23825a2817012da61b8eadaca2380.tar
bukkit-126cab926ac23825a2817012da61b8eadaca2380.tar.gz
bukkit-126cab926ac23825a2817012da61b8eadaca2380.tar.lz
bukkit-126cab926ac23825a2817012da61b8eadaca2380.tar.xz
bukkit-126cab926ac23825a2817012da61b8eadaca2380.zip
Update Bukkit for Minecraft 1.7.8
Diffstat (limited to 'src/main/java/org/bukkit/block')
-rw-r--r--src/main/java/org/bukkit/block/Skull.java32
1 files changed, 30 insertions, 2 deletions
diff --git a/src/main/java/org/bukkit/block/Skull.java b/src/main/java/org/bukkit/block/Skull.java
index 974aea20..e0f9fd3c 100644
--- a/src/main/java/org/bukkit/block/Skull.java
+++ b/src/main/java/org/bukkit/block/Skull.java
@@ -1,7 +1,10 @@
package org.bukkit.block;
+import org.bukkit.OfflinePlayer;
import org.bukkit.SkullType;
+import java.util.UUID;
+
/**
* Represents a Skull
*/
@@ -17,19 +20,44 @@ public interface Skull extends BlockState {
/**
* Gets the owner of the skull
*
- * @return the owner of the skull
+ * @return the owner of the skull or null if the profile does not have a name
+ * @deprecated Skulls no longer store player names, they store profiles
+ * @see #getPlayer()
*/
+ @Deprecated
public String getOwner();
/**
- * Sets the owner of the skull
+ * Does nothing
*
* @param name the new owner of the skull
* @return true if the owner was successfully set
+ * @deprecated Skulls no longer store player names, they store profiles
+ * @see #setPlayer(org.bukkit.OfflinePlayer)
*/
+ @Deprecated
public boolean setOwner(String name);
/**
+ * Gets the owner of the skull, if one exists
+ *
+ * @return the owner of the skull or null if this skull does not have an owner
+ */
+ public OfflinePlayer getPlayer();
+
+ /**
+ * Sets the owner of the skull to this player
+ * <p>
+ * If the owner does not contain all the needed data for the skull a call to
+ * {@link #update()} may potentially involve a blocking web request to acquire
+ * the missing data.
+ *
+ * @param player the new owner of the skull
+ * @return true if the owner was successfully set
+ */
+ public boolean setPlayer(OfflinePlayer player);
+
+ /**
* Gets the rotation of the skull in the world
*
* @return the rotation of the skull