RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"create a script inside a tool that will make it stackable in player backpack"
-- local script inside the tool local tool = script.Parent local players = game:GetService("Players") local player = players.LocalPlayer local backpack = player:WaitForChild("Backpack") local toolName = tool.Name local function onEquipped() local toolsInBackpack = 0 for _, item in ipairs(backpack:GetChildren()) do if item.Name == toolName then toolsInBackpack = toolsInBackpack + 1 end end if toolsInBackpack > 1 then tool:Destroy() local newTool = game.ServerStorage[toolName]:Clone() newTool.Parent = backpack end end tool.Equipped:Connect(onEquipped)