improves rounding for boss hp and player pending damage - partial fix for #8368 (#9749)

* improves rounding for boss hp and player pending damage

* use floor filter function for user's pending damage for party page and tavern boss
This commit is contained in:
Alys
2018-03-31 20:57:37 +10:00
committed by Matteo Pagliazzi
parent bd07f3cd38
commit 338781f57b
4 changed files with 11 additions and 7 deletions

View File

@@ -55,10 +55,12 @@ div
.row.boss-details
.col-6
span.float-left
| {{parseFloat(group.quest.progress.hp).toFixed(2)}} / {{parseFloat(questData.boss.hp).toFixed(2)}}
| {{ Math.ceil(parseFloat(group.quest.progress.hp) * 100) / 100 }} / {{ parseFloat(questData.boss.hp).toFixed(2) }}
// current boss hp uses ceil so you don't underestimate damage needed to end quest
.col-6(v-if='userIsOnQuest')
// @TODO: Why do we not sync quset progress on the group doc? Each user could have different progress
span.float-right {{parseFloat(user.party.quest.progress.up).toFixed(1) || 0}} pending damage
// @TODO: Why do we not sync quest progress on the group doc? Each user could have different progress.
span.float-right {{ user.party.quest.progress.up | floor(10) }} {{ $t('pendingDamageLabel') }}
// player's pending damage uses floor so you don't overestimate damage you've already done
.row.rage-bar-row(v-if='questData.boss.rage')
.col-12
.grey-progress-bar