💶 Exchange Setup
CoinsEngine allows your players to exchange one currency for another!
Setup:
Let's assume we have 2 currencies: Gems and Coins, where: 1 Gem = 5 Coins.
In /currencies/gems.yml config file go to Exchange
-> Rates
section and set it to:
In the code above, coins
is the name of a currency that Gems can be exchanged for, and the 5
is amount of exchanged currency per 1 gem.
Do the same for /currencies/coins.yml config file:
0.2
is because it's exchange amount per 1 coin, so 5 coins will result in 1 gem.
Last updated