From 61bb4f860894a176b27d8ee227c76a579b2e6531 Mon Sep 17 00:00:00 2001 From: Robert Date: Wed, 18 Dec 2013 21:22:21 -0500 Subject: [PATCH] fixed a few issues with AccessProfile --- src/com/dark/access/AccessProfile.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/com/dark/access/AccessProfile.java b/src/com/dark/access/AccessProfile.java index 6c14ce0b..9202109a 100644 --- a/src/com/dark/access/AccessProfile.java +++ b/src/com/dark/access/AccessProfile.java @@ -95,6 +95,7 @@ public class AccessProfile implements ISpecialAccess, IVirtualObject if (object instanceof EntityPlayer) { id = ((EntityPlayer) object).username + "_" + System.currentTimeMillis(); + this.global = true; }//Created by a tile else if (object instanceof TileEntity || object == null) { @@ -249,10 +250,11 @@ public class AccessProfile implements ISpecialAccess, IVirtualObject } @Override - public void save(NBTTagCompound nbt) + public void load(NBTTagCompound nbt) { this.profileName = nbt.getString("name"); this.global = nbt.getBoolean("global"); + this.profileID = nbt.getString("profileID"); NBTTagList userList = nbt.getTagList("groups"); if (userList != null && userList.tagCount() > 0) { @@ -267,10 +269,11 @@ public class AccessProfile implements ISpecialAccess, IVirtualObject } @Override - public void load(NBTTagCompound nbt) + public void save(NBTTagCompound nbt) { nbt.setString("name", this.profileName); nbt.setBoolean("global", this.global); + nbt.setString("profileID", this.profileID); NBTTagList usersTag = new NBTTagList(); for (AccessGroup group : this.getGroups()) {