Hi, I'm a novice in scripting, and I am in need of help qq
Right now I am trying to create a script that would only allow certain players in the said script to spawn with these set of tools, so far this is what I got:
if game.Players.LocalPlayer.Name == "kevincatssing" then
game.ServerStorage:GetChildren()
for i, v in pairs(x) do
v:Clone().Parent = game.Players["kevincatssing"].Backpack
end
end
I am planning to place the script in StarterGui
Please aid qq

15 comments
you are comparing the player's "name" to table "admin"
fixed.
Alright, I will try this now, thank you :D and for multiple 'admin', I just have to {"Name1", "Name2"}?
If this helped do mind accepting Answer. Thanks!
I will :D! And, in ReplicatedStorage, there is also other things besides the tools that I am placing in there, how do I make it so that it will only clone the Tools (Which consist of HopperBin and Tool, in their ClassName) only?
??
Clone tools only?
Yes, only the Tools, which consist of HopperBin and Tool, because there is also a few scripts in there that I don't want to copy over to the user's Backpack
I edited my answer.
Oh, so, on line 7, I just need to add a value for HopperBin too, besides the Tool? if value:IsA("Too", "HopperBin") then?? QQ
No no...I'll edit my answer.
Thank you so much :D
np.
Ahh... Thanks for the downvote, and I was told that A localscript can't access a ServerStorage, People aren't always correct.
I'm stupid, sorry. You're right.