Do not check for doors between if target is already a door.

This commit is contained in:
MobiusDev 2017-09-29 10:01:36 +00:00
parent ba7092e5b6
commit 13b55f77fe
5 changed files with 5 additions and 5 deletions

View File

@ -582,7 +582,7 @@ public class GeoEngine
final int ty = target.getY();
final int tz = target.getZ();
if (DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
if (!target.isDoor() && DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
{
return false;
}

View File

@ -582,7 +582,7 @@ public class GeoEngine
final int ty = target.getY();
final int tz = target.getZ();
if (DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
if (!target.isDoor() && DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
{
return false;
}

View File

@ -582,7 +582,7 @@ public class GeoEngine
final int ty = target.getY();
final int tz = target.getZ();
if (DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
if (!target.isDoor() && DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
{
return false;
}

View File

@ -580,7 +580,7 @@ public class GeoEngine
final int ty = target.getY();
final int tz = target.getZ();
if (DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceId(), false))
if (!target.isDoor() && DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceId(), false))
{
return false;
}

View File

@ -582,7 +582,7 @@ public class GeoEngine
final int ty = target.getY();
final int tz = target.getZ();
if (DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
if (!target.isDoor() && DoorData.getInstance().checkIfDoorsBetween(ox, oy, oz, tx, ty, tz, origin.getInstanceWorld(), false))
{
return false;
}