--The resources produced from a gunchunks workbench, somewhat cleverly condensed here. local materials = { "Copper", "Iron", "Tech", "Silver", "Gold", "Steel", "Platinum", } local gunparts = { "Gunslide", "Gunbarrel", "Gungrip", "Gunmagazine", "Weapon Scope", "Reflex Scope", } for k,v in pairs(materials) do for i,j in pairs(gunparts) do local ITEM = {} ITEM.Name = v .. " " .. j ITEM.Description = "A part of a weapon!" local filename = string.Replace(v .. " " .. j," ","_") local directory = "items/weaponparts/" .. filename .. ".png" print("File for " .. ITEM.Name .. " is " .. directory) ITEM.Icon = directory ITEM.UniqueData = false genericMakeDroppable(ITEM) GMS.RegisterResource(ITEM) end end