Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Script wont be cloned and put into Character what do I do?

Asked by 3 years ago

So I have a First-Person script that when a player enters 1st person it should delete a script inside of the Character(and it does that), but when the player leaves First-Person the same script in a folder in ServerStorage should be cloned and put into the character but it does not do that and I get the warningInfinite yield possible on 'ServerStorage:WaitForChild("Scripts")' whats the problem?

game.ServerStorage:WaitForChild("Scripts").HeadTurning:Clone().Parent = Character --this is the line that causes the warning and does not work at all.

1 answer

Log in to vote
0
Answered by 3 years ago

Is the Script in question, (the Script from which this excerpt was taken from) a LocalScript? LocalScripts cannot access ServerStorage, hence the difference between LocalScript (local) and Script (server).

0
Where do you suggest I put it? vincentthecat1 199 — 3y
0
If you want a place to store the folder where the client can access it, I would recommend ReplicatedStorage. appxritixn 2235 — 3y
0
I would recommend moving your folder to ReplicatedStorage, as phxntxsmic has already suggested. efficacies 180 — 3y
Ad

Answer this question