mirror of
https://github.com/plexusorg/Plex-FAWE.git
synced 2025-07-06 04:46:40 +00:00
Update the Bukkit adapter to the Spigot API Preview
This commit is contained in:
@ -117,7 +117,7 @@ public class BukkitServerInterface implements MultiUserPlatform {
|
||||
|
||||
@Override
|
||||
public void registerCommands(Dispatcher dispatcher) {
|
||||
List<CommandInfo> toRegister = new ArrayList<CommandInfo>();
|
||||
List<CommandInfo> toRegister = new ArrayList<>();
|
||||
BukkitCommandInspector inspector = new BukkitCommandInspector(plugin, dispatcher);
|
||||
|
||||
for (CommandMapping command : dispatcher.getCommands()) {
|
||||
@ -159,7 +159,7 @@ public class BukkitServerInterface implements MultiUserPlatform {
|
||||
|
||||
@Override
|
||||
public Map<Capability, Preference> getCapabilities() {
|
||||
Map<Capability, Preference> capabilities = new EnumMap<Capability, Preference>(Capability.class);
|
||||
Map<Capability, Preference> capabilities = new EnumMap<>(Capability.class);
|
||||
capabilities.put(Capability.CONFIGURATION, Preference.NORMAL);
|
||||
capabilities.put(Capability.WORLDEDIT_CUI, Preference.NORMAL);
|
||||
capabilities.put(Capability.GAME_HOOKS, Preference.PREFERRED);
|
||||
@ -175,7 +175,7 @@ public class BukkitServerInterface implements MultiUserPlatform {
|
||||
|
||||
@Override
|
||||
public Collection<Actor> getConnectedUsers() {
|
||||
List<Actor> users = new ArrayList<Actor>();
|
||||
List<Actor> users = new ArrayList<>();
|
||||
for (org.bukkit.entity.Player player : Bukkit.getServer().getOnlinePlayers()) {
|
||||
users.add(new BukkitPlayer(plugin, player));
|
||||
}
|
||||
|
Reference in New Issue
Block a user