Hey, I am trying to remove a number value from a table. It is 100% in the table. It also gives no error.

Script with problem:

local DS2 = require(script.Parent.DataStore2)
game.ReplicatedStorage.Delete.OnServerEvent:Connect(function(plr,id)
	local DataStore = DS2("gamelibrary",plr)
	local games = DataStore:Get({game.PlaceId})
	print(id)
		table.remove(games,id)
		DataStore:Set(games)
		game.ReplicatedStorage.Refresh:FireClient(plr,games)
end)

LocalScript that calls the event:

script.Parent.Activated:Connect(function()
	script.Parent.Visible = false
	game.ReplicatedStorage.Delete:FireServer(script.Parent.Parent.GameID.Value)
end)

2 comments

0

this doesnt look like the entire script, could you include that as well?

0

It is the whole script, but I could add the local script too.