FoxAPI is an easy-to-use economy API for Hytale plugins, allowing multiple plugins to support economy plugins indirectly.
To build from source, you will need to obtain a HytaleServer.jar file, which requires you to own Hytale. View Hytale's documentation on downloading a jar here
Once you have a HytaleServer.jar file, create a directory called libs/ in the project root directory, and place the HytaleServer.jar file in the folder.
You can then build it using Maven from your IDE of choice.
In IntelliJ Idea, click the Maven logo on the right hand side, click FoxEconomy, Lifecycle, and then dobule click install.
This will create the FoxAPI jar in the target/ folder.
To use FoxAPI in your plugin, add FoxEconomy as a dependency in your pom.xml:
<dependencies>
<dependency>
<groupId>xyz.herberto.foxAPI</groupId>
<artifactId>FoxAPI</artifactId>
<version>1.0.0</version>
<systemPath>${pom.basedir}/libs/FoxAPI.jar</systemPath>
<scope>system</scope>
</dependency>
</dependencies>You can use FoxAPI to create your own economy plugin. See the examples for more details.
All API methods are detailed in the API-README.MD file.
Using FoxAPI to integrate with an economy plugin: https://github.com/PlasmaServices/FoxAPIExample.
Using FoxAPI to create an economy plugin: https://github.com/PlasmaServices/FoxEconomy.
Hooking into FoxAPI must be done in your protected void start() method in your main class, protected void setup() will NOT work, as it loads before FoxAPI.
Support for FoxEconomy and FoxAPI is provided in https://discord.gg/mcplugins