mirror of
https://github.com/EssentialsX/Essentials.git
synced 2025-02-21 23:01:28 +01:00
[trunk] EssentialsProtect :- fix owner spam on arm swing, will only show on right-click now
git-svn-id: https://svn.java.net/svn/essentials~svn/trunk@1346 e251c2fe-e539-e718-e476-b85c1f46cddb
This commit is contained in:
parent
0825a1de86
commit
5051bcb383
@ -4,6 +4,7 @@ import com.earth2me.essentials.Essentials;
|
||||
import com.earth2me.essentials.User;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.block.Block;
|
||||
import org.bukkit.event.block.Action;
|
||||
import org.bukkit.event.player.PlayerInteractEvent;
|
||||
import org.bukkit.event.player.PlayerListener;
|
||||
import org.bukkit.inventory.ItemStack;
|
||||
@ -51,7 +52,7 @@ public class EssentialsProtectPlayerListener extends PlayerListener
|
||||
return;
|
||||
}
|
||||
|
||||
if (user.isAuthorized("essentials.protect.ownerinfo"))
|
||||
if (event.getAction() == Action.RIGHT_CLICK_BLOCK && user.isAuthorized("essentials.protect.ownerinfo"))
|
||||
{
|
||||
String ownerName = spData.getBlockOwner(user.getWorld().getName(), user.getName(),
|
||||
blockClicked);
|
||||
|
Loading…
Reference in New Issue
Block a user