Updated Frequently Asked Questions (markdown)

Thijs Wiefferink 2017-12-08 12:16:07 +01:00
parent fdcc6e8fed
commit 2af93a6512

@ -239,6 +239,8 @@ mallshops:
```
### How can I use a price per square meter (m2) or per block (m3)?
*Added in AreaShop 2.5.0+ (current development builds)*
You can set a price using the region variables and complete JavaScript expressions (result of the last statement is used):
Charge $5 per square meter:
@ -246,9 +248,9 @@ Charge $5 per square meter:
price: '5*%width%*%depth%'
```
Charge $5 per block:
Charge $5 per block (`%volume%` properly calculates the blocks of odd shaped regions):
```yaml
price: '5*%width%*%depth%*%height%'
price: '5*%volume%'
```
You can put this in `default.yml`, a group in `groups.yml` or in a region file. You cannot set a price like this using `/as setprice` for security reasons.