Error: ServerScriptService.dataStore:69: bad argument #2 (number expected, got Object) table.remove(playersPlaying, Simon)
local playersPlaying = require(game.ServerScriptService.ModuleScript)
workspace.Part.Touched:Connect(function(hit)
if hit.Parent:FindFirstChild("Humanoid") then
table.insert(playersPlaying, hit.Parent)
wait(2)
print("Killing players")
for i, v in ipairs(playersPlaying) do
print("Choosing random player")
local Simon = playersPlaying[math.random(1, #playersPlaying)]
print("Random player is: "..Simon.Name)
for i=0, 4 do
print(i)
i = i - 1
wait(1)
end
table.remove(playersPlaying, Simon)
print(v)
end
end
end)

1 comment
Can you add me discord Aft3rL1fe#8610 when we fix the problem, we will post the answer