generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: ugh DataStores.

Previous Thread :: Next Thread 
Hazzatr0m is not online. Hazzatr0m
Joined: 13 Dec 2014
Total Posts: 1069
16 Jun 2017 02:01 PM
Hey.

I wanted to make a method with a DataStore which I could save all the player's developer product purchases and at a later data administrators could see a log filled with all the recent purchases and data about each one - so I used an OrderedDataStore.

The only problem is that I need to save a table with it and OrderedDataStores does not allow that. I've tried to save it as a string by turning it into JSON, but it still denies it and tells me I can't save strings.

Does anyone know a way around this?


ME ME BIG BOY!
Report Abuse
Wrathsong is online. Wrathsong
Joined: 05 Jul 2012
Total Posts: 22393
16 Jun 2017 02:02 PM
OrderedDataStores are not what you want. You can only save ints so it's for things like leaderboards.


Report Abuse
Hazzatr0m is not online. Hazzatr0m
Joined: 13 Dec 2014
Total Posts: 1069
16 Jun 2017 02:04 PM
I need some sort of function which I can get all - or at least a half dozen of the values in a DataStore. From my research so far, it only seems like I can do this via OrderedDataStore.


ME ME BIG BOY!
Report Abuse
MidasTouched is not online. MidasTouched
Joined: 02 Dec 2016
Total Posts: 242
16 Jun 2017 02:11 PM
For ordereddatastore, make the key the tick() that they bought the game pass, and the return value can be an array of data
Report Abuse
Hazzatr0m is not online. Hazzatr0m
Joined: 13 Dec 2014
Total Posts: 1069
16 Jun 2017 02:14 PM
@MidasTouched

Already tried this. It doesn't like the key's value anything other than an int, like said above.


ME ME BIG BOY!
Report Abuse
MidasTouched is not online. MidasTouched
Joined: 02 Dec 2016
Total Posts: 242
16 Jun 2017 02:16 PM
err a tick() is a number according to the wiki so idk
Report Abuse
Hazzatr0m is not online. Hazzatr0m
Joined: 13 Dec 2014
Total Posts: 1069
16 Jun 2017 02:20 PM
Yes, that's correct. You're telling me to make the key tick() - which is valid. But then, you are telling me to make the value of the key an array - which is where the error is thrown.


ME ME BIG BOY!
Report Abuse
MidasTouched is not online. MidasTouched
Joined: 02 Dec 2016
Total Posts: 242
16 Jun 2017 02:27 PM
Set the key to the data and the tick to the value
Report Abuse
Hazzatr0m is not online. Hazzatr0m
Joined: 13 Dec 2014
Total Posts: 1069
16 Jun 2017 02:29 PM
I had that idea, but later denied it because if the data was to go over 50 characters ROBLOX would freak


ME ME BIG BOY!
Report Abuse
MidasTouched is not online. MidasTouched
Joined: 02 Dec 2016
Total Posts: 242
16 Jun 2017 02:34 PM
Try it anyways, and test it to see what will happen. It could be that because the table is actually a reference to the table, it would only be the "hashcode" length number of letters. (Btw idk what the reference name is called in ROBLOX)
Report Abuse
MidasTouched is not online. MidasTouched
Joined: 02 Dec 2016
Total Posts: 242
16 Jun 2017 02:36 PM
If ROBLOX doesn't let you because of the limit, you could just store the players name as the key, and then in a normal data store have the players name as the key and the data as the value
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image