6. Taxation System - Tylwen/ShopGUIPlus-DynaShop GitHub Wiki
The plugin includes a flexible taxation system that automatically applies a tax percentage to all transactions. The collected taxes can be sent to a player account, a system account, or simply removed from the economy.
# Tax system configuration
tax:
enabled: false
# Destination mode for taxes: "player", "system" or "remove"
# player: Sends the tax to a real player (must have played on the server)
# system: Sends the tax to a system account (works even if it's not a real player)
# remove: Simply removes the money from the economy (does not assign it to anyone)
mode: "system"
# Name of the player or account who will receive the taxes
receiver: "DynaShopBank"
# Percentage of tax applied on purchases
buy-rate: 5.0
# Percentage of tax applied on sales
sell-rate: 3.0
# Log transactions in the console
log-transactions: true
- When a player makes a transaction (buy or sell), a percentage of the price is deducted as tax.
- The tax amount is calculated based on the
buy-rate
(for purchases) orsell-rate
(for sales). - The tax is then:
- Sent to a real player's account (if
mode
is "player") - Sent to a system account (if
mode
is "system") - Simply removed from the economy (if
mode
is "remove")
- Sent to a real player's account (if
- The player receives a message indicating the tax amount and destination.
- If
log-transactions
is enabled, all tax transactions are logged in the console.
Example 1: Bank account
tax:
enabled: true
mode: "system"
receiver: "ServerBank"
buy-rate: 5.0
sell-rate: 2.0
log-transactions: true
Example 2: Tax collector player
tax:
enabled: true
mode: "player"
receiver: "Tylwen"
buy-rate: 7.5
sell-rate: 3.5
log-transactions: true
Example 3: Economic sink (just removes money)
tax:
enabled: true
mode: "remove"
receiver: "Treasury" # This is just for the message, money is not sent anywhere
buy-rate: 3.0
sell-rate: 1.0
log-transactions: false