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
We use cookies to offer you a better experience. By using Roblox.com, you are agreeing to our Privacy and Cookie Policy.
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: Everyone sharing data for some weird reason?

Previous Thread :: Next Thread 
cybercircut is not online. cybercircut
Joined: 28 Jan 2011
Total Posts: 280
07 Nov 2014 09:15 PM
I was testing converting my game to Data Stores from Data Persistence, and I noticed that some of the Data was shared across all of the testers.
I was wondering if making it so every player has there data saved under different key names ("lvlPlayer1", "lvlPlayer2", "lvlPlayer3", etc) would fix that, and if that would work with large amounts of people?
Report Abuse
jaredmai is not online. jaredmai
Joined: 08 Sep 2011
Total Posts: 395
07 Nov 2014 09:17 PM
This is because you need different names for each save file.
Such as:
local DataSaveName = plr.userId.."LvlSave"
and load it the with the same way...
lcoal DataLoadName = plr.userId.."LvlSave"
Report Abuse
cybercircut is not online. cybercircut
Joined: 28 Jan 2011
Total Posts: 280
07 Nov 2014 09:19 PM
So for each player, it saves it using a different keyname?
Like:
DataStore:SetAsync("Player1SaveData", 5)
vs
DataStore:SetAsync("Player2SaveData", 5)
Like I said?
Report Abuse
cybercircut is not online. cybercircut
Joined: 28 Jan 2011
Total Posts: 280
07 Nov 2014 09:25 PM
Bump
Report Abuse
cybercircut is not online. cybercircut
Joined: 28 Jan 2011
Total Posts: 280
07 Nov 2014 09:33 PM
BUMP
Report Abuse
jakej78b is not online. jakej78b
Joined: 09 Mar 2011
Total Posts: 813
07 Nov 2014 09:35 PM
No, for each player, you need to use a different keyname or else it will use the same data for every player. Using their userId is the best way rather than using numbers, because there is no other way to indefinitely identify users other than userids.
Report Abuse
cybercircut is not online. cybercircut
Joined: 28 Jan 2011
Total Posts: 280
07 Nov 2014 09:36 PM
You get what I mean, and will that work with huge amounts of players?
Report Abuse
jaredmai is not online. jaredmai
Joined: 08 Sep 2011
Total Posts: 395
07 Nov 2014 10:16 PM
._. Of course yes. Every userId is unique to that player and doesn't change if a player changes their username.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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