How can i make this gui give me tools if i click it, any help please?
Hi i have a script that removes your tools if you click this gui and it makes an image appear too and when you click the gui again the image will disappear but i want the tools that got removed to come back too. The problem is i really have no idea how to do that. Can someone please help me. Here is my script. (I'd like to get the tools i had in my inventory before instead of getting specific tools since my game has a shop and you can have 1-3 items at a time). Thanks :D
02 | f = script.Parent.Parent.EpixShop |
07 | script.Parent.ImageTransparency = 0.5 |
10 | for _,child in pairs (script.Parent.Parent.Parent.Parent.Backpack:GetChildren()) do |
11 | if child.ClassName = = "Tool" or child.ClassName = = "HopperBin" then |
12 | print ( "Removed " ..child.Name.. "!" ) |
15 | script.Parent.ImageTransparency = 0 |
23 | script.Parent.MouseButton 1 Down:connect(click) |