Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I check all values in a datastore?

Asked by
NRCme 0
8 years ago

In my game it gives everyone a unique value, but I need a way to check the data stores to see if anyone else has the same number how would I go about doing this?

0
What have you tried doing? Uglypoe 557 — 8y
0
I'm pretty new to lua let alone Data Stores so I can't think of any ways of doing it so I looked it up in google but I didn't really get much NRCme 0 — 8y
0
Running GetAsync on a Datastore does not return the list of key-value pairs. In fact, nothing does. The only way to currently do this (as far as I am aware) is to hold all data inside a table, with that table being saved to the data store. Then you could set that table to a variable, get it from the Datastore, and then iterate through it. Uglypoe 557 — 8y

Answer this question