diff options
Diffstat (limited to 'src/main/java/net/benjidial/nswp/commands/DeleteWaypoint.java')
-rw-r--r-- | src/main/java/net/benjidial/nswp/commands/DeleteWaypoint.java | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/main/java/net/benjidial/nswp/commands/DeleteWaypoint.java b/src/main/java/net/benjidial/nswp/commands/DeleteWaypoint.java new file mode 100644 index 0000000..d24d133 --- /dev/null +++ b/src/main/java/net/benjidial/nswp/commands/DeleteWaypoint.java @@ -0,0 +1,20 @@ +package net.benjidial.nswp.commands; + +import net.benjidial.nswp.Database; + +import org.bukkit.entity.Player; + +import java.sql.SQLException; + +public class DeleteWaypoint extends WaypointCommand { + public CompletionType getCompletionType() { + return CompletionType.Waypoint; + } + + public boolean body(Player player, String[] args) throws SQLException { + if (args.length != 1) + return false; + Database.deleteWaypoint(player, args[0]); + return true; + } +} |