-
Notifications
You must be signed in to change notification settings - Fork 1
Discord Economy
Dreamvisitor has an economy system. Users may purchase items from a shop using currency that can be used.
The shop consists of up to 25 items. Items have an ID, name, description, price, sale percent, quantity, and max allowed quantity. The ID is randomly chosen upon item creation. The name and description are chosen upon creation. The price represent the regular price of the item. It must not be negative. The sale percent is a number form 0 to 100 that represents the percent removed from the price. The quantity represents the number of items available in the shop (or infinity if -1). If the item is purchased, the quantity will be reduced by one. When at zero, the item can no longer be purchased. Max allowed quantity represents the maximum number of the item a user can hold in their inventory.
Items also have the following flags:
- enabled - Whether the item appears in the shop and can be purchased.
- giftingEnabled - Whether the item can be transferred by one user to another.
- useDisabled - Whether the item can be used.
- useOnPurchase - Whether the item is automatically used when purchased. Does not override useDisabled.
Items can do the any of following on use:
- Add roles
- Remove roles
- Add parent groups (requires LuckPerms)
- Remove parent groups (requires LuckPerms)
- Execute commands via the console
Users can gain currency by claiming daily rewards and working.
Users can claim a daily reward once every day. The current day changes at the system's midnight. If they claim their reward before the day after the day after their claim, they can build a streak. The daily reward is configured by dailyBaseAmount
and the steak multiplier is configured by dailyStreakMultiplier
in config.yml
.
Users can work once every hour. The work reward is configured by workReward
.