mirror of
https://e.coding.net/circlecloud/QuickShop.git
synced 2024-11-23 02:08:55 +00:00
Hopefully fixes #5
This commit is contained in:
parent
fa084634a0
commit
7e73d8dcee
@ -1,7 +1,6 @@
|
|||||||
package org.maxgamer.quickshop.Listeners;
|
package org.maxgamer.quickshop.Listeners;
|
||||||
|
|
||||||
import org.bukkit.event.EventHandler;
|
import org.bukkit.event.EventHandler;
|
||||||
import org.bukkit.event.EventPriority;
|
|
||||||
import org.bukkit.event.Listener;
|
import org.bukkit.event.Listener;
|
||||||
import org.bukkit.event.player.AsyncPlayerChatEvent;
|
import org.bukkit.event.player.AsyncPlayerChatEvent;
|
||||||
import org.maxgamer.quickshop.QuickShop;
|
import org.maxgamer.quickshop.QuickShop;
|
||||||
@ -18,10 +17,11 @@ public class ChatListener implements Listener {
|
|||||||
this.plugin = plugin;
|
this.plugin = plugin;
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler(ignoreCancelled = true, priority = EventPriority.LOWEST)
|
@EventHandler
|
||||||
public void onChat(final AsyncPlayerChatEvent e) {
|
public void onChat(final AsyncPlayerChatEvent e) {
|
||||||
if (!plugin.getShopManager().getActions().containsKey(e.getPlayer().getUniqueId()))
|
if (!plugin.getShopManager().getActions().containsKey(e.getPlayer().getUniqueId())) {
|
||||||
return;
|
return;
|
||||||
|
}
|
||||||
plugin.getShopManager().handleChat(e.getPlayer(), e.getMessage());
|
plugin.getShopManager().handleChat(e.getPlayer(), e.getMessage());
|
||||||
e.setCancelled(true);
|
e.setCancelled(true);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user