correctly award ultimategear achievement

This commit is contained in:
Matteo Pagliazzi
2013-10-27 12:11:59 +01:00
parent 39e37e1404
commit a5af52a275
3 changed files with 7 additions and 25 deletions

View File

@@ -37,7 +37,11 @@ habitrpg.controller('NotificationCtrl',
$rootScope.modals.achievements.streak = true;
});
// FIXME: this isn't working for some reason
$rootScope.$watch('user.achievements.ultimateGear', function(after, before) {
if (after === before || after !== true) return;
$rootScope.modals.achievements.ultimateGear = true;
});
/*_.each(['weapon', 'head', 'chest', 'shield'], function(watched){
$rootScope.$watch('user.items.' + watched, function(before, after){
if (after == before) return;