So, I’m trying to clone a script, and parent it to proximityPrompts. Well, it ain’t working, but the way I typed the code was the same way I did many other times and it worked, cloning to all the parts indentified with the given info, and without any errors.
I tried to delete and type it again and again but no success. And also I didn’t find any articles who could answer it properly.
Maybe this is a silly issue with me, or maybe how the script is typed, but I would like to understading what’s happening, cuz it may be useful in the future.
This is two different lines of codes that I’ve written in command bar:
-- local newscript = game.ServerStorage.OilCansSS:FindFirstChild("SSFinder") for _,v in ipairs(game.ServerStorage.OilCansSS:GetDescendants()) do if v:IsA("ProximityPrompt") then newscript:Clone() newscript.Parent = v end end
-- local newscript = game.ServerStorage.OilCansSS:FindFirstChild("SSFinder"):Clone() for _,v in ipairs(game.ServerStorage.OilCansSS:GetDescendants()) do if v:IsA("ProximityPrompt") then newscript.Parent = v end end
SSFinder is the script that I want to clone, and the P.P.s are inside the parts/meshes/unions

Tested it and the SSFinder is being cloned, but only parented to one part
