mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-17 07:35:11 +00:00
Proper Reformating
This commit is contained in:
1 parent
ce75880aba
commit
180d257024
1179 files changed
+59847
-61583
No files matched your search
@@ -38,43 +38,43 @@ import java.util.HashSet;
|
||||
import java.util.UUID;
|
||||
|
||||
public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
public PlayerDialogData dialogData = new PlayerDialogData(this);
|
||||
public PlayerBankData bankData = new PlayerBankData(this);
|
||||
public PlayerQuestData questData = new PlayerQuestData(this);
|
||||
public PlayerTransportData transportData = new PlayerTransportData(this);
|
||||
public PlayerFactionData factionData = new PlayerFactionData(this);
|
||||
public PlayerItemGiverData itemgiverData = new PlayerItemGiverData(this);
|
||||
public PlayerMailData mailData = new PlayerMailData(this);
|
||||
public AnimationData animationData = new AnimationData(this);
|
||||
public PlayerDialogData dialogData = new PlayerDialogData(this);
|
||||
public PlayerBankData bankData = new PlayerBankData(this);
|
||||
public PlayerQuestData questData = new PlayerQuestData(this);
|
||||
public PlayerTransportData transportData = new PlayerTransportData(this);
|
||||
public PlayerFactionData factionData = new PlayerFactionData(this);
|
||||
public PlayerItemGiverData itemgiverData = new PlayerItemGiverData(this);
|
||||
public PlayerMailData mailData = new PlayerMailData(this);
|
||||
public AnimationData animationData = new AnimationData(this);
|
||||
public PlayerEffectData effectData = new PlayerEffectData(this);
|
||||
public DataTimers timers = new DataTimers(this);
|
||||
public DataSkinOverlays skinOverlays = new DataSkinOverlays(this);
|
||||
public DataTimers timers = new DataTimers(this);
|
||||
public DataSkinOverlays skinOverlays = new DataSkinOverlays(this);
|
||||
public MagicData magicData = new MagicData();
|
||||
|
||||
public EntityNPCInterface editingNpc;
|
||||
public NBTTagCompound cloned;
|
||||
public EntityNPCInterface editingNpc;
|
||||
public NBTTagCompound cloned;
|
||||
|
||||
public UUID partyUUID = null;
|
||||
private final HashSet<UUID> partyInvites = new HashSet<>();
|
||||
public UUID partyUUID = null;
|
||||
private final HashSet<UUID> partyInvites = new HashSet<>();
|
||||
|
||||
public EntityPlayer player;
|
||||
public EntityPlayer player;
|
||||
|
||||
public String playername = "";
|
||||
public String uuid = "";
|
||||
public String playername = "";
|
||||
public String uuid = "";
|
||||
|
||||
private EntityNPCInterface activeCompanion = null;
|
||||
public int companionID = 0;
|
||||
private EntityNPCInterface activeCompanion = null;
|
||||
public int companionID = 0;
|
||||
|
||||
public boolean isGUIOpen = false;
|
||||
public boolean isGUIOpen = false;
|
||||
public boolean hadInteract = true;
|
||||
|
||||
public boolean updateClient = false;
|
||||
|
||||
public ScreenSize screenSize = new ScreenSize(-1,-1);
|
||||
public ScreenSize screenSize = new ScreenSize(-1, -1);
|
||||
|
||||
public int profileSlot = 0;
|
||||
|
||||
public void onLogin() {
|
||||
public void onLogin() {
|
||||
// Continue playing animation for self when re-logging
|
||||
AnimationData animationData = this.animationData;
|
||||
if (animationData != null && animationData.isClientAnimating()) {
|
||||
@@ -92,57 +92,57 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
}
|
||||
}
|
||||
|
||||
public void onLogout() {
|
||||
this.partyInvites.clear();
|
||||
}
|
||||
public void onLogout() {
|
||||
this.partyInvites.clear();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void saveNBTData(NBTTagCompound nbtTagCompound) {
|
||||
}
|
||||
@Override
|
||||
public void saveNBTData(NBTTagCompound nbtTagCompound) {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loadNBTData(NBTTagCompound compound) {
|
||||
}
|
||||
@Override
|
||||
public void loadNBTData(NBTTagCompound compound) {
|
||||
}
|
||||
|
||||
public void setNBT(NBTTagCompound data){
|
||||
dialogData.loadNBTData(data);
|
||||
bankData.loadNBTData(data);
|
||||
questData.loadNBTData(data);
|
||||
transportData.loadNBTData(data);
|
||||
factionData.loadNBTData(data);
|
||||
itemgiverData.loadNBTData(data);
|
||||
mailData.loadNBTData(data);
|
||||
timers.readFromNBT(data);
|
||||
skinOverlays.readFromNBT(data);
|
||||
animationData.readFromNBT(data);
|
||||
public void setNBT(NBTTagCompound data) {
|
||||
dialogData.loadNBTData(data);
|
||||
bankData.loadNBTData(data);
|
||||
questData.loadNBTData(data);
|
||||
transportData.loadNBTData(data);
|
||||
factionData.loadNBTData(data);
|
||||
itemgiverData.loadNBTData(data);
|
||||
mailData.loadNBTData(data);
|
||||
timers.readFromNBT(data);
|
||||
skinOverlays.readFromNBT(data);
|
||||
animationData.readFromNBT(data);
|
||||
effectData.readFromNBT(data);
|
||||
magicData.readToNBT(data);
|
||||
|
||||
if(player != null){
|
||||
playername = player.getCommandSenderName();
|
||||
uuid = player.getPersistentID().toString();
|
||||
}
|
||||
else{
|
||||
playername = data.getString("PlayerName");
|
||||
uuid = data.getString("UUID");
|
||||
}
|
||||
companionID = data.getInteger("PlayerCompanionId");
|
||||
if (player != null) {
|
||||
playername = player.getCommandSenderName();
|
||||
uuid = player.getPersistentID().toString();
|
||||
} else {
|
||||
playername = data.getString("PlayerName");
|
||||
uuid = data.getString("UUID");
|
||||
}
|
||||
companionID = data.getInteger("PlayerCompanionId");
|
||||
profileSlot = data.getInteger("ProfileSlot");
|
||||
if(data.hasKey("PlayerCompanion") && !hasCompanion()){
|
||||
EntityCustomNpc npc = new EntityCustomNpc(player.worldObj);
|
||||
npc.readEntityFromNBT(data.getCompoundTag("PlayerCompanion"));
|
||||
npc.setPosition(player.posX, player.posY, player.posZ);
|
||||
if(npc.advanced.role == EnumRoleType.Companion){
|
||||
setCompanion(npc);
|
||||
((RoleCompanion)npc.roleInterface).setSitting(false);
|
||||
player.worldObj.spawnEntityInWorld(npc);
|
||||
}
|
||||
}
|
||||
isGUIOpen = data.getBoolean("isGUIOpen");
|
||||
if (data.hasKey("PlayerCompanion") && !hasCompanion()) {
|
||||
EntityCustomNpc npc = new EntityCustomNpc(player.worldObj);
|
||||
npc.readEntityFromNBT(data.getCompoundTag("PlayerCompanion"));
|
||||
npc.setPosition(player.posX, player.posY, player.posZ);
|
||||
if (npc.advanced.role == EnumRoleType.Companion) {
|
||||
setCompanion(npc);
|
||||
((RoleCompanion) npc.roleInterface).setSitting(false);
|
||||
player.worldObj.spawnEntityInWorld(npc);
|
||||
}
|
||||
}
|
||||
isGUIOpen = data.getBoolean("isGUIOpen");
|
||||
DBCAddon.instance.readFromNBT(this, data);
|
||||
}
|
||||
}
|
||||
|
||||
public NBTTagCompound getNBT() {
|
||||
if(player != null){
|
||||
if (player != null) {
|
||||
playername = player.getCommandSenderName();
|
||||
uuid = player.getPersistentID().toString();
|
||||
}
|
||||
@@ -163,19 +163,19 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
compound.setString("PlayerName", playername);
|
||||
compound.setString("UUID", uuid);
|
||||
compound.setInteger("PlayerCompanionId", companionID);
|
||||
compound.setBoolean("isGUIOpen",isGUIOpen);
|
||||
compound.setBoolean("isGUIOpen", isGUIOpen);
|
||||
compound.setInteger("ProfileSlot", profileSlot);
|
||||
|
||||
if(hasCompanion()){
|
||||
if (hasCompanion()) {
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
if(activeCompanion.writeToNBTOptional(nbt))
|
||||
if (activeCompanion.writeToNBTOptional(nbt))
|
||||
compound.setTag("PlayerCompanion", nbt);
|
||||
}
|
||||
DBCAddon.instance.writeToNBT(this, compound);
|
||||
return compound;
|
||||
}
|
||||
|
||||
public NBTTagCompound getSyncNBT(){
|
||||
public NBTTagCompound getSyncNBT() {
|
||||
NBTTagCompound compound = new NBTTagCompound();
|
||||
dialogData.saveNBTData(compound);
|
||||
questData.saveNBTData(compound);
|
||||
@@ -183,24 +183,24 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
return compound;
|
||||
}
|
||||
|
||||
public void setSyncNBT(NBTTagCompound data){
|
||||
public void setSyncNBT(NBTTagCompound data) {
|
||||
dialogData.loadNBTData(data);
|
||||
questData.loadNBTData(data);
|
||||
factionData.loadNBTData(data);
|
||||
}
|
||||
|
||||
public NBTTagCompound getPlayerEffects(){
|
||||
public NBTTagCompound getPlayerEffects() {
|
||||
NBTTagCompound compound = new NBTTagCompound();
|
||||
effectData.writeToNBT(compound);
|
||||
return compound;
|
||||
}
|
||||
|
||||
public void setPlayerEffects(NBTTagCompound data){
|
||||
public void setPlayerEffects(NBTTagCompound data) {
|
||||
effectData.readFromNBT(data);
|
||||
}
|
||||
|
||||
public NBTTagCompound getSyncNBTFull() {
|
||||
if(player != null){
|
||||
if (player != null) {
|
||||
playername = player.getCommandSenderName();
|
||||
uuid = player.getPersistentID().toString();
|
||||
}
|
||||
@@ -217,114 +217,113 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
return compound;
|
||||
}
|
||||
|
||||
public void setSyncNBTFull(NBTTagCompound data){
|
||||
public void setSyncNBTFull(NBTTagCompound data) {
|
||||
dialogData.loadNBTData(data);
|
||||
bankData.loadNBTData(data);
|
||||
questData.loadNBTData(data);
|
||||
transportData.loadNBTData(data);
|
||||
factionData.loadNBTData(data);
|
||||
mailData.loadNBTData(data);
|
||||
if(player != null){
|
||||
if (player != null) {
|
||||
playername = player.getCommandSenderName();
|
||||
uuid = player.getPersistentID().toString();
|
||||
}
|
||||
else{
|
||||
} else {
|
||||
playername = data.getString("PlayerName");
|
||||
uuid = data.getString("UUID");
|
||||
}
|
||||
DBCAddon.instance.readFromNBT(this, data);
|
||||
}
|
||||
|
||||
public void getDBCSync(NBTTagCompound compound){
|
||||
public void getDBCSync(NBTTagCompound compound) {
|
||||
DBCAddon.instance.writeToNBT(this, compound);
|
||||
}
|
||||
|
||||
public void setDBCSync(NBTTagCompound data){
|
||||
public void setDBCSync(NBTTagCompound data) {
|
||||
DBCAddon.instance.readFromNBT(this, data);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init(Entity entity, World world) {
|
||||
@Override
|
||||
public void init(Entity entity, World world) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
public void setGUIOpen(boolean bool) {
|
||||
this.isGUIOpen = bool;
|
||||
}
|
||||
public void setGUIOpen(boolean bool) {
|
||||
this.isGUIOpen = bool;
|
||||
}
|
||||
|
||||
public boolean getGUIOpen() {
|
||||
return this.isGUIOpen;
|
||||
}
|
||||
public boolean getGUIOpen() {
|
||||
return this.isGUIOpen;
|
||||
}
|
||||
|
||||
public ScreenSize getScreenSize(){
|
||||
return screenSize;
|
||||
}
|
||||
public ScreenSize getScreenSize() {
|
||||
return screenSize;
|
||||
}
|
||||
|
||||
public void setScreenSize(ScreenSize size){
|
||||
screenSize = size;
|
||||
}
|
||||
public void setScreenSize(ScreenSize size) {
|
||||
screenSize = size;
|
||||
}
|
||||
|
||||
public boolean hasCompanion(){
|
||||
return activeCompanion != null && !activeCompanion.isDead;
|
||||
}
|
||||
public boolean hasCompanion() {
|
||||
return activeCompanion != null && !activeCompanion.isDead;
|
||||
}
|
||||
|
||||
public void setCompanion(EntityNPCInterface npc) {
|
||||
if(npc != null && npc.advanced.role != EnumRoleType.Companion)//shouldnt happen
|
||||
return;
|
||||
companionID++;
|
||||
activeCompanion = npc;
|
||||
if(npc != null)
|
||||
((RoleCompanion)npc.roleInterface).companionID = companionID;
|
||||
save();
|
||||
}
|
||||
public void setCompanion(EntityNPCInterface npc) {
|
||||
if (npc != null && npc.advanced.role != EnumRoleType.Companion)//shouldnt happen
|
||||
return;
|
||||
companionID++;
|
||||
activeCompanion = npc;
|
||||
if (npc != null)
|
||||
((RoleCompanion) npc.roleInterface).companionID = companionID;
|
||||
save();
|
||||
}
|
||||
|
||||
public void updateCompanion(World world) {
|
||||
if(!hasCompanion() || world == activeCompanion.worldObj)
|
||||
return;
|
||||
RoleCompanion role = (RoleCompanion) activeCompanion.roleInterface;
|
||||
role.owner = player;
|
||||
if(!role.isFollowing())
|
||||
return;
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
activeCompanion.writeToNBTOptional(nbt);
|
||||
activeCompanion.isDead = true;
|
||||
public void updateCompanion(World world) {
|
||||
if (!hasCompanion() || world == activeCompanion.worldObj)
|
||||
return;
|
||||
RoleCompanion role = (RoleCompanion) activeCompanion.roleInterface;
|
||||
role.owner = player;
|
||||
if (!role.isFollowing())
|
||||
return;
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
activeCompanion.writeToNBTOptional(nbt);
|
||||
activeCompanion.isDead = true;
|
||||
|
||||
EntityCustomNpc npc = new EntityCustomNpc(world);
|
||||
npc.readEntityFromNBT(nbt);
|
||||
npc.setPosition(player.posX, player.posY, player.posZ);
|
||||
setCompanion(npc);
|
||||
((RoleCompanion)npc.roleInterface).setSitting(false);
|
||||
world.spawnEntityInWorld(npc);
|
||||
}
|
||||
EntityCustomNpc npc = new EntityCustomNpc(world);
|
||||
npc.readEntityFromNBT(nbt);
|
||||
npc.setPosition(player.posX, player.posY, player.posZ);
|
||||
setCompanion(npc);
|
||||
((RoleCompanion) npc.roleInterface).setSitting(false);
|
||||
world.spawnEntityInWorld(npc);
|
||||
}
|
||||
|
||||
public void inviteToParty(Party party) {
|
||||
if (party != null && this.partyUUID == null && !this.partyInvites.contains(party.getPartyUUID())) {
|
||||
this.partyInvites.add(party.getPartyUUID());
|
||||
public void inviteToParty(Party party) {
|
||||
if (party != null && this.partyUUID == null && !this.partyInvites.contains(party.getPartyUUID())) {
|
||||
this.partyInvites.add(party.getPartyUUID());
|
||||
|
||||
AchievementPacket.sendAchievement((EntityPlayerMP) player, true, "party.inviteAlert", party.getPartyLeader().getCommandSenderName());
|
||||
ChatAlertPacket.sendChatAlert((EntityPlayerMP) player, "\u00A7a", "party.inviteChat", " ", party.getPartyLeader().getCommandSenderName(), "!");
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public void ignoreInvite(UUID uuid) {
|
||||
if (uuid != null) {
|
||||
this.partyInvites.remove(uuid);
|
||||
PartyInvitePacket.sendInviteData((EntityPlayerMP) player);
|
||||
}
|
||||
}
|
||||
public void ignoreInvite(UUID uuid) {
|
||||
if (uuid != null) {
|
||||
this.partyInvites.remove(uuid);
|
||||
PartyInvitePacket.sendInviteData((EntityPlayerMP) player);
|
||||
}
|
||||
}
|
||||
|
||||
public void acceptInvite(UUID uuid) {
|
||||
if (uuid != null) {
|
||||
this.partyInvites.remove(uuid);
|
||||
Party party = PartyController.Instance().getParty(uuid);
|
||||
if(party != null){
|
||||
public void acceptInvite(UUID uuid) {
|
||||
if (uuid != null) {
|
||||
this.partyInvites.remove(uuid);
|
||||
Party party = PartyController.Instance().getParty(uuid);
|
||||
if (party != null) {
|
||||
if (!party.getIsLocked()) {
|
||||
party.addPlayer(player);
|
||||
PartyController.Instance().pingPartyUpdate(party);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public Party getPlayerParty() {
|
||||
if (partyUUID != null) {
|
||||
@@ -333,100 +332,100 @@ public class PlayerData implements IExtendedEntityProperties, IPlayerData {
|
||||
return null;
|
||||
}
|
||||
|
||||
public HashSet<UUID> getPartyInvites() {
|
||||
return (HashSet<UUID>) this.partyInvites.clone();
|
||||
}
|
||||
public HashSet<UUID> getPartyInvites() {
|
||||
return (HashSet<UUID>) this.partyInvites.clone();
|
||||
}
|
||||
|
||||
public void setCompanion(ICustomNpc npc) {
|
||||
this.setCompanion((EntityNPCInterface) npc.getMCEntity());
|
||||
}
|
||||
public void setCompanion(ICustomNpc npc) {
|
||||
this.setCompanion((EntityNPCInterface) npc.getMCEntity());
|
||||
}
|
||||
|
||||
public ICustomNpc getCompanion() {
|
||||
return (ICustomNpc) NpcAPI.Instance().getIEntity(activeCompanion);
|
||||
}
|
||||
public ICustomNpc getCompanion() {
|
||||
return (ICustomNpc) NpcAPI.Instance().getIEntity(activeCompanion);
|
||||
}
|
||||
|
||||
public int getCompanionID() {
|
||||
return companionID;
|
||||
}
|
||||
public int getCompanionID() {
|
||||
return companionID;
|
||||
}
|
||||
|
||||
public IPlayerDialogData getDialogData() {
|
||||
return dialogData;
|
||||
}
|
||||
public IPlayerDialogData getDialogData() {
|
||||
return dialogData;
|
||||
}
|
||||
|
||||
public IPlayerBankData getBankData() {
|
||||
return bankData;
|
||||
}
|
||||
public IPlayerBankData getBankData() {
|
||||
return bankData;
|
||||
}
|
||||
|
||||
public IPlayerQuestData getQuestData() {
|
||||
return questData;
|
||||
}
|
||||
public IPlayerQuestData getQuestData() {
|
||||
return questData;
|
||||
}
|
||||
|
||||
public IPlayerTransportData getTransportData() {
|
||||
return transportData;
|
||||
}
|
||||
public IPlayerTransportData getTransportData() {
|
||||
return transportData;
|
||||
}
|
||||
|
||||
public IPlayerFactionData getFactionData() {
|
||||
return factionData;
|
||||
}
|
||||
public IPlayerFactionData getFactionData() {
|
||||
return factionData;
|
||||
}
|
||||
|
||||
public IPlayerItemGiverData getItemGiverData() {
|
||||
return itemgiverData;
|
||||
}
|
||||
public IPlayerItemGiverData getItemGiverData() {
|
||||
return itemgiverData;
|
||||
}
|
||||
|
||||
public IPlayerMailData getMailData() {
|
||||
return mailData;
|
||||
}
|
||||
public IPlayerMailData getMailData() {
|
||||
return mailData;
|
||||
}
|
||||
|
||||
public synchronized void save() {
|
||||
public synchronized void save() {
|
||||
// Don't Save this is a Modification of a Profile's PlayerData
|
||||
Profile profile = ProfileController.Instance.getProfile(UUID.fromString(uuid));
|
||||
if(profile != null && profile.currentSlotId != this.profileSlot){
|
||||
if (profile != null && profile.currentSlotId != this.profileSlot) {
|
||||
ProfileController.Instance.saveOffline(profile, UUID.fromString(uuid));
|
||||
return;
|
||||
}
|
||||
|
||||
final NBTTagCompound compound = getNBT();
|
||||
final String filename;
|
||||
if(ConfigMain.DatFormat){
|
||||
filename = uuid + ".dat";
|
||||
} else {
|
||||
filename = uuid + ".json";
|
||||
}
|
||||
PlayerDataController.Instance.putPlayerMap(playername, uuid);
|
||||
PlayerDataController.Instance.putPlayerDataCache(uuid, this);
|
||||
CustomNPCsThreader.customNPCThread.execute(() -> {
|
||||
try {
|
||||
File saveDir = PlayerDataController.Instance.getSaveDir();
|
||||
File file = new File(saveDir, filename + "_new");
|
||||
File file1 = new File(saveDir, filename);
|
||||
if(ConfigMain.DatFormat){
|
||||
CompressedStreamTools.writeCompressed(compound, new FileOutputStream(file));
|
||||
} else {
|
||||
NBTJsonUtil.SaveFile(file, compound);
|
||||
}
|
||||
if(file1.exists()){
|
||||
file1.delete();
|
||||
}
|
||||
file.renameTo(file1);
|
||||
} catch (Exception e) {
|
||||
LogWriter.except(e);
|
||||
}
|
||||
});
|
||||
}
|
||||
final NBTTagCompound compound = getNBT();
|
||||
final String filename;
|
||||
if (ConfigMain.DatFormat) {
|
||||
filename = uuid + ".dat";
|
||||
} else {
|
||||
filename = uuid + ".json";
|
||||
}
|
||||
PlayerDataController.Instance.putPlayerMap(playername, uuid);
|
||||
PlayerDataController.Instance.putPlayerDataCache(uuid, this);
|
||||
CustomNPCsThreader.customNPCThread.execute(() -> {
|
||||
try {
|
||||
File saveDir = PlayerDataController.Instance.getSaveDir();
|
||||
File file = new File(saveDir, filename + "_new");
|
||||
File file1 = new File(saveDir, filename);
|
||||
if (ConfigMain.DatFormat) {
|
||||
CompressedStreamTools.writeCompressed(compound, new FileOutputStream(file));
|
||||
} else {
|
||||
NBTJsonUtil.SaveFile(file, compound);
|
||||
}
|
||||
if (file1.exists()) {
|
||||
file1.delete();
|
||||
}
|
||||
file.renameTo(file1);
|
||||
} catch (Exception e) {
|
||||
LogWriter.except(e);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void load() {
|
||||
NBTTagCompound data = PlayerDataController.Instance.loadPlayerData(player.getPersistentID().toString());
|
||||
if(data.hasNoTags()){
|
||||
data = PlayerDataController.Instance.loadPlayerDataOld(player.getCommandSenderName());
|
||||
}
|
||||
if(data.hasNoTags()){
|
||||
public void load() {
|
||||
NBTTagCompound data = PlayerDataController.Instance.loadPlayerData(player.getPersistentID().toString());
|
||||
if (data.hasNoTags()) {
|
||||
data = PlayerDataController.Instance.loadPlayerDataOld(player.getCommandSenderName());
|
||||
}
|
||||
if (data.hasNoTags()) {
|
||||
data = getNBT();
|
||||
}
|
||||
setNBT(data);
|
||||
}
|
||||
setNBT(data);
|
||||
}
|
||||
|
||||
public static PlayerData get(EntityPlayer player) {
|
||||
if(player.worldObj.isRemote)
|
||||
if (player.worldObj.isRemote)
|
||||
return CustomNpcs.proxy.getPlayerData(player);
|
||||
|
||||
return PlayerDataController.Instance.getPlayerData(player);
|
||||
|
||||
Reference in new issue
Block a user