forked from 2009Scape/Server
Fixed Bogrog spirit shard pouch exchange rounding
This commit is contained in:
parent
04ce0879c8
commit
ee88bfe3f0
1 changed files with 2 additions and 2 deletions
|
|
@ -7,6 +7,7 @@ import content.global.skill.summoning.SummoningPouch
|
|||
import content.global.skill.summoning.SummoningScroll
|
||||
import core.game.node.item.Item
|
||||
import core.game.world.map.zone.ZoneBorders
|
||||
import kotlin.math.ceil
|
||||
import kotlin.math.floor
|
||||
|
||||
/**
|
||||
|
|
@ -76,7 +77,6 @@ object BogrogPouchSwapper {
|
|||
if(item == null) item = SummoningPouch.get(SummoningScroll.forItemId(itemID)?.pouch ?: -1).also { isScroll = true }
|
||||
item ?: return 0.0
|
||||
var shardQuantity = item.items[item.items.size - 1].amount * 0.7
|
||||
if(isScroll) shardQuantity /= 20.0
|
||||
return shardQuantity
|
||||
return if(isScroll) shardQuantity / 20.0 else ceil(shardQuantity)
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue