I made a suggestion thing for my game (not released yet). And i have this script for the send button-
can = true
DS = game:GetService("DataStoreService"):GetDataStore("Suggestion")
script.Parent.MouseButton1Click:Connect(function()
if can == true then
can = false
DS:SeyAsync(math.random(1,100),script.Parent.Parent.TextBox.Text)
script.Parent.Parent.TextBox.Text = ""
script.Parent.Parent.sent.Visible = true
wait(5)
script.Parent.Parent.sent.Visible = false
can = true
end
end)
this is the best i can think of. but the problem is the random number picking. if two people send something and both are 69 then the second one overrides the first. (dont worry i already made this button that prints to me a suggestion when a click a number or WHATEVER THAT PART IS COOL). so i tried id
DS:GetAsync(1) == not "slhfhgehkogbjahvhuahiwfj(random stuff)" then
print("stuff")--for debug
end
i know this had like nothing to do with it but still didnt print when it should have. the store want all that stuff. Pleas help :<

6 comments
instead of a random number how about you increment a value and save that to the database as well?
OMG GREAT IDEA ANOTHER DATA BASE WITH WHAT NUMBER, THX
hey, you can use a webhook to log feedback, this is just a recommendation instead of using DataStoreService
im having another problem
i understand the problem. It wont set the data store because if u write in a text boc, its local. and im using normal scripts to try to grab that, but it cant because as i said its LOCAL. But i cant use a local script because using those prevents you from being able to set dtastores. WHAT TO DO!?
is there a place where something can be accessed by both tserver and client in terms of clinet changing things and those changes affect the server?