Skip to content

Commit

Permalink
Test
Browse files Browse the repository at this point in the history
  • Loading branch information
fullwall committed Feb 15, 2015
1 parent 20e0ea2 commit bce5e04
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/java/net/citizensnpcs/npc/ai/CitizensNavigator.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package net.citizensnpcs.npc.ai;

import java.util.Iterator;
import java.util.ListIterator;

import net.citizensnpcs.Settings.Setting;
import net.citizensnpcs.api.ai.EntityTarget;
Expand Down Expand Up @@ -306,8 +307,8 @@ public PassableState isPassable(BlockSource source, PathPoint point) {
private static class DoorOpener implements PathCallback {
@Override
@SuppressWarnings("deprecation")
public void run(NPC npc, Block point, double radius) {
if (radius < 2) {
public void run(NPC npc, Block point, ListIterator<Block> path) {
if (npc.getStoredLocation().distance(point.getLocation()) < 2) {
boolean bottom = (point.getData() & 8) == 0;
Block set = bottom ? point : point.getRelative(BlockFace.DOWN);
set.setData((byte) ((set.getData() & 7) | 4));
Expand Down

0 comments on commit bce5e04

Please sign in to comment.