File tree Expand file tree Collapse file tree
worldguard-bukkit/src/main/java/com/sk89q/worldguard/bukkit/listener Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -258,13 +258,11 @@ private void handleBlockRightClick(PlayerInteractEvent event) {
258258 }
259259
260260 if (wcfg .useRegions ) {
261- //Block placedIn = block.getRelative(event.getBlockFace());
262- ApplicableRegionSet set =
263- WorldGuard .getInstance ().getPlatform ().getRegionContainer ().createQuery ().getApplicableRegions (BukkitAdapter .adapt (block .getLocation ()));
264- //ApplicableRegionSet placedInSet = plugin.getRegionContainer().createQuery().getApplicableRegions(placedIn.getLocation());
265261 LocalPlayer localPlayer = getPlugin ().wrapPlayer (player );
266262
267263 if (item != null && item .getType ().getKey ().toString ().equals (wcfg .regionWand ) && getPlugin ().hasPermission (player , "worldguard.region.wand" )) {
264+ ApplicableRegionSet set = WorldGuard .getInstance ().getPlatform ().getRegionContainer ().createQuery ()
265+ .getApplicableRegions (BukkitAdapter .adapt (block .getLocation ()), RegionQuery .QueryOption .SORT );
268266 if (set .size () > 0 ) {
269267 player .sendMessage (ChatColor .YELLOW + "Can you build? " + (set .testState (localPlayer , Flags .BUILD ) ? "Yes" : "No" ));
270268
You can’t perform that action at this time.
0 commit comments