Why doesn't this script work?
02 | if script.Parent.Parent.TeamColor = = BrickColor.new( "Black" ) then |
03 | if workspace:FindFirstChild(script.Parent.Parent.Name):FindFirstChild( "Shirt" ) = = nil then |
04 | if workspace:FindFirstChild(script.Parent.Parent.Name):FindFirstChild( "Pants" ) ~ = nil then |
05 | workspace:FindFirstChild(script.Parent.Parent.Name).Pants:remove() |
06 | a = Instance.new( "Shirt" ) |
08 | a.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
09 | b = Instance.new( "Pants" ) |
11 | b.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
13 | a = Instance.new( "Shirt" ) |
15 | a.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
16 | b = Instance.new( "Pants" ) |
18 | b.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
21 | if workspace:FindFirstChild(script.Parent.Parent.Name):FindFirstChild( "Pants" ) ~ = nil then |
22 | workspace:FindFirstChild(script.Parent.Parent.Name).Shirt:remove() |
23 | workspace:FindFirstChild(script.Parent.Parent.Name).Pants:remove() |
24 | a = Instance.new( "Shirt" ) |
26 | a.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
27 | b = Instance.new( "Pants" ) |
29 | b.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
31 | workspace:FindFirstChild(script.Parent.Parent.Name).Shirt:remove() |
32 | a = Instance.new( "Shirt" ) |
34 | a.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
35 | b = Instance.new( "Pants" ) |
37 | b.Parent = workspace:FindFirstChild(script.Parent.Parent.Name) |
It's putted in startergui, and It should work. WHy doesn't it?