mirror of
https://github.com/BentoBoxWorld/Level.git
synced 2024-12-25 10:38:20 +01:00
Updated to latest CompositeCommand API
Updated POM to use latest BSB version.
This commit is contained in:
parent
08844a8e18
commit
181cb25357
2
pom.xml
2
pom.xml
@ -48,7 +48,7 @@
|
||||
<dependency>
|
||||
<groupId>us.tastybento</groupId>
|
||||
<artifactId>bskyblock</artifactId>
|
||||
<version>alpha-0.0.1</version>
|
||||
<version>LATEST</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>bskyblock.addon</groupId>
|
||||
|
@ -19,7 +19,7 @@ public class AdminLevel extends CompositeCommand {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean execute(User user, List<String> args) {
|
||||
public boolean execute(User user, String label, List<String> args) {
|
||||
if (args.size() == 2) {
|
||||
// Get world
|
||||
World world = null;
|
||||
@ -38,7 +38,7 @@ public class AdminLevel extends CompositeCommand {
|
||||
return true;
|
||||
} else {
|
||||
if (user.isPlayer()) {
|
||||
levelPlugin.calculateIslandLevel(world, user, playerUUID, false, getPermissionPrefix());
|
||||
levelPlugin.calculateIslandLevel(world, user, playerUUID, false, getPermissionPrefix());
|
||||
} else {
|
||||
levelPlugin.calculateIslandLevel(world, user, playerUUID, true, getPermissionPrefix());
|
||||
}
|
||||
|
@ -21,7 +21,7 @@ public class AdminTop extends CompositeCommand {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean execute(User user, List<String> args) {
|
||||
public boolean execute(User user, String label, List<String> args) {
|
||||
// Get world
|
||||
World world = null;
|
||||
if (args.isEmpty()) {
|
||||
|
@ -8,16 +8,16 @@ import us.tastybento.bskyblock.api.commands.CompositeCommand;
|
||||
import us.tastybento.bskyblock.api.user.User;
|
||||
|
||||
public class IslandLevel extends CompositeCommand {
|
||||
|
||||
|
||||
private final Level levelPlugin;
|
||||
|
||||
|
||||
public IslandLevel(Level levelPlugin, CompositeCommand parent) {
|
||||
super(parent, "level");
|
||||
this.levelPlugin = levelPlugin;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean execute(User user, List<String> args) {
|
||||
public boolean execute(User user, String label, List<String> args) {
|
||||
if (!args.isEmpty()) {
|
||||
// Asking for another player's level?
|
||||
// Convert name to a UUID
|
||||
@ -45,7 +45,7 @@ public class IslandLevel extends CompositeCommand {
|
||||
this.setPermission("island.level");
|
||||
this.setParameters("island.level.parameters");
|
||||
this.setDescription("island.level.description");
|
||||
this.setOnlyPlayer(true);
|
||||
this.setOnlyPlayer(true);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ public class IslandTop extends CompositeCommand {
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean execute(User user, List<String> list) {
|
||||
public boolean execute(User user, String label, List<String> list) {
|
||||
plugin.getTopTen().getGUI(getWorld(), user, getPermissionPrefix());
|
||||
return true;
|
||||
}
|
||||
@ -26,7 +26,7 @@ public class IslandTop extends CompositeCommand {
|
||||
this.setPermission("island.top");
|
||||
this.setDescription("island.top.description");
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user