[{"data":1,"prerenderedAt":145},["ShallowReactive",2],{"class-doc-/reference/2.0/gg_inventory/ggitemtype":3,"navigation":73},{"_path":4,"_dir":5,"_draft":6,"_partial":6,"_locale":7,"_id":8,"navigation":6,"addon":5,"version":9,"brief_description":10,"description":11,"tutorials":7,"methods":12,"members":35,"signals":65,"constants":66,"inherits":67,"name":68,"title":68,"_source":69,"_file":70,"_stem":71,"_extension":72},"/reference/2.0/gg_inventory/ggitemtype","gg_inventory",false,"","content:40.reference:2.0:gg_inventory:GGItemType.xml","2.0","Represents a type of inventory item and defines shared item properties.","Item types describe the properties shared by all instances of a particular type of item. An instance of an item type is represented by the [GGItemData] class.  For example, the [member name] and [member image] that represent the item type.[br][br]Some item types may be [member stackable], up to a specific [member stack_size]. They may also have a [member weight].[br][br]This class should be extended by your game to describe additional properties you may need. For example:\n[codeblock]\nclass_name MyCustomItemType extends GGItemType\n\n# The item description that will be shown to players on the item detail screen\nvar description: String = \"\"\n\n# Determines whether this type of item can be equipped.\nvar equippable: bool = false\n[/codeblock]",[13,22,27,31],{"description":14,"name":15,"public":16,"returnType":17,"params":18},"Creates and returns a new instance of the item type. The [param properties] can be used to set any properties on the [GGItemData] instance. Example:\n[codeblock]\nmy_item_data = my_item_type.create_item({ quantity = 2 })\n[/codeblock]","create_item",true,"GGItemData",[19],{"name":20,"type":21},"properties","Dictionary",{"description":23,"name":24,"public":16,"returnType":25,"params":26},"Wether instances of this item can be stacked with other instances of the same type.","is_stackable","bool",[],{"description":28,"name":29,"public":6,"returnType":17,"params":30},"Override to determine which class is use to represent the [GGItemData]. Example:\n[codeblock]\nfunc _factory_class() -> GGItemData:\n    return MyCustomItemData.new()\n[/codeblock]","_factory_class",[],{"description":7,"name":32,"public":6,"returnType":33,"params":34},"_to_string","String",[],[36,41,45,48,51,56,61],{"name":37,"description":38,"type":39,"setter":7,"getter":7,"default":40,"public":16},"icon","Represents the item visually.[br][br]This is, for example, used by the [GGInventorySlotItemUI].","Texture2D","null",{"name":42,"description":43,"type":33,"setter":7,"getter":7,"default":44,"public":16},"name","The name of the item.","\"\"",{"name":46,"description":47,"type":33,"setter":7,"getter":7,"default":44,"public":16},"description","The description of the item.",{"name":49,"description":23,"type":25,"setter":7,"getter":7,"default":50,"public":16},"stackable","false",{"name":52,"description":53,"type":54,"setter":7,"getter":7,"default":55,"public":16},"stack_size","The maximum stack size for this item.","int","0",{"name":57,"description":58,"type":59,"setter":7,"getter":7,"default":60,"public":16},"weight","How much this type of item weighs. Used by [method GGInventory.item_weight] to calculate the weight of all items.","float","0.0",{"name":62,"description":63,"type":64,"setter":7,"getter":7,"public":16},"audio","The audio to use when interacting with the item.","GGItemAudio",[],[],"Resource","GGItemType","content","40.reference/2.0/gg_inventory/GGItemType.xml","40.reference/2.0/gg_inventory/GGItemType","xml",[74,83,110,130],{"title":75,"_path":76,"children":77},"Getting Started","/getting-started",[78,80],{"title":79,"_path":76},"Introduction",{"title":81,"_path":82},"Installation","/getting-started/installation",{"title":84,"_path":85,"children":86},"Concepts","/concepts",[87,89,92,95,98,101,104,107],{"title":88,"_path":85},"Overview",{"title":90,"_path":91},"Inventory","/concepts/inventory",{"title":93,"_path":94},"Interactions","/concepts/interaction",{"title":96,"_path":97},"Permissions","/concepts/permissions",{"title":99,"_path":100},"Multiplayer","/concepts/multiplayer",{"title":102,"_path":103},"User Interface","/concepts/user-interface",{"title":105,"_path":106},"Game Integration","/concepts/game-integration",{"title":108,"_path":109},"Crafting","/concepts/crafting",{"title":111,"_path":112,"children":113},"Demos","/demos",[114,116,119,122,124,127],{"title":115,"_path":112},"Inventory Tour",{"title":117,"_path":118},"Inventory UI Playground","/demos/inventory_ui",{"title":120,"_path":121},"Inventory Game UI","/demos/inventory_game_ui",{"title":108,"_path":123},"/demos/crafting",{"title":125,"_path":126},"Multiplayer Lobby","/demos/mp_lobby",{"title":128,"_path":129},"Sequencer (prototype)","/demos/sequencer",{"title":131,"_path":132,"children":133},"Guide","/guide",[134,136,139,142],{"title":135,"_path":132},"Architecture Deep Dive",{"title":137,"_path":138},"Design Principles","/guide/design-principles",{"title":140,"_path":141},"Changelog v2.x","/guide/changelog-v2",{"title":143,"_path":144},"Changelog v1.x","/guide/changelog",1743268974405]