So, im in the middle of making a simulator and I kept running to this same issue. The object is to lift and when they user lifts a line is sent to my output saying “Datastore request was added to queue. If request queue fulls, further requests will be dropped. Try sending fewer request.key = (numbers)”
There’s no datastore in that script, so I don’t believe that fully affects it. Do you possibly do :SetAsync() every time the value changes? Or if you could include your leaderboard script too that could help.
Sorry, that was the wrong thing let me get my Datastore.
local serverStorage = game:GetService(“ServerStorage”)
local DataStore = game:GetService(“DataStoreService”):GetDataStore(“PlayerSave3”)
game.Players.PlayerAdded:Connect(function(player)
local leaderstats = Instance.new("Folder")
leaderstats.Name = "leaderstats"
leaderstats.Parent = player
local strength = Instance.new("NumberValue")
strength.Name = "Strength"
strength.Parent = leaderstats
local rebirths = Instance.new("IntValue")
rebirths.Name = "Rebirths"
rebirths.Parent = leaderstats
local coins = Instance.new("DoubleConstrainedValue",leaderstats)
coins.Name = "Coins"
coins.Parent = leaderstats
coins.MinValue = 0
coins.MaxValue = 100000000
local dataFolder = Instance.new("Folder")
dataFolder.Name = player.Name
dataFolder.Parent = serverStorage.RemoteData
local debounce = Instance.new("BoolValue")
debounce.Name = "Debounce"
debounce.Parent = dataFolder
local strengthData, rebirthsData
local success,errormessage = pcall (function()
strengthData = DataStore:GetAsync("strength--"..player.UserId)
rebirthsData = DataStore:GetAsync("rebirths--"..player.UserId)
end)
if success then
if strengthData then
strength.Value = strengthData
rebirths.Value = rebirthsData
end
end
end)
game.Players.PlayerRemoving:Connect(function(player)
local success, errormessage = pcall(function()
DataStore:SetAsync(“strength–”…player.UserId,player.leaderstats.Strength.Value)
DataStore:SetAsync(“rebirths–”…player.UserId,player.leaderstats.Rebirths.Value)
In all honesty, this shouldn’t fill the queue that much. Double check to make sure that Studio access to API services is enabled in game settings, and see how often the :SetAsync() functions are called. This will resolve your issue most likely.