basically i have a ban datastore and a hacker banned like 60 players and i dont really have the time to search through all players to find the banned ones
how would i unban all players or make it print the players that are banned
if you know how, please do tell me because i am really stumped
local DataStoreService = game:GetService("DataStoreService")
local banDatastore = -- add datastore line here
local success, pages = pcall(function()
return banDatastore:ListKeysAsync(nil, 200, nil, true)
end)
if success then
local page = pages:GetCurrentPage()
for i, info in page do
local success, value = pcall(function()
return banDatastore:GetAsync(info.KeyName)
end)
if success then
print(`Key: {info.KeyName}, Value: {value}`)
end
--local success, value = pcall(function()
--return banDatastore:RemoveAsync(info.KeyName)
--end)
-- Uncomment to remove key from datastore
end
end