Advertisement
Guest User

test

a guest
Nov 26th, 2014
177
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.04 KB | None | 0 0
  1. import java.util.logging.Logger;
  2.  
  3. import org.bukkit.ChatColor;
  4. import org.bukkit.command.Command;
  5. import org.bukkit.command.CommandSender;
  6. import org.bukkit.entity.Player;
  7. import org.bukkit.plugin.PluginDescriptionFile;
  8. import org.bukkit.plugin.java.JavaPlugin;
  9.  
  10. public class test extends JavaPlugin{
  11.  
  12. public final Logger logger = Logger.getLogger("Minecraft");
  13. public static test plugin;
  14.  
  15. @Override
  16. public void onDisable() {
  17. PluginDescriptionFile pdfFile = this.getDescription();
  18. this.logger.info(pdfFile.getName() + " Has Been Disabled!");
  19. }
  20.  
  21. @Override
  22. public void onEnable() {
  23. PluginDescriptionFile pdfFile = this.getDescription();
  24. this.logger.info(pdfFile.getName() + " Version " + pdfFile.getVersion() + " Has Been Enabled!");
  25. }
  26.  
  27. public boolean onCommand(CommandSender sender, Command cmd, String commandLabel, String[] args) {
  28. Player player = (Player) sender;
  29. if(commandLabel.equalsIgnoreCase("test")) {
  30. player.sendMessage(ChatColor.GOLD + "working");
  31. }
  32. return false;
  33. }
  34.  
  35.  
  36.  
  37.  
  38.  
  39. (meant to say working when you say /test)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement