local player = game.Players:FindFirstChild(script.Parent.name.Value) if (game.Workspace:FindFirstChild(script.Parent.name.Value).Torso.Position - game.Workspace:FindFirstChild(script.Parent.name.Value.. "'s Cop").Torso.Position).magnitude < 100 then script.Parent.Active.Disabled = false script.Parent.NonActive.Disabled = true else if (game.Workspace:FindFirstChild(script.Parent.name.Value).Torso.Position - game.Workspace:FindFirstChild(script.Parent.name.Value.. "'s Cop").Torso.Position).magnitude > 100 then script.Parent.Active.Disabled = true script.Parent.NonActive.Disabled = false end end
this script will not work i dont know what is wrong with it. in the output it says Workspace.touchme.Script:2: attempt to index a nil value