mirror of
https://github.com/NLthijs48/AreaShop.git
synced 2025-02-18 04:41:29 +01:00
Updated Frequently Asked Questions (markdown)
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.
|
Loading…
Reference in New Issue
Block a user