mirror of
https://github.com/PikaMug/Quests.git
synced 2025-02-05 07:01:51 +01:00
Avoid null locations on reload, untested, fixes #102
This commit is contained in:
parent
0f52951a6c
commit
f3792b480c
@ -164,9 +164,10 @@ public class Quest {
|
||||
} else if (nextStage.locationsToReach != null && nextStage.locationsToReach.size() > 0) {
|
||||
targetLocation = nextStage.locationsToReach.getFirst();
|
||||
}
|
||||
if (targetLocation != null && targetLocation.getWorld().equals(quester.getPlayer().getWorld())) {
|
||||
// plugin.getLogger().info("Setting compass target for " + quester.getPlayer().getName() + " to " + targetLocation);
|
||||
quester.getPlayer().setCompassTarget(targetLocation);
|
||||
if (targetLocation != null) {
|
||||
if (targetLocation.getWorld().equals(quester.getPlayer().getWorld())) {
|
||||
quester.getPlayer().setCompassTarget(targetLocation);
|
||||
}
|
||||
}
|
||||
return targetLocation != null;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user