I was a Bukkit Plugin developer and am a bit confused - I’m not very, uh, technical? -.
I see there is Sponge & SpongeAPI - can we download them to begin making small plugins or are they used to make the thing that allows us to make a plugin?
Sorry if this makes no sense, I’m English. Get it?
You can download and use SpongeAPI. But there are many functions missing and you can’t test the plugin, so I think it’s better to wait until there’s a working Sponge server…
Ah okay - If I were to download the SpongeAPI from Bukkit, it gives me “sponge-master”. This is a folder that has lots of Java Classes in it, which would I set as my build path?
Currently the easiest way is to just put the org.spongepowered.api package into your plugin src and write your code with that, then wait for the official JAR file as exporting the plugin before a server exists is senseless anyways…
The probably more complex (but probably better) way is to make it a JAR file with Gradle, like explained in readme.md - then you can put this into your build path.
No, don’t do this. In the root of your project run
$ git submodule add https://github.com/SpongePowered/SpongeAPI
Then edit (or create) your
settings.gradle and add
Finally, edit your
build.gradle and add
And if it isn’t already there, add
apply plugin: "java"
Now you can compile it by just running
gradle build, or create an IDE project by importing it. Updating is as simple as running
git pull from the SpongeAPI folder. The version of SpongeAPI that you’ve built against is included in your git commit.
basically yes you can start already creating simple e.g. broadcast/welcome plugins but it doesnt make much sense to start already
There is an example plugin in the API. It doesn’t do much atm.
The POM is how Maven builds its project model.
*.gradle is Gradle’s equivalent.
There’s not enough done yet in the Sponge API for plugins to really do anything. Additionally, because there’s no working Sponge server yet, you can’t test any of your work end to end (you could write some unit tests to execute your code, but you can’t start up a server today running a sponge plugin).
All that’s really possible for you is to create a very basic layout for your plugin. There is no implementation of anything yet. It is just the API so all you will see is interfaces. Even now I wouldn’t suggest laying out your plugin because I’m sure the API will change in some ways as it goes through development.
Looks like @TheYeti is kindly making the API available in his Maven repo: [OUTDATED] Coming from Bukkit? Here's Some Tips and Tricks to Get you Started - #68 by TheYeti
Which is nice for us Bukkit refugees used to building with Maven