List of usage examples for net.minecraftforge.server.permission PermissionAPI hasPermission
public static boolean hasPermission(GameProfile profile, String node, @Nullable IContext context)
From source file:com.lothrazar.cyclicmagic.registry.PermissionRegistry.java
License:Open Source License
public static boolean hasPermissionHere(EntityPlayer player, BlockPos pos) { if (player.world.isRemote) { return true;//Do not check permissions on client side! can crash or go crazy }/* www . j a v a 2 s . c om*/ return PermissionAPI.hasPermission(player.getGameProfile(), MODIFYBLOCKS, new BlockPosContext(player, pos, null, null)); }