Skip to content

Commit

Permalink
Avoid error from extensive reach locations, fixes #1688
Browse files Browse the repository at this point in the history
  • Loading branch information
PikaMug committed May 20, 2021
1 parent 60d319f commit eff3e14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main/src/main/java/me/blackvein/quests/Quester.java
Original file line number Diff line number Diff line change
Expand Up @@ -2610,7 +2610,7 @@ public void reachLocation(final Quest quest, final Location l) {
finishObjective(quest, new Objective(type, new ItemStack(Material.AIR, 1),
new ItemStack(Material.AIR, 1)), null, null, null, location, null, null,
null);
} else if (getQuestData(quest).hasReached.get(index) == false) {
} else if (index >= getQuestData(quest).hasReached.size()) {
getQuestData(quest).hasReached.set(index, true);
finishObjective(quest, new Objective(type, new ItemStack(Material.AIR, 1),
new ItemStack(Material.AIR, 1)), null, null, null, location, null, null,
Expand Down

0 comments on commit eff3e14

Please sign in to comment.