Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Someone help me please, i'm trying to make a leader board and this error appeared. Help?

Asked by 4 years ago
Edited 4 years ago

local severStorage = game:GetService("ServerStorage") local DataStore = game:GetService("DataStoreService"):GetDataStore("PlayerSave3")

game.Players.PlayerAdded:Connect(function(player)

local leaderstats = Instance.new("Folder")
leaderstats.Name = "leaderstats"
leaderstats.Parent = player

local strength = Instance.new("NumberValue")
strength.Name = "ChillStrength"
strength.Parent = leaderstats

local rebirths = Instance.new("IntValue")
rebirths.Name = "Rebirths"
rebirths.Parent = leaderstats

local dataFolder = Instance.new("Folder")
dataFolder.Name = player.Name
dataFolder.Parent = severStorage.RemoteData

end <eof>

Error: ServerScriptService.Stats:22: Expected identifier when parsing expression, got <eof> Sorry i'm new to coding.

Uptate: Code:

local severStorage = game:GetService("ServerStorage") local DataStore = game:GetService("DataStoreService"):GetDataStore("PlayerSave3")

game.Players.PlayerAdded:Connect(function(player)

local leaderstats = Instance.new("Folder")
leaderstats.Name = "leaderstats"
leaderstats.Parent = player

local strength = Instance.new("NumberValue")
checkpoint.Name = "Level"
checkpoint.Parent = leaderstats

local dataFolder = Instance.new("Folder")
dataFolder.Name = player.Name
dataFolder.Parent = severStorage.RemoteData

end)

Error: ServerScriptService.Stats:11: attempt to index global 'checkpoint' (a nil value)

0
end) Azarth 3141 — 4y
0
then i have a new problem ivan6361 34 — 4y
0
oh i fixed it, thank you ivan6361 34 — 4y

1 answer

Log in to vote
0
Answered by 4 years ago

After i used end) and deleted <eof> i managed to fix it with. Thank you too Azarth.

Ad

Answer this question