Close GUI after taking quest from NPC, fixes #1081. Bump version number

This commit is contained in:
PikaMug 2020-02-16 22:53:02 -05:00
parent 4911939a29
commit 379bcec37c
8 changed files with 11 additions and 9 deletions

2
dist/pom.xml vendored
View File

@ -5,7 +5,7 @@
<parent>
<groupId>me.blackvein.quests</groupId>
<artifactId>quests-parent</artifactId>
<version>3.8.7</version>
<version>3.8.8</version>
</parent>
<artifactId>quests-dist</artifactId>
<packaging>pom</packaging>

View File

@ -4,7 +4,7 @@
<parent>
<groupId>me.blackvein.quests</groupId>
<artifactId>quests-parent</artifactId>
<version>3.8.7</version>
<version>3.8.8</version>
</parent>
<artifactId>quests-main</artifactId>

View File

@ -3738,7 +3738,9 @@ public class Quester {
getPlayer().sendMessage(ChatColor.YELLOW + msg);
}
return false;
} else if (quest.getNpcStart() != null && plugin.getSettings().canAllowCommandsForNpcQuests() == false) {
} else if (quest.getNpcStart() != null && quest.getNpcStart().getEntity() != null
&& quest.getNpcStart().getEntity().getLocation().distance(getPlayer().getLocation()) < 5.0
&& plugin.getSettings().canAllowCommandsForNpcQuests() == false) {
if (giveReason) {
String msg = Lang.get(getPlayer(), "mustSpeakTo");
msg = msg.replace("<npc>", ChatColor.DARK_PURPLE + quest.getNpcStart().getName() + ChatColor.YELLOW);

View File

@ -128,8 +128,8 @@ public class PlayerListener implements Listener {
} catch (Exception e) {
e.printStackTrace();
}
evt.getWhoClicked().closeInventory();
}
evt.getWhoClicked().closeInventory();
}
}
}

View File

@ -6,12 +6,12 @@
<groupId>me.blackvein.quests</groupId>
<artifactId>quests-parent</artifactId>
<version>3.8.7</version>
<version>3.8.8</version>
<name>quests</name>
<url>https://github.com/PikaMug/Quests/</url>
<properties>
<revision>3.8.7</revision>
<revision>3.8.8</revision>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>me.blackvein.quests</groupId>
<artifactId>quests-parent</artifactId>
<version>3.8.7</version>
<version>3.8.8</version>
</parent>
<properties>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>me.blackvein.quests</groupId>
<artifactId>quests-parent</artifactId>
<version>3.8.7</version>
<version>3.8.8</version>
</parent>
<properties>

View File

@ -5,7 +5,7 @@
<parent>
<groupId>me.blackvein.quests</groupId>
<artifactId>quests-parent</artifactId>
<version>3.8.7</version>
<version>3.8.8</version>
</parent>
<properties>