Multiplier is not a valid member of Folder???
when i test play on Roblox studio, the log says this :
Multiplier is not a valid member of Folder
Stack Begin
Script 'ServerScriptService.Stats', Line 21
Stack End
And also the multiplier value does not show up in leaderstats
01 | local DataStoreService = game:GetService( "DataStoreService" ) |
02 | local DataStore = DataStoreService:GetDataStore( "Clidat" ) |
04 | game.Players.PlayerAdded:Connect( function (player) |
05 | local leaderstats = Instance.new( "Folder" ) |
06 | leaderstats.Parent = player |
07 | leaderstats.Name = "leaderstats" |
09 | local Clicks = Instance.new( "IntValue" , leaderstats) |
10 | Clicks.Name = "Clicks" |
11 | Clicks.Value = DataStore:GetAsync(player.UserId) or 0 |
13 | local mult = Instance.new( "IntValue" , leaderstats) |
14 | mult.Name = "Multiplier" |
15 | mult.Value = DataStore:GetAsync(player.UserId) or 1 |
18 | game.Players.PlayerRemoving:Connect( function (player) |
19 | local Clicks = player.leaderstats.Clicks |
20 | local mult = player.leaderstats.Multiplier |
25 | DataStore:SetAsync(player.UserId, dattosa) |