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: Data store help

Previous Thread :: Next Thread 
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
30 Oct 2017 09:36 PM
Every time I join the game the value stays true, but it's supposed to turn false at the changed event.. output doesn't say that there is anything wrong. Is the format for this data store correct?


local Key = "Player - "..player.userId
local DataStoreService = game:GetService("DataStoreService")
local PlayerStats = DataStoreService:GetDataStore("PlayerStats")

FirstTime = Instance.new("BoolValue",InfoStore)
FirstTime.Name = "FirstTime"
FirstTime.Value = PlayerStats:GetAsync(Key) or true
PlayerStats:SetAsync(Key, player.InfoStore.FirstTime.Value)

player.InfoStore.FirstTime.Changed:connect(function()
PlayerStats:SetAsync(Key,false)
end)
Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
30 Oct 2017 09:58 PM
Bumpeth
Report Abuse
WildGuest is not online. WildGuest
Joined: 28 Feb 2010
Total Posts: 647
30 Oct 2017 10:18 PM
Did you define player?


Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
30 Oct 2017 10:24 PM
Yes, assume that any variables are defined. :)
Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
30 Oct 2017 10:39 PM
Bumperoo
Report Abuse
popthecorn145 is not online. popthecorn145
Joined: 04 Aug 2013
Total Posts: 68
30 Oct 2017 10:45 PM
on line 7 im pretty sure that is suppose to be firsttime.Value = ########################### false
Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
30 Oct 2017 10:51 PM
Tags. #####
Report Abuse
WildGuest is not online. WildGuest
Joined: 28 Feb 2010
Total Posts: 647
30 Oct 2017 10:51 PM
Use the preview option before posting to see if you're post is hashtagged.


Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
30 Oct 2017 11:59 PM
Wow I never even realized that's what that was for lol. Bump.
Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
31 Oct 2017 12:12 AM
Bump please I just want to get this to work so I can GO TO BED D:
Report Abuse
Kasumo is not online. Kasumo
Joined: 22 Mar 2013
Total Posts: 2467
31 Oct 2017 11:29 AM
Bump
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