mirror of
https://github.com/PikaMug/Quests.git
synced 2024-11-15 07:05:51 +01:00
Merge pull request #396 from christophe6/master
- PlaceholderAPI for start/end messages, switched obj. and start msg.
This commit is contained in:
commit
7df24e079f
@ -98,6 +98,9 @@ public class Quest {
|
||||
public void nextStage(Quester q) {
|
||||
String stageCompleteMessage = q.getCurrentStage(this).completeMessage;
|
||||
if (stageCompleteMessage != null) {
|
||||
if(Quests.placeholder != null) {
|
||||
s = PlaceholderAPI.setPlaceholders(quester.getPlayer(), s);
|
||||
}
|
||||
q.getPlayer().sendMessage(Quests.parseString(stageCompleteMessage, this));
|
||||
}
|
||||
if (plugin.useCompass) {
|
||||
@ -153,16 +156,19 @@ public class Quest {
|
||||
nextStage.startEvent.fire(quester, this);
|
||||
}
|
||||
updateCompass(quester, nextStage);
|
||||
String stageStartMessage = quester.getCurrentStage(this).startMessage;
|
||||
if (stageStartMessage != null) {
|
||||
quester.getPlayer().sendMessage(Quests.parseString(stageStartMessage, this));
|
||||
}
|
||||
String msg = Lang.get(quester.getPlayer(), "questObjectivesTitle");
|
||||
msg = msg.replaceAll("<quest>", name);
|
||||
quester.getPlayer().sendMessage(ChatColor.GOLD + msg);
|
||||
for (String s : quester.getObjectivesReal(this)) {
|
||||
if(Quests.placeholder != null) {
|
||||
s = PlaceholderAPI.setPlaceholders(quester.getPlayer(), s);
|
||||
}
|
||||
quester.getPlayer().sendMessage(s);
|
||||
}
|
||||
String stageStartMessage = quester.getCurrentStage(this).startMessage;
|
||||
if (stageStartMessage != null) {
|
||||
quester.getPlayer().sendMessage(Quests.parseString(stageStartMessage, this));
|
||||
}
|
||||
quester.updateJournal();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user