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: Correct layout for datastore?

Previous Thread :: Next Thread 
Tynezz is not online. Tynezz
Joined: 28 Apr 2014
Total Posts: 4945
01 Nov 2015 01:35 PM
Right now I do:

PlayerAdded
-Load
-SetAsync every 60 secs

PlayerRemoving
-SetAsync

But, sometimes there is data loss. Should I be using UpdateAsync?
Report Abuse
hunxrepair is not online. hunxrepair
Joined: 07 Aug 2011
Total Posts: 777
01 Nov 2015 01:41 PM
The server might shut down before data is saved.

game.OnClose = function()
repeat wait() until everyone's data is saved
end



http://wiki.roblox.com/index.php?title=API:Class/DataModel/OnClose


This is not a solution, just something that might be causing the problem.
Report Abuse
Tynezz is not online. Tynezz
Joined: 28 Apr 2014
Total Posts: 4945
01 Nov 2015 01:50 PM
@hun, already got that
Report Abuse
hunxrepair is not online. hunxrepair
Joined: 07 Aug 2011
Total Posts: 777
01 Nov 2015 02:25 PM
Well your code is probably the problem here then.
I'd say look over it again or remake the whole thing from scratch.
Or give us the code and someone here may find the issue.

I never had problems with data loss using setasync or getasync.
Report Abuse
LegitimatlyMe is not online. LegitimatlyMe
Joined: 30 Oct 2013
Total Posts: 1108
01 Nov 2015 02:27 PM
30 seconds is the max limit for game.OnClose, are you waiting <= 30 seconds?
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