Items
Items are the most basic building block of a game. They are the things that players can pick up, use, and interact with. Since this is a very broad category, this file will focus only on how to create core item data.
Relevant Files
Client
- None
Server
- DataModule -
src\ServerStorage\Modules\Data\DataModule\init.lua - Data types -
src\ServerStorage\Modules\Data\DataModule\DataTypes.lua
Data
- Item icon data -
src\ReplicatedStorage\Modules\Data\ItemIconData.lua - Item data -
src\ServerStorage\Data\DataTypes - Item description data -
src\ReplicatedStorage\Modules\Data\ItemDescriptionData.lua
Shared
- Item pack format -
src\ReplicatedStorage\Modules\Data\PackFormats\ItemPackFormat.lua - Inventory item pack format -
src\ReplicatedStorage\Modules\Data\PackFormats\InventoryPackFormat.lua
Minimum Requirements For Creating an Item
- An
ItemData_ItemNamefile in thesrc\ServerStorage\Data\DataTypesfolder, placed in the appropriate data type folder. - Optional an
ItemNamefield in thesrc\ReplicatedStorage\Modules\Data\ItemDescriptionData.luafile. - Optional An
ItemNamefield in thesrc\ReplicatedStorage\Modules\Data\ItemIconData.luafile.
Minimum Requirements For Adding an Item Type
- An
ItemTypefolder in thesrc\ServerStorage\Data\DataTypesfolder. - A data type and typecheck in the
src\ServerStorage\Modules\Data\DataModule\DataTypes.luafile. - A pack format in the
src\ReplicatedStorage\Modules\Data\PackFormats\ItemPackFormat.luafile.