UniversalGUI API ( Java ) - Oskang09/UniversalGUI GitHub Wiki

ShopRequirement API

public class CustomSR extends ShopRequirement
{
    public CustomSR()
    {
        setAuthor("Your Name"); // Your's name
        setConfigName("custom"); // Becareful , this will be your config name in shop configuration
        setDisplayName("Custom ShopRequirement"); // Just display name when loading , maybe other usage for later
    }
    @Override
    public boolean checkHook() { } 
    // checkHook() is for check the required plugin exists or not.

    @Override
    public boolean check(Player p) { } 
    // check(Player p) is for check the player has reach the requirement or not 

    @Override
    public void remove(Player p) { } 
    // remove(Player p) this will run after check(Player p) , 
    // player reached requirement and remove the requirement object from player

    // For reading the config setting u able to use ( this.configmap.get("node"); )
    // configmap is FileConfiguration.class
}

ShopReward API

public class CustomSR extends ShopReward
{
    public CustomSR()
    {
        setAuthor("Your Name"); // Your's name
        setConfigName("custom"); // Becareful , this will be your config name in shop configuration
        setDisplayName("Custom ShopReward"); // Just display name when loading , maybe other usage for later
    }
    @Override
    public boolean checkHook() { } 
    // checkHook() is for check the required plugin exists or not.

    @Override
    public boolean add(Player p) { } 
    // add(Player p) is for giving rewards to player

    // For reading the config setting u able to use ( this.configmap.get("node"); )
    // configmap is FileConfiguration.class
}