Solved new JavaPlugin()

Discussion in 'Plugin Development' started by acecheesecr14, Apr 22, 2014.

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


    So it's possible to make a new plugin inside a plugin.
    Does anyone know thebest way to do this?

    Something like JavaPlugin plugin = new JavaPlugin(PluginLoader, Server, etc...)
  2. Offline


    To what end?
  3. Never heard of this before
  4. Offline


    just because you created a new instance of the class does not mean you created a new plugin
  5. Offline



    read javadocs about plugins.
  6. Offline


    Alright. then is this possible?
  7. Offline


  8. Offline


    I've been told stuff is impossible before and done it. Sometimes people are too closed minded.

    If I find a way, I'll let you know.
  9. Offline


    Ok...why would you want to do this? :confused:
  10. Offline


    Bukkit is designed to load plugins on startup, and expects each plugin to contain only that plugin.

    Ofc you can do whatever you want, but you'll most likelly encounter more obstacles than it is worth. Also, by saying "impossible" we mean "it is bad practice and you should probably not do that".
  11. Offline


    What reason is there to do this?
  12. Offline


    I guess you could create a new class that extends JavaPlugin in the same .jar. But you's still need a .jar with a plugin.yml that points to that new class in that other .jar. So this is kinda pointless...and, as asked a lot of times before in the thread, what benefit is there really to this?
    acecheesecr14 likes this.
  13. Offline


    its possible to load arbitrary JavaPlugin from arbitrary location, but this have ZERO benefits.
  14. Offline


    I dont see a point but you could recreate another jar in your plugin and then reload the server
  15. Offline


    why reloading server and loading jar from disk when you can load jar directly to memory from memory or arbitrary location?
  16. Offline


    Checking Bukkit's Github will give you more info on how plugins are loaded.
    acecheesecr14 likes this.
  17. Offline


  18. Offline


    I feel like this is another feeble attempt to include someone else's plugin in a plugin
  19. Offline


    there is no benifit from embedding jar into jar since you can distribute zip with multiple jars inside.
  20. Offline


    It is not an attempt... If that was the case I would just change the plugin.yml... xD
    Although it is an attempt to modify someone else's plugin... Allowing me to log and have separate config files wilt compatible clean code.
  21. Offline


    This doesnt sound like something Bukkit would approve of.
  22. Offline


    It's a grey area... GREEY MOAR THAN MY HAIR.. Bukkit doesn't disapprove.

    Besides.. There's nothing wrong as long as you provide original credits, and it's got a public licence...

    Reloading's baddd, mkaaayyy..
  23. Offline


    I was questioning wether anyone has done it before, and if I'm using the correct methods...

    It's not impossible. The best and most efficient way of doing it would probably be modifying the way plugins are loaded. But again I'm a curious person and I wondered if it's possible.
  24. Offline


    Removed discussion about unofficial builds that really have nothing to do with this as they don't have anything to do with this question anyway.

    Bundling another plugin and distributing it with modifications would not be allowed on BukkitDev. As mentioned, this is a terrible idea anyway.
  25. Offline


    The best way to do this is to obtain the original source and the permission to use it, then modifying it. The way you're discussing is "possible" but seriously offensive to the sensibilities of everyone in this thread.

    Furthermore, modifying someone else's plugin is not supported on this forum. Do it right or don't do it at all.
Thread Status:
Not open for further replies.

Share This Page