From 0f3f3c552aed3eca287c7b6a2e4658c04c670855 Mon Sep 17 00:00:00 2001 From: afforess Date: Sun, 3 Apr 2011 11:40:08 -0400 Subject: [PATCH] Added player.saveData and player.loadData. --- .../net/minecraft/server/ServerConfigurationManager.java | 2 +- .../java/org/bukkit/craftbukkit/entity/CraftPlayer.java | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/minecraft/server/ServerConfigurationManager.java b/src/main/java/net/minecraft/server/ServerConfigurationManager.java index 0d71c5209f..b2a4e9a19d 100644 --- a/src/main/java/net/minecraft/server/ServerConfigurationManager.java +++ b/src/main/java/net/minecraft/server/ServerConfigurationManager.java @@ -39,7 +39,7 @@ public class ServerConfigurationManager { private File k; private File l; private File m; - private PlayerFileData n; + public PlayerFileData n; // CraftBukkit - private->public private boolean o; // CraftBukkit start diff --git a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java index 4be1716c37..02b2fdcb1e 100644 --- a/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java +++ b/src/main/java/org/bukkit/craftbukkit/entity/CraftPlayer.java @@ -201,6 +201,14 @@ public class CraftPlayer extends CraftHumanEntity implements Player { return getHandle().Z(); } + public void loadData() { + server.getHandle().n.b(getHandle()); + } + + public void saveData() { + server.getHandle().n.a(getHandle()); + } + public void updateInventory() { getHandle().m(); }