summaryrefslogtreecommitdiffstats
path: root/src/main/java/org
diff options
context:
space:
mode:
authorsk89q <the.sk89q@gmail.com>2011-09-26 15:10:35 -0700
committersk89q <the.sk89q@gmail.com>2011-09-26 15:10:35 -0700
commit87494d46f86738084c52f20acb399f787a436ba5 (patch)
treeb4d6a0524fc07ee08636d14580c0227e4f1b6e87 /src/main/java/org
parent484376bbac625ee595b850d88d22162772ea7606 (diff)
downloadcraftbukkit-87494d46f86738084c52f20acb399f787a436ba5.tar
craftbukkit-87494d46f86738084c52f20acb399f787a436ba5.tar.gz
craftbukkit-87494d46f86738084c52f20acb399f787a436ba5.tar.lz
craftbukkit-87494d46f86738084c52f20acb399f787a436ba5.tar.xz
craftbukkit-87494d46f86738084c52f20acb399f787a436ba5.zip
Added Player.get/setListName to change the name of the player on the player list.
Diffstat (limited to 'src/main/java/org')
-rw-r--r--src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
index 2476be75..8bd1ab11 100644
--- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
+++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java
@@ -124,6 +124,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player {
getHandle().displayName = name;
}
+ public String getListName() {
+ return getHandle().listName;
+ }
+
+ public void setListName(String name) {
+ server.getHandle().changeListName(getHandle(), name);
+ }
+
@Override
public String toString() {
return "CraftPlayer{" + "name=" + getName() + '}';