Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package me.Stoolbend.CraftList;
- import java.util.List;
- import org.bukkit.ChatColor;
- import org.bukkit.Server;
- import org.bukkit.command.Command;
- import org.bukkit.command.CommandExecutor;
- import org.bukkit.command.CommandSender;
- import org.bukkit.entity.LivingEntity;
- import org.bukkit.entity.Player;
- import java.sql.*;
- public class CraftListCommandManager implements CommandExecutor {
- public static CraftList plugin;
- public static Server server;
- public static List<LivingEntity> entities;
- // Thanks for DominionSpy for the help with the DB Connection
- public Connection CLDB;
- public CraftListCommandManager(CraftList instance){
- plugin = instance;
- CLDB = DriverManager.getConnection("jdbc:mysql://storecraft.org:3306/storrcra_whitelist?user=STORRCRA&password=,~7Xq.rkm0PB");
- }
- public boolean onCommand(CommandSender sender, Command cmd, String label, String[] args){
- if(label.equalsIgnoreCase("clist")){
- Player player = (Player) sender;
- if(args.length == 1 && args[0].equalsIgnoreCase("listnew")){
- //MySQL Stuff - Only for Storecraft.org Server
- //End MySQL Stuff
- sender.sendMessage(ChatColor.GREEN + "[CraftList] There are currently 0 new applications.");
- }
- if(args.length == 0){
- sender.sendMessage(ChatColor.RED + "[CraftList] You didn't specify any arguments");
- //sender.sendMessage(ChatColor.YELLOW + "/clist listnew " + ChatColor.WHITE + "- Lists the amount of new applications currently waiting");
- }
- }
- return false;
- }
- }
Add Comment
Please, Sign In to add comment