Install your plugin
Before installing your first plugin, you will need to build it.
Click on the icon on the side bar to open the terminal and type:
You should see something like this in your console:
Then, copy the built wheel package endstone_my_plugin.whl
under the dist
folder to the plugins folder path/to/bedrock_server/plugins
.
Now, start your server again. You should see your plugin has been successfully loaded.
Congratulations! You've made your first plugin for Endstone servers!
Development Mode (a.k.a Editable Installs)¶
When creating a plugin, developers usually want to implement and test changes iteratively, before cutting a release and preparing a distribution archive. In normal circumstances this can be quite cumbersome and require the developers to continuously re-build and re-install the plugin.
But we've got you! Endstone also allows developers to load the code under development directly from the project folder
without having to copy the whl
files to the plugins
folder.
To do so, you will need the activate the virtual environment. Please make sure Endstone is also installed inside the environment.
You can now enter this ādevelopment modeā by performing an editable installation inside the virtual environment,
using pipās -e/--editable
flag, as shown below:
Now, if you change the source code on the disk, you can simply run the /reload
command in Endstone and you change
will be effective immediately.
When youāre done with a given development task, you can simply uninstall your package
(as you would normally do with pip uninstall <package name>
).
Click on the menu icon on the top bar and select Build > Build Project to build your plugin.
Then, copy the built shared library endstone_my_plugin.dll
to the plugins
folder path/to/bedrock_server/plugins
.
Now, start your server again. You should see your plugin has been successfully loaded.
Congratulations! You've made your first plugin for Endstone servers!