Browse Source

fixes #800

tags/v0.3.0
Big Bad Waffle 5 years ago
parent
commit
acc91d7b51
2 changed files with 6 additions and 4 deletions
  1. +1
    -0
      src/client/js/components/inventory.js
  2. +5
    -4
      src/client/ui/templates/inventory/inventory.js

+ 1
- 0
src/client/js/components/inventory.js View File

@@ -37,6 +37,7 @@ define([
rerender = (
(findItem.pos !== nItem.pos) ||
(findItem.eq !== nItem.eq) ||
(findItem.quickSlot !== nItem.quickSlot) ||
(findItem.quantity !== nItem.quantity)
);
}


+ 5
- 4
src/client/ui/templates/inventory/inventory.js View File

@@ -269,7 +269,7 @@ define([
},
quickSlot: {
text: 'quickslot',
callback: this.performItemAction(this, item, 'setQuickSlot')
callback: this.performItemAction.bind(this, item, 'setQuickSlot')
},
activate: {
text: 'activate',
@@ -312,9 +312,10 @@ define([
config.push(menuItems.learn);
else if (item.type === 'mtx')
config.push(menuItems.activate);
else if ((item.type === 'toy') || (item.type === 'consumable')) {
else if (item.type === 'toy' || item.type === 'consumable') {
config.push(menuItems.use);
config.push(menuItems.quickSlot);
if (!item.has('quickSlot'))
config.push(menuItems.quickSlot);
} else if (item.slot) {
config.push(menuItems.equip);
if (!item.eq)
@@ -586,7 +587,7 @@ define([
if (['equip', 'setQuickSlot'].includes(action)) {
cpn = 'equipment';

if (action === 'quickSlot') {
if (action === 'setQuickSlot') {
data = {
itemId: item.id,
slot: 0


Loading…
Cancel
Save