UltimateRewards Wiki
  • Getting started
    • Support
  • Addons
  • Configs
    • Player Levels
    • Referrals
    • Loginstreak
  • USAGE
    • Installation
    • Commands
  • configuration
    • Rewards
      • Creating Reward
      • Reward Types
        • Afk Reward
          • World Afk Reward
          • Area Afk Reward
          • Region Afk Reward
        • Advent Calendar
        • Pickable Reward
        • Time Reward
        • Time Fixed Reward
        • Streak Reward
        • Streak Fixed Reward
        • Vote Reward
        • Renewable Vote Reward
        • Per Vote Reward
        • Streak Vote Reward
        • Play Time Reward
        • Renewable Play Time Reward
        • Referral Reward
        • Renewable Referral Reward
        • Purchasable Reward
        • Re-Purchasable Reward
        • One Time Reward
        • Time Limited Reward
        • Custom Reward
        • Multiple Custom Reward
        • Coupon Reward
        • Discord Reward
      • Reward Settings
      • Reward Actions
      • Reward Features
        • Auto Claim
        • Notifications
        • Reward NPC
        • Discord Support
        • Reward Requirements
        • Reward Variants
        • Selectable Rewards
        • Randomization
          • Execution Chances
          • Random Placeholders
        • AFK Checkers
        • Leaderboards
    • Menus
      • Basics
      • Example of GUIs
      • Setting Menu
    • Schedules & Timers
  • Colors & Models
  • Placeholders
  • API
    • Events
    • Examples
    • Setting up own playtime calculator
  • Policies
    • TOS
Powered by GitBook
On this page
  1. configuration
  2. Rewards
  3. Reward Types
  4. Afk Reward

World Afk Reward

This reward rewards players who find themselves in a specific world in a repeating cycle.

  • world [text] - certain world where the rewarding should apply

  • required-time [number] - the amount of time the player will be rewarded after staying in the world (in minutes)

  • reset-on-leave [true/false] - should the timer start again when the player leaves and comes back

  • progress-actions[list] - actions proceeded to keep inform the the player that he is in afk area

  • entering-actions[list] - actions proceeded when the player has entered the afk world

  • quiting-actions[list] - actions proceeded when the player has left the afk world

Example configuration

# Decides if rewards will be claimable
enabled: true
#
# Each type of reward has different specifications.
# All currently supported types can be found on:
# https://revivalo.gitbook.io/ultimaterewards/
#
type: world_afk_reward
#
# Reward tag
#
tag: World Afk Reward
# World where the AFK time is computed
world: afk
# Required AFK time to obtain reward (in minutes)
required-time: 2
# Should the progress reset if the
# player leave the world?
reset-on-leave: true
#
# (Optional) Permission which player must have to be
# able to obtain this reward.
#
permission: ultimaterewards.exampleWorldAfkReward
#
# When player has this permission,
# following properties will be shown.
#
# When the reward is currently claimable:
enter-actions:
  - "[subtitle] &aEntered AFK world!"
quit-actions:
  - "[subtitle] &cLeft AFK world"
progress-actions:
  - "[actionbar] &eNext Reward: %progress%"
#
# 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% gold_nugget 1 '
  - '[sound] BLOCK_NOTE_PLING'
  - '[subtitle] &aYou have received a reward!'
#
# Variants for this reward can be added here,
# if you don't want any, delete the variants section
#
# Which variant will be available for player depends on permission
# You can add as many variants you want
#
variants:
  premium:
    permission: ultimaterewards.exampleAreaAfkReward.premium
    actions:
      80:
        - '[console] give %player% gold_ingot 1'
        - '[subtitle] &eYou have received a premium reward!'
      20:
        - '[console] give %player% gold_ingot 1'
        - '[firework] colors:{FF0000;00FF00;0000FF},type:BALL_LARGE,power:3'
        - '[message] &6&lWOW! You are a lucky player, received 1 diamond!'
        - '[console] give %player% diamond 1'
PreviousAfk RewardNextArea Afk Reward

Last updated 5 months ago