mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 07:37:25 +01:00
costumes: add costume support in inventory
This commit is contained in:
@@ -162,5 +162,10 @@ habitrpg.controller("InventoryCtrl", ['$rootScope', '$scope', 'User', 'API_URL',
|
||||
User.set('items.currentMount', (user.items.currentMount == mount) ? '' : mount);
|
||||
}
|
||||
|
||||
$scope.equip = function(user, item, costume) {
|
||||
var equipTo = costume ? 'costume' : 'equipped';
|
||||
User.set('items.gear.' + equipTo + '.' + item.type, item.key);
|
||||
}
|
||||
|
||||
}
|
||||
]);
|
||||
Reference in New Issue
Block a user