mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-12 03:47:27 +00:00
get the name of the player who spawned this npc with soulstone
This commit is contained in:
1 parent
b7ad0ce29b
commit
9fef65b194
4 files changed
+26
-2
No files matched your search
@@ -52,6 +52,8 @@ public class DataAdvanced {
|
||||
public boolean attackOtherFactions = false;
|
||||
public boolean defendFaction = false;
|
||||
public boolean disablePitch = false;
|
||||
|
||||
public String soulStonePlayerName;
|
||||
|
||||
public DataAdvanced(EntityNPCInterface npc) {
|
||||
this.npc = npc;
|
||||
@@ -83,6 +85,8 @@ public class DataAdvanced {
|
||||
|
||||
compound.setTag("NPCDialogOptions", nbtDialogs(npc.dialogs));
|
||||
|
||||
compound.setString("SoulStonePlayerName", soulStonePlayerName);
|
||||
|
||||
return compound;
|
||||
}
|
||||
|
||||
@@ -113,6 +117,8 @@ public class DataAdvanced {
|
||||
factions.readFromNBT(compound.getCompoundTag("FactionPoints"));
|
||||
|
||||
npc.dialogs = getDialogs(compound.getTagList("NPCDialogOptions", 10));
|
||||
|
||||
soulStonePlayerName = compound.getString("SoulStonePlayerName");
|
||||
}
|
||||
|
||||
private HashMap<Integer, DialogOption> getDialogs(NBTTagList tagList) {
|
||||
|
||||
Reference in new issue
Block a user