Developer API
Here you can find all the information on how to use our API to add custom economies.
Creating a custom economy provider is a fairly straight forward process. First of all, ensure you have the API dependency loaded into your project and set it as a depend in your plugin.yml file.
To being with we need to create a class and have it extend EconomyProvider
some IDEs will then prompt you to add the missing values. In this example we will call our class CustomEconomy
After that is finished if your IDE does not prompt you to add in the missing values you must do so manually here you can find how they should look.
Now all you must do is update each method with the relevant code to work with your plugin. It is recommended to define the API in the onEnable
method. Below we will provide an example using the TokenManager plugin
Now all we must do is register the objective an example of this can be seen below.
Make sure DeluxeCoinflip has been added as a depend in your plugin.yml
to ensure it loads correctly.
Last updated