#ifndef EDITSCENE_ITEM_HPP
#define EDITSCENE_ITEM_HPP
#pragma once

#include <Ogre.h>
#include <string>

/**
 * Item reference component.
 *
 * Attached to a world entity that represents a pickable / interactable item.
 * All item properties (name, type, weight, etc.) are stored in
 * the ItemRegistry singleton and looked up by itemId.
 *
 * action:     Optional GOAP action name to execute on interact (E key).
 *             If empty, the item is picked up into inventory.
 * instanceId: Optional unique ID for global state tracking (save/load).
 * disabled:   Set to true when the item has been picked up / consumed.
 */
struct ItemComponent {
	// Registry key for this item definition
	Ogre::String itemId;

	// Stack size for this world entity
	int stackSize = 1;

	// Optional action to execute on interact (instead of pickup)
	Ogre::String action;

	// Unique instance ID for global state tracking
	Ogre::String instanceId;

	// True when item has been picked up or consumed
	bool disabled = false;

	ItemComponent() = default;

	explicit ItemComponent(const Ogre::String &id, int stack = 1)
		: itemId(id)
		, stackSize(stack)
	{
	}
};

#endif // EDITSCENE_ITEM_HPP
