mirror of
https://github.com/PikaMug/Quests.git
synced 2024-12-24 10:09:49 +01:00
Potential fix for #924
This commit is contained in:
parent
d5e050412d
commit
dd985ab2c5
@ -1693,6 +1693,9 @@ public class Quester {
|
||||
int index = 0;
|
||||
for (Location location : getQuestData(quest).locationsReached) {
|
||||
try {
|
||||
if (getCurrentStage(quest).locationsToReach.size() <= index) {
|
||||
return;
|
||||
}
|
||||
Location locationToReach = getCurrentStage(quest).locationsToReach.get(index);
|
||||
double radius = getQuestData(quest).radiiToReachWithin.get(index);
|
||||
if (l.getX() < (locationToReach.getX() + radius) && l.getX() > (locationToReach.getX() - radius)) {
|
||||
@ -1711,6 +1714,7 @@ public class Quester {
|
||||
}
|
||||
}
|
||||
index++;
|
||||
|
||||
} catch (IndexOutOfBoundsException e) {
|
||||
plugin.getLogger().severe("An error has occurred with Quests. Please report on Github. Include the info below");
|
||||
plugin.getLogger().warning("index = " + index);
|
||||
|
Loading…
Reference in New Issue
Block a user