Hello everyone!
so recently I’ve been working on scripting GUI’s, and I came across an issue.
so I made a script that clones a group of tools from ReplicatedStorage and put it inside the player’s Backpage, but since Gui’s only works with local scripts, it was a result of this (Look at {Local Error}).
as you can tell, the tools ONLY show’s locally, which means that only the player that pressed the button in the GUI will be able to see the tools that he’s holding, while other players cant.
I can’t think of any way to fix this issue, I mean, I tried using normal scripts with GUI but of course, that won’t work.
-- local script
local Player = game.Players.LocalPlayer
script.Parent.MouseButton1Click:Connect(function()
for i,v in pairs(game.ReplicatedStorage.RPTools:GetChildren()) do
local RPS = v:Clone()
RPS.Parent = Player.Backpack
end
script.Parent.Image = "http://www.roblox.com/asset/?id=5936753015"
script.Parent.Remover.Disabled = false
script.Disabled =true
end)
I hope there is a solution to this, thanks for your time.