|
| 19 Oct 2015 05:11 PM |
Problem: It is Only Loading One Value When i Load player.userId i thought thats how it works to load a value. my gut is telling me Change player.userId to the Value name ------------------------------------------------ local SacredStorage = game:GetService("DataStoreService"):GetDataStore("BleachOnlineReborn") game.Players.PlayerAdded:connect(function(player) local Level = Instance.new("IntValue") Level.Name = "Level" Level.Value = 1 local XP = Instance.new("IntValue") XP.Name = "XP" XP.Value = 0 local NEWBIE = Instance.new("BoolValue",player) NEWBIE.Name = "NewPlayer" NEWBIE.Value = false local MaxXP = Instance.new("IntValue") MaxXP.Name = "MaxXP" MaxXP.Value = 5 MaxXP.Parent = player Level.Parent = player XP.Parent = player if SacredStorage:GetAsync(player.userId) ~= nil then XP.Value = SacredStorage:GetAsync(player.userId)--problem Level.Value = SacredStorage:GetAsync(player.userId)---problem MaxXP.Value = SacredStorage:GetAsync(player.userId)---problem end while true do wait(2) SacredStorage:SetAsync(player.userId,Level.Value,XP.Value,MaxXP.Value,NEWBIE.VALUE) end end) |
|
|
| Report Abuse |
|