mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-12 02:37:27 +00:00
Fix Quest Tracking Autocomplete Text
This commit is contained in:
1 parent
dd544d033a
commit
2f8dad6ca0
2 files changed
+15
-4
No files matched your search
@@ -347,7 +347,12 @@ public class NoppesUtilPlayer {
|
||||
NBTTagCompound compound = new NBTTagCompound();
|
||||
compound.setTag("Quest",trackedQuest.writeToNBT(new NBTTagCompound()));
|
||||
compound.setString("CategoryName", trackedQuest.getCategory().getName());
|
||||
compound.setString("TurnInNPC", trackedQuest.getNpcName());
|
||||
if(trackedQuest.completion == EnumQuestCompletion.Instant){
|
||||
compound.setBoolean("Instant", true);
|
||||
}
|
||||
else {
|
||||
compound.setString("TurnInNPC", trackedQuest.getNpcName());
|
||||
}
|
||||
NBTTagList nbtTagList = new NBTTagList();
|
||||
for (IQuestObjective objective : trackedQuest.questInterface.getObjectives(player)) {
|
||||
nbtTagList.appendTag(new NBTTagString(objective.getText()));
|
||||
|
||||
@@ -143,9 +143,15 @@ public class OverlayQuestTracking extends Gui {
|
||||
objectiveLines.add(objective);
|
||||
}
|
||||
|
||||
String npcName = compound.getString("TurnInNPC");
|
||||
if (!npcName.isEmpty()) {
|
||||
turnInText.add("Complete with " + npcName);
|
||||
boolean instantComplete = compound.getBoolean("Instant");
|
||||
if(instantComplete){
|
||||
turnInText.add("Completed automatically");
|
||||
}
|
||||
else {
|
||||
String npcName = compound.getString("TurnInNPC");
|
||||
if (!npcName.isEmpty()) {
|
||||
turnInText.add("Complete with " + npcName);
|
||||
}
|
||||
}
|
||||
|
||||
this.initOverlay();
|
||||
|
||||
Reference in new issue
Block a user