mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-03 08:21:07 +00:00
fix(shop): Enable head accessories
This commit is contained in:
parent
e2b1083088
commit
ae25af7c02
2 changed files with 4 additions and 2 deletions
|
|
@ -522,6 +522,8 @@
|
|||
"bodySpecialSummerHealerText": "Coral Collar",
|
||||
"bodySpecialSummerHealerNotes": "A stylish collar of live coral! Confers no benefit. Limited Edition 2014 Summer Gear.",
|
||||
|
||||
"headAccessory": "head accessory",
|
||||
|
||||
"headAccessoryBase0Text": "No Head Accessory",
|
||||
"headAccessoryBase0Notes": "No Head Accessory.",
|
||||
|
||||
|
|
|
|||
|
|
@ -108,8 +108,8 @@ habitrpg.controller("InventoryCtrl",
|
|||
|
||||
var gems = User.user.balance * 4;
|
||||
|
||||
var string = (type == 'weapon') ? window.env.t('weapon') : (type == 'armor') ? window.env.t('armor') : (type == 'head') ? window.env.t('headgear') : (type == 'shield') ? window.env.t('offhand') : (type == 'hatchingPotions') ? window.env.t('hatchingPotion') : (type == 'eggs') ? window.env.t('eggSingular') : (type == 'quests') ? window.env.t('quest') : (item.key == 'Saddle') ? window.env.t('foodSaddleText').toLowerCase() : type; // this is ugly but temporary, once the purchase modal is done this will be removed
|
||||
if (type == 'weapon' || type == 'armor' || type == 'head' || type == 'shield') {
|
||||
var string = (type == 'weapon') ? window.env.t('weapon') : (type == 'armor') ? window.env.t('armor') : (type == 'head') ? window.env.t('headgear') : (type == 'shield') ? window.env.t('offhand') : (type == 'headAccessory') ? window.env.t('headAccessory') : (type == 'hatchingPotions') ? window.env.t('hatchingPotion') : (type == 'eggs') ? window.env.t('eggSingular') : (type == 'quests') ? window.env.t('quest') : (item.key == 'Saddle') ? window.env.t('foodSaddleText').toLowerCase() : type; // this is ugly but temporary, once the purchase modal is done this will be removed
|
||||
if (type == 'weapon' || type == 'armor' || type == 'head' || type == 'shield' || type == 'headAccessory') {
|
||||
if (gems < ((item.specialClass == "wizard") && (item.type == "weapon")) + 1) return $rootScope.openModal('buyGems');
|
||||
var message = window.env.t('buyThis', {text: string, price: ((item.specialClass == "wizard") && (item.type == "weapon")) + 1, gems: gems})
|
||||
if($window.confirm(message))
|
||||
|
|
|
|||
Loading…
Reference in a new issue