Your Command was not Recognised

Discussion in 'Plugin Development' started by Nikowolf123, Jul 3, 2020.

  1. Offline

    Nikowolf123

    Hey Bukkit Community!
    I have a Problem: When I execute a command, it says: Your Command was not Recognised.

    https://hastebin.com/ezocuwoqom.java <-- Heres my code. (Down below the plugin.yml


    Thank you!
     
  2. Offline

    bowlerguy66

    You put .toLowerCase() when making the lowerCmd variable, then you used capital letters in your switch statement for "fastAF" "nofastAF" and "Skelly"
     
    Last edited: Jul 4, 2020
  3. Offline

    Strahan

    You also checked if sender is a Player after casting it thus. That's putting the cart in front of the horse, lol

    PS you also should not embed the color character, use ChatColor enum. You don't need to send enable and disable messages, Spigot already does that. Lastly, in your skelly command you have
    if(le instanceof Zombie){ yet le = skelly which is a Skeleton so that will never evaluate true.
     

Share This Page