Solved Keeping players banned

Discussion in 'Plugin Development' started by Ethan Rocks 365, Mar 28, 2016.

Thread Status:
Not open for further replies.
  1. Offline

    Ethan Rocks 365

    My code (open)

    Code:
    public boolean onCommand(CommandSender theSender, Command cmd, String commandLable, String[] args)
       {
         if (commandLable.equalsIgnoreCase("ban"))
         {
           Player target = (Bukkit.getServer().getPlayer(args[0]));
           target.kickPlayer();
                  target.setBanned(true);
         }
    


    When ever i restart the server, the banned player is unbanned. Why?
     
  2. Offline

    Konato_K

  3. Offline

    Ethan Rocks 365

    I cant figure out how I use the BanList
     
  4. Offline

    WolfMage1

    It actually says how to use it......
     
  5. Offline

    GamerzKing

    You obviously did t read the docs. It tells you the exact parameters.
     
  6. Offline

    mine-care

    What if there is no argument in the command? This will error :p
     
Thread Status:
Not open for further replies.

Share This Page