Plugin Not working : Could not load !

Discussion in 'Plugin Development' started by general656, Dec 30, 2013.

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

    general656

    Hello beautiful forum :D Guys I have a smaaall problem . I just created my first plugin in bukkit , and I can not make it work on a server . I think I have done all correctly but something does not working .
    Code and Images :
    Code
    "main" code :

    Code:java
    1. package me.bukkit.plugin;
    2.  
    3. import org.bukkit.Bukkit;
    4. import org.bukkit.command.Command;
    5. import org.bukkit.command.CommandSender;
    6. import org.bukkit.entity.Player;
    7. import org.bukkit.plugin.java.JavaPlugin;
    8.  
    9. public class main extends JavaPlugin{
    10.  
    11.  
    12. @Override
    13. public void onEnable(){
    14. getLogger().info("This plugin () is ENABLED !");
    15.  
    16. }
    17.  
    18. @Override
    19. public void onDisable(){
    20.  
    21. }
    22.  
    23. public boolean onCommand(CommandSender sender,Command cmd,String label,String[] args)
    24. {
    25. if(cmd.getName().equalsIgnoreCase("ignite")) {
    26. if(args.length !=1){
    27. return false;
    28. }
    29. if (!(sender instanceof Player)) {
    30. sender.sendMessage("Only players can set other players on fire .");
    31. return true;
    32. }
    33.  
    34. Player target = Bukkit.getServer().getPlayer(args[0]);
    35.  
    36. if (target == null){
    37.  
    38. sender.sendMessage(args[0] + "is not currently online .");
    39. return false;
    40. }
    41. target.setFireTicks(1000);
    42. return true;
    43.  
    44. }
    45. return false;
    46. }
    47. }
    48.  

    plugin.yml code:
    Code:
    name: IgnitePlugin
    main: me.bukkit.plugin.main
    author: general656
    version: 1.0.0
     
    commands:
      ignite:
          description: burns a player
          usage: /ignite <player>
          default: op
    Images :
    cmd image : [​IMG]

    [​IMG]
    As you see I have set them all as I should , what's going wrong ?
     
  2. Offline

    TheJakubx

    open the *.jar in zip and check if there is a file plugin.yml
     
  3. Offline

    general656

    [​IMG]
    As it seems ... there is ...
    Also I do not use tab in plugin.yml .. only spaces
     
  4. Offline

    TheJakubx

    hmm... where are class? I see only META-INF and plugins.yml
    when you compile project Select src to compile
    like that:
    [​IMG]
     
  5. Offline

    general656

    Thank you polite minion ... :D But if when I saw the whole error after I updated bukkit to the development Build , it says this :
    [​IMG]
    but as you see I have set them up correctly ... I think ...
    Edit :
    [​IMG]
    And still it doesn't work
     
  6. Offline

    mbaxter ʇıʞʞnq ɐ sɐɥ ı

    There's no classfiles in your jar.
     
  7. Offline

    xTigerRebornx

    general656 You aren't exporting the classes into the jar, as you can see. Make sure you are exporting it properly
    EDIT: Ninjad by mbaxter XD
     
  8. Offline

    TheJakubx

    hmm... it work on my pc, recompile it.
    look: [​IMG]


    My source of your plugin

    You compile with Java 1.6 or 1.7? if 1.7 change in project proporties to 1.6
     
  9. Offline

    general656

    It works .. .thanx .. I just have to export all java source files and resources ... thanx guys for the help, really ... I will continue making new plugins ... :D thank you kind minion :p I would also like to thank my mother , my brother , my uncle ... my father .. my grandmother ...
     
Thread Status:
Not open for further replies.

Share This Page