3
0
Mirror von https://github.com/IntellectualSites/FastAsyncWorldEdit.git synchronisiert 2024-11-09 13:00:05 +01:00

Changes to completely separate SyncTabCompleteListener from Paper

Dieser Commit ist enthalten in:
IronApollo 2018-10-19 18:24:58 -04:00
Ursprung 3add6fd32b
Commit ea0133b740

Datei anzeigen

@ -1,6 +1,8 @@
package com.boydti.fawe.bukkit.listener; package com.boydti.fawe.bukkit.listener;
import com.sk89q.worldedit.bukkit.WorldEditPlugin; import com.sk89q.worldedit.bukkit.WorldEditPlugin;
import org.bukkit.command.ConsoleCommandSender;
import org.bukkit.event.EventHandler; import org.bukkit.event.EventHandler;
import org.bukkit.event.server.TabCompleteEvent; import org.bukkit.event.server.TabCompleteEvent;
@ -13,7 +15,7 @@ public class SyncTabCompleteListener extends ATabCompleteListener {
@EventHandler @EventHandler
public void onTabComplete(TabCompleteEvent event) { public void onTabComplete(TabCompleteEvent event) {
if (event.isCommand()) { if (event.getSender() instanceof ConsoleCommandSender || event.getBuffer().startsWith("/")) {
List<String> result = this.onTab(event.getBuffer(), event.getSender()); List<String> result = this.onTab(event.getBuffer(), event.getSender());
if (result != null) { if (result != null) {
event.setCompletions(result); event.setCompletions(result);