Why won't my analyzing script work?
I am trying to make a script that will cycle through models and turn them into a certain material depending on what color it is. Right now I only have the script that will cycle through it, but it won't work. The error it gives me is " Argument 1 missing or nil." It is in a server script.
This is the code:
01 | local S = game.Workspace |
02 | local T = game.ServerStorage |
04 | local P = S:FindFirstChild() |
05 | if P:IsA( "Model" ) then |
09 | P:FindFirstChild() = = nil |
13 | local C = P:FindFirstChild() |
20 | T.Analyzing:FindFirstChild() = = nil |
22 | C.Parent = T.Analyzing |
26 | local R = T.Analyzing:FindFirstChild() |
32 | local M = T.Analyzed:FindFirstChild() |
41 | S:FindFirstChild() = = nil |
46 | T.Analyzed:FindFirstChild() = = nil |
Edit: I know it won't change the material yet since I have not coded it in yet. I am just trying to see if it will move the materials to the holding folder.