World Generator Cannot Be Found

Discussion in 'Plugin Development' started by The Gaming Grunts, Mar 26, 2014.

Thread Status:
Not open for further replies.
  1. Hey everyone! So in my plugin I have 2 built-in generators. I want people to be able to be able to use those, as well as any other generator for world creation. I have the following command to do it:

    /world create <name> [-g <generator>]

    Ex: /world create VoidWorld -g VoidGenerator

    This is the code for the command:

    Code:java
    1. if (args[0].equalsIgnoreCase("create")){
    2. if (args.length == 2)
    3. GlobalManagerAPI.getAPI().getWorldCreator().generateWorld(args[1]);
    4. if (args.length == 4){
    5. if (args[2].equalsIgnoreCase("-g")){
    6. if (!(args[3].equalsIgnoreCase("VoidGenerator") && args[3].equalsIgnoreCase("FlatWorldGenerator")))
    7. GlobalManagerAPI.getAPI().getWorldCreator().createWorld(args[1], sender, args[3]);
    8. if (args[3].equalsIgnoreCase("VoidGenerator"))
    9. GlobalManagerAPI.getAPI().getWorldCreator().generateVoidWorld(args[1]);
    10. if (args[3].equalsIgnoreCase("FlatWorldGenerator"))
    11. GlobalManagerAPI.getAPI().getWorldCreator().generateFlatWorld(args[1]);
    12. }
    13. }
    14. }


    The problem is that if I try to use one of the built-in generators, I get an error in the console saying that the generator for the world could not be set because the plugin "VoidGenerator" cannot be found. Any ideas on how I can fix this? Thanks :)
     
  2. Still can't figure it out :( Probably something really simple that I'm missing...
     
Thread Status:
Not open for further replies.

Share This Page