Restore missing NPC effects, see #2189

This commit is contained in:
PikaMug 2024-03-02 02:47:29 -05:00
parent ff4dcacea8
commit f440ea43cd
1 changed files with 2 additions and 2 deletions

View File

@ -41,8 +41,7 @@ public class BukkitNpcEffectThread implements Runnable {
for (final Entity entity : nearby) {
final UUID uuid = plugin.getDependencies().getUuidFromNpc(entity);
if (uuid != null) {
showConfigEffect(plugin.getQuester(player.getUniqueId()), entity.getUniqueId(),
entity.getLocation());
showConfigEffect(plugin.getQuester(player.getUniqueId()), uuid, entity.getLocation());
}
}
}
@ -91,6 +90,7 @@ public class BukkitNpcEffectThread implements Runnable {
*/
public void showConfigEffect(final BukkitQuester quester, final UUID targetUuid, final Location targetLocation) {
if (targetUuid != null) {
targetLocation.add(0, 2, 0);
final BukkitQuesterPostViewEffectEvent event;
if (quester.canAcceptQuest(targetUuid)) {
showEffect(quester.getPlayer(), targetLocation, plugin.getConfigSettings().getEffect());