Simplify superfluous confirmation code

This commit is contained in:
PikaMug 2019-09-25 23:40:54 -04:00
parent afaeb8e24e
commit b1ced220d4

View File

@ -108,7 +108,7 @@ public class QuestOfferPrompt extends StringPrompt {
player.sendMessage(msg); player.sendMessage(msg);
} }
if (!plugin.getSettings().canAskConfirmation()) { if (!plugin.getSettings().canAskConfirmation()) {
plugin.getQuester(player.getUniqueId()).takeQuest(plugin.getQuest(plugin.getQuester(player.getUniqueId()).getQuestToTake()), false); quester.takeQuest(q, false);
} else { } else {
plugin.getConversationFactory().buildConversation((Conversable) player).begin(); plugin.getConversationFactory().buildConversation((Conversable) player).begin();
} }
@ -138,7 +138,7 @@ public class QuestOfferPrompt extends StringPrompt {
player.sendMessage(msg); player.sendMessage(msg);
} }
if (!plugin.getSettings().canAskConfirmation()) { if (!plugin.getSettings().canAskConfirmation()) {
plugin.getQuester(player.getUniqueId()).takeQuest(plugin.getQuest(plugin.getQuester(player.getUniqueId()).getQuestToTake()), false); quester.takeQuest(q, false);
} else { } else {
plugin.getConversationFactory().buildConversation((Conversable) player).begin(); plugin.getConversationFactory().buildConversation((Conversable) player).begin();
} }