Add filter to round gold > 999 to nearest thousand
This commit is contained in:
@@ -13,4 +13,9 @@ angular.module('habitrpg')
|
||||
return function(html){
|
||||
return $('<div/>').html(html).text();
|
||||
}
|
||||
})
|
||||
.filter('goldRoundThousandsToK', function(){
|
||||
return function (gp) {
|
||||
return (gp > 999) ? (Math.floor(gp / 100) / 10.0 + 'K') : gp;
|
||||
}
|
||||
})
|
||||
Reference in New Issue
Block a user