i only read the data when player joins
Is this occurring with only one player in the game? Or is it possible that there are multiple players sending the request to the same DataStore?
EDIT:
With only 5 datastore requests per user per 3 minutes this shouldn’t be a problem anyway.
so far its only happening to one person, but only like 3 peeople have played the game so far
Is there any chance that it is saving faster than 3 minutes, even though you only intend for it to save every 3 minutes?
i dont think so, it should save once per 180 seconds and when player leaves
The message you are getting is the message that usually occurs when DataStores are being accessed too quickly or too many times. There is a delay between write requests which may actually be the issue you are having (see here: How to avoid flooding DB queries - Help and Feedback / Scripting Support - DevForum | Roblox).
60 + numplayers x10 that is 60 + 20 because there were 2 players, im pretty sure i didnt sendd 80 requests wtf
That is the total requests made per server. However, there is a 6 second delay between writing to the same key. If you are trying to write to the same key twice in a script in quick succession (less than 6 seconds), you might get that message.
do u mean if i save info to the same data store in the same time?
Yes that would cause it. If you notice in the screenshot each message has a key attached to it, and the keys are identical for each message.
should i ddelete the autosave? everything has stopped working since i have added it.
Not necessarily, it can be a good idea to save data periodically. It’s worth noting that that message does not mean that nothing is being saved, it just means that a request was added to a queue. Unfortunately, I cannot really tell you what your issue is exactly, without seeing your script.
wait, it says theres a 6 second delay between saving, so should i do something like this?
save info in datastore 1
wait 6 seconds
save info in datastore 2
wait 6 seconds
save info in datastore 3
wait 6 seconds
save info in datastore 4
wait 6 seconds
save info in datastore 5
That would work if they are using the same key, yes. But if you are accessing a different key each time, that might not be where the issue is occurring.
there are 5 data stores in my game, and when the player leaves they all save info in the same time
but if i add a 6 second cooldown betwen each of them it will be like 30 seconds, the server could already shutdown in this time or someone else could join and claim their plot and everything would break
What key is each DataStore using?
the same one which is plr.UserId
should i change the key for each data store?
like plr.UserId…“Plots”
plr.UserId…“Inventory”
plr.UserId…“Structures”
etc. ?
If the issue is what I think it is, that would probably fix it. I really cannot say without seeing a script or a portion of a script though.
ok ill try that and tell the guy with the issue to test it out