Skip to content

Commit

Permalink
Fix quest objective text was not moved to a new line
Browse files Browse the repository at this point in the history
  • Loading branch information
TorayLife authored and mchorse committed Jun 15, 2023
1 parent b765c78 commit 504ee92
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,15 @@ public static void fillQuest(GuiElement element, Quest quest, boolean forceRewar
element.add(new GuiText(mc).text(DialogueFragment.process(characterQuest.story)).color(0xaaaaaa, true).marginBottom(12));
element.add(Elements.label(IKey.lang("mappet.gui.quests.objectives.title")));

StringBuilder objectives = new StringBuilder();

for (AbstractObjective objective : characterQuest.objectives)
{
element.add(Elements.label(IKey.str("- " + objective.stringify(mc.player))).color(0xaaaaaa));
objectives.append(IKey.str("- " + objective.stringify(mc.player)).toString() + "\n");
}

element.add(new GuiText(mc).text(objectives.toString()).color(0xaaaaaa, true));

if (!Mappet.questsPreviewRewards.get() && !forceReward)
{
return;
Expand Down

0 comments on commit 504ee92

Please sign in to comment.