I'm trying to make it like a party system where certain players don't get damaged but it doesn't work. IDK why ve been trying different things for 45 mins or so and I'm lost.
script.Parent.Touched:Connect(function(hit)
print("TOUCHED")
local nokill = {"hellericc","TestSub"}
for i,v in pairs(nokill) do
local x = Instance.new("StringValue",game.Workspace.Xhels)
x.Name = v
print(nokill)
if hit.Parent == v.Name then
print(hit.Parent)
else
wait(1)
print("Killing")
hit:Destroy()
end
end
end)

2 comments
Are you sure you didn't misspell your name in the nokill table, because other than it should be working.
no i did not misspell anything i'm using a different account to make the script