Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package me.TheLazeboy.Staves;
- import java.util.logging.Logger;
- import org.bukkit.Bukkit;
- import org.bukkit.ChatColor;
- import org.bukkit.command.Command;
- import org.bukkit.command.CommandSender;
- import org.bukkit.entity.Player;
- import org.bukkit.plugin.PluginDescriptionFile;
- import org.bukkit.plugin.java.JavaPlugin;
- public class Staves extends JavaPlugin{
- public final Logger logger = Logger.getLogger("Minecraft");
- public static Staves plugin;
- public final MyPlayerListener mp = new MyPlayerListener(this);
- @Override
- public void onDisable() {
- PluginDescriptionFile pdfFile = this.getDescription();
- this.logger.info(pdfFile.getName() + " Has Been Disabled!");
- }
- @Override
- public void onEnable() {
- PluginDescriptionFile pdfFile = this.getDescription();
- this.logger.info(pdfFile.getName() + " Version " + pdfFile.getVersion() + " Has Been Enabled!");
- Bukkit.getPluginManager().registerEvents(MyPlayerListener, this);
- Bukkit.getPluginManager().registerEvents((Listener) mp, this);
- }
- public boolean onCommand(CommandSender sender, Command cmd, String commandLabel, String[] args){
- if(commandLabel.equalsIgnoreCase("staves")){
- Player player = (Player) sender;
- player.sendMessage(ChatColor.GRAY + "Staves was made by TheLazeboy!");
- }
- return false;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement