By default, the example of this reward is disabled to avoid initial error because not all servers use PlaceholderAPI on which this reward is dependent.
The reward type works based on PAPI placeholders, where the reward is unlocked for the player when the certain expression is met - all comparisons (< > <= >= ==) are supported, both numbers and boolean values.
expression [text] - an evaluating expression that evaluates whether the reward is claimable
remaining-expression [text] - expression that calculates the remaining amount
Be sure that you have the PAPI extension downloaded.
/papi ecloud download Statistic for this example
Example configuration
# Decides if rewards will be claimableenabled:truetype:custom_reward## Reward tag#tag:Custom Reward# Expression is used to determine if player can claim this reward.# Returns true/false depending on the condition## In this case, when player has 20 mob kills, he# can claim this rewardexpression:"%statistic_mob_kills% >= 20"# Remaining expression is used to calculate missing amount# for %amount% placeholder in unavailable-loreremaining-expression:"20 - %statistic_mob_kills%"## Permission which player must have to be# able to obtain this reward#permission:ultimaterewards.customRewardExample## When player has this permission,# following properties will be shown.## NOTE THAT ITEM & SOUND NAMES ARE SLIGHTLY DIFFERENT BETWEEN >1.12 & 1.13< VERSIONS!# SO MAKE SURE YOU ARE USING VALID ITEM NAMES (DEFAULT ONE ARE USED FROM 1.13+ VERSIONS)# OTHERWISE WILL BE REPLACED BY STONE IF INVALID NAME IS IN USE.## When the reward is currently claimable:available-item:"LIME_DYE"available-display-name:"&a&lCUSTOM REWARD"available-lore: - "&7You have collected" - "&7enough monster kills to be" - "&7able to obtain this reward!" - " " - "&b► Click to claim!"## Whereas player doesn't have enough required kills,# this version of reward item is displayed in inventory:#unavailable-item:"RED_DYE"unavailable-display-name:"&c&lCUSTOM REWARD"unavailable-lore: - "&7You need to kill" - "&720 monsters to unlock" - "&7this reward!" - " " - "&4► Requires another %amount% monster kills"## When player already claimed this reward:#claimed-item:"GRAY_DYE"claimed-display-name:"&7&lCUSTOM REWARD"claimed-lore: - "&7You have already" - "&7claimed this reward" - "&7for 20 monster kills!"## Player doesn't have permission for this reward,# following properties will be shown.#no-permission-item:BARRIERno-permission-display-name:"&c&l&mCUSTOM REWARD"no-permission-lore: - "&c ✕ Locked, requires" - "&c %permission% permission"## Commands list that will be executed after player# obtains this reward.# All available actions can be found on# https://revivalo.gitbook.io/ultimaterewards/## Format: () - optional value | [] - required value# [<actionType>] (<chance>):<command>## Examples:# - [console] 50:give %player% diamond 1# - this command will have 50%# execution chance due his property value## - [message] "&aYou have claimed your %type% reward!"# - this action will send player a message# with defined content## You can also use the random placeholders# from randoms.yml file and use it in command.# Example:# - give %player% iron_ingot %exampleRandom%# - placeholder will be replaced by# random number from defined interval in randoms.yml#actions: - '[console] give %player% diamond_sword 1' - '[console] say %player% claimed his %type% reward!' - '[message] &7You have claimed custom reward for |&7 20 monster kills!'# - '[actionbar] &aSuccessfully claimed!' # Action bar can be used only from 1.12 versions! - '[title] &aClaimed' - '[subtitle] &aReward %type%'