while wait() do
for i, v in pairs(workspace:GetChildren()) do
Human = v:FindFirstChild("Torso")
if Human then
print(v.Name)
vplayer = v.Torso
end
end
print((workspace.Part.Position - vplayer.Position).magnitude)
if workspace.Part.Position - vplayer.Position.magnitude < 50 then
print("yes")
end
end
Everytime I run this code, it says "Workspace.Part.Script:14: bad argument #2 to '?' (Vector3 expected, got number) 11:09:01.650 - Stack Begin"
I tried putting vector3 in the beginning but did not work.

1 comment
Thank you.