Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package me.tequilaxbr.breport;
- import org.bukkit.command.Command;
- import org.bukkit.command.CommandSender;
- import org.bukkit.entity.Player;
- import org.bukkit.plugin.java.JavaPlugin;
- public class Main extends JavaPlugin {
- public void onEnable(){
- System.out.println("[BReport] Plugin Ativado");
- System.out.println("[BReport] By TequilAxBr");
- }
- public void onDisable(){
- System.out.println("[BReport] Plugin Desativado");
- System.out.println("[BReport] By TequilAxBr");
- }
- public boolean onCommand(CommandSender sender, Command command, String label, String[] args) {
- @SuppressWarnings("unused")
- Player p = (Player) sender;
- if(label.equalsIgnoreCase("report")) {
- if(args.length < 2) return false;
- String msg = "";
- for(int i = 0; i < args.length; i++){
- msg=msg+args[i] + " ";
- }
- //Quando for pegar o que o player reportou usa o 'msg'.
- //Ex:
- p.sendMessage("§bSeu report foi §a"+msg);
- }
- return false;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement