mirror of
https://github.com/NoCheatPlus/NoCheatPlus.git
synced 2024-12-30 20:37:52 +01:00
Add convenience method for isPassable.
This commit is contained in:
parent
6c610c490b
commit
77d8c27f7e
@ -978,6 +978,17 @@ public class BlockProperties {
|
||||
return isPassable(access, loc.getX(), loc.getY(), loc.getZ(), access.getTypeId(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()));
|
||||
}
|
||||
|
||||
/**
|
||||
* Convenience method to allow using an already fetched or prepared IBlockAccess.
|
||||
* @param access
|
||||
* @param loc
|
||||
* @return
|
||||
*/
|
||||
public static final boolean isPassable(final IBlockAccess access, final Location loc)
|
||||
{
|
||||
return isPassable(access, loc.getX(), loc.getY(), loc.getZ(), access.getTypeId(loc.getBlockX(), loc.getBlockY(), loc.getBlockZ()));
|
||||
}
|
||||
|
||||
/**
|
||||
* API access to read extra properties from files.
|
||||
* @param config
|
||||
|
Loading…
Reference in New Issue
Block a user