mirror of
https://github.com/MassiveCraft/Factions.git
synced 2024-11-25 19:56:23 +01:00
MassiveCore - Skip Off Hand Interact Test 1
This commit is contained in:
parent
b1907b7682
commit
011a59eb47
@ -1669,6 +1669,9 @@ public class EngineMain extends Engine
|
|||||||
@EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true)
|
@EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true)
|
||||||
public void onPlayerInteractEntity(PlayerInteractEntityEvent event)
|
public void onPlayerInteractEntity(PlayerInteractEntityEvent event)
|
||||||
{
|
{
|
||||||
|
// Ignore Off Hand
|
||||||
|
if (isOffHand(event)) return;
|
||||||
|
|
||||||
// Gather Info
|
// Gather Info
|
||||||
final Player player = event.getPlayer();
|
final Player player = event.getPlayer();
|
||||||
final Entity entity = event.getRightClicked();
|
final Entity entity = event.getRightClicked();
|
||||||
|
@ -41,6 +41,9 @@ public class EngineSpigot extends Engine
|
|||||||
@EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true)
|
@EventHandler(priority = EventPriority.NORMAL, ignoreCancelled = true)
|
||||||
public void onPlayerInteractAtEntity(PlayerInteractAtEntityEvent event)
|
public void onPlayerInteractAtEntity(PlayerInteractAtEntityEvent event)
|
||||||
{
|
{
|
||||||
|
// Ignore Off Hand
|
||||||
|
if (isOffHand(event)) return;
|
||||||
|
|
||||||
// Gather Info
|
// Gather Info
|
||||||
final Player player = event.getPlayer();
|
final Player player = event.getPlayer();
|
||||||
if (MUtil.isntPlayer(player)) return;
|
if (MUtil.isntPlayer(player)) return;
|
||||||
|
Loading…
Reference in New Issue
Block a user