I have leaderstats in the game but when I test in studio they are there and when I go to my game they are not, Could the reason be because the error message and how do I fix
01 | game.Players.PlayerAdded:Connect( function (player) |
02 | local leaderstats = Instance.new( "Folder" , player) |
03 | leaderstats.Name = "leaderstats" |
04 |
05 | local Lvl = Instance.new( "NumberValue" , leaderstats) |
06 | Lvl.Name = "Level" |
07 | Lvl.Value = 1 |
08 |
09 | local EXP = Instance.new( "NumberValue" , leaderstats) |
10 | EXP.Name = "EXP" |
11 |
12 | local MaxEXP = Instance.new( "IntValue" , leaderstats) |
13 | MaxEXP.Name = "MaxExp" |
14 | MaxEXP.Value = 100 * (Lvl.Value / 2 ) |
15 |