mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-07-16 03:01:59 +00:00
Fix bulk buying gems
This commit is contained in:
parent
8c61fa7950
commit
f34ec2724f
1 changed files with 1 additions and 1 deletions
|
|
@ -69,7 +69,7 @@ open class ShopItem : RealmObject() {
|
|||
get() = "pets" == purchaseType || "mounts" == purchaseType
|
||||
|
||||
val canPurchaseBulk: Boolean
|
||||
get() = "eggs" == purchaseType || "hatchingPotions" == purchaseType || "food" == purchaseType
|
||||
get() = "eggs" == purchaseType || "hatchingPotions" == purchaseType || "food" == purchaseType || "gems" == purchaseType
|
||||
|
||||
fun canAfford(user: User?, quantity: Int): Boolean = when(currency) {
|
||||
"gold" -> (value * quantity) <= user?.stats?.gp ?: 0.0
|
||||
|
|
|
|||
Loading…
Reference in a new issue