static keys - items in inventory will save their assigned key
precursor to cleaning up/modularising inventory display, instead of needing to iterate through every item held to find unique copies, we can just check if the button pressed corresponds to any entity's Key {} index
This commit is contained in:
parent
a7b4f621fb
commit
d11971126c
19 changed files with 445 additions and 122 deletions
|
|
@ -5,7 +5,7 @@
|
|||
"renderable": { "glyph": "!", "fg": "#FF00FF", "bg": "#000000", "order": 4 },
|
||||
"weight": 1,
|
||||
"value": 50,
|
||||
"flags": ["CONSUMABLE", "DESTRUCTIBLE"],
|
||||
"flags": ["CONSUMABLE", "DESTRUCTIBLE", "STACKABLE"],
|
||||
"effects": { "heal": "4d4+2" },
|
||||
"magic": { "class": "uncommon", "naming": "potion" }
|
||||
},
|
||||
|
|
@ -15,7 +15,7 @@
|
|||
"renderable": { "glyph": "!", "fg": "#FF00FF", "bg": "#000000", "order": 4 },
|
||||
"weight": 1,
|
||||
"value": 25,
|
||||
"flags": ["CONSUMABLE", "DESTRUCTIBLE"],
|
||||
"flags": ["CONSUMABLE", "DESTRUCTIBLE", "STACKABLE"],
|
||||
"effects": { "heal": "2d4+2" },
|
||||
"magic": { "class": "uncommon", "naming": "potion" }
|
||||
},
|
||||
|
|
@ -401,7 +401,7 @@
|
|||
"renderable": { "glyph": "%", "fg": "#FFA07A", "bg": "#000000", "order": 4 },
|
||||
"weight": 1,
|
||||
"value": 1,
|
||||
"flags": ["FOOD", "CONSUMABLE"]
|
||||
"flags": ["FOOD", "CONSUMABLE", "STACKABLE"]
|
||||
},
|
||||
{
|
||||
"id": "food_apple",
|
||||
|
|
@ -409,6 +409,6 @@
|
|||
"renderable": { "glyph": "%", "fg": "#00FF00", "bg": "#000000", "order": 4 },
|
||||
"weight": 0.5,
|
||||
"value": 1,
|
||||
"flags": ["FOOD", "CONSUMABLE"]
|
||||
"flags": ["FOOD", "CONSUMABLE", "STACKABLE"]
|
||||
}
|
||||
]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue