Add convenience methods for debugging.

This commit is contained in:
asofold 2012-10-01 02:22:50 +02:00
parent f05a327f4b
commit c3eebcc9be

View File

@ -844,5 +844,23 @@ public class BlockProperties {
return false;
}
}
/**
* Convenience method for debugging purposes.
* @param loc
* @return
*/
public static final boolean isPassable(final PlayerLocation loc) {
return isPassable(loc.getBlockAccess(), loc.getX(), loc.getY(), loc.getZ(), loc.getTypeId());
}
/**
* Convenience method for debugging purposes.
* @param loc
* @return
*/
public static final boolean isPassable(final Location loc) {
return isPassable(((org.bukkit.craftbukkit.CraftWorld) loc.getWorld()).getHandle(), loc.getX(), loc.getY(), loc.getZ(), loc.getBlock().getTypeId());
}
}