'use strict'; const ITEMS = [ { id: 'healing_potion', name: 'Healing Potion', type: 'consumable', description: 'Restores 1 heart.', color: '#FF69B4', stackable: true, value: 0 }, { id: 'super_potion', name: 'Super Potion', type: 'consumable', description: 'Restores 3 hearts.', color: '#FF1493', stackable: true, value: 0 }, { id: 'magic_potion', name: 'Magic Potion', type: 'consumable', description: 'Restores magic power.', color: '#9400D3', stackable: true, value: 0 }, { id: 'heart_piece', name: 'Heart Piece', type: 'consumable', description: 'Permanently increases max HP by 1/4 heart.', color: '#FF0000', stackable: false, value: 0 }, { id: 'arrow', name: 'Arrow', type: 'material', description: 'Ammunition for the Bow.', color: '#8B4513', stackable: true, value: 0 }, { id: 'bomb', name: 'Bomb', type: 'material', description: 'Explodes on impact. Destroys walls.', color: '#8B4513', stackable: true, value: 0 }, { id: 'key', name: 'Key', type: 'key', description: 'Opens locked doors.', color: '#FFD700', stackable: true, value: 0 }, { id: 'small_key', name: 'Small Key', type: 'key', description: 'Opens chests and small doors.', color: '#DAA520', stackable: true, value: 0 }, { id: 'rupee_green', name: 'Green Rupee', type: 'currency', description: 'Worth 1 rupee.', color: '#00FF00', stackable: true, value: 1 }, { id: 'rupee_blue', name: 'Blue Rupee', type: 'currency', description: 'Worth 5 rupees.', color: '#0000FF', stackable: true, value: 5 }, { id: 'rupee_red', name: 'Red Rupee', type: 'currency', description: 'Worth 20 rupees.', color: '#FF0000', stackable: true, value: 20 }, { id: 'rupee_yellow', name: 'Yellow Rupee', type: 'currency', description: 'Worth 100 rupees.', color: '#FFD700', stackable: true, value: 100 }, { id: 'magic_crystal', name: 'Magic Crystal', type: 'material', description: 'Used to power magic weapons.', color: '#E0FFFF', stackable: true, value: 0 } ]; function getItem(id) { return ITEMS.find(i => i.id === id); } if (typeof module !== 'undefined' && module.exports) { module.exports = { ITEMS, getItem }; }