this is just a quick question i wanted to ask. Is there anyways you can view a players stats from datastore?
I'm assuming you understand how to use Data Store efficiently so I'll just explain how to make a visual example of the player's data. We'll be using leaderstats as to answer this question, BUT keep in mind that you can also show the player's data through many other ways too. In order to set up our leaderstats, we'll want to set a function that fires when a player joins. This can be done through game.Players.PlayerAdded:Connect(function(player)
. Next, we will add a model named "leaderstats" to the player and then add a values inside that model that represents the Data Store Values. Take this for an example,
local PrimaryData = game:GetService("DataStoreService"):GetDataStore("DataStore) game.Players.PlayerAdded:Connect(function(player) local LeaderStatsModel = Instance.new("Model",player) --Inserting the model into the player if PrimaryData:GetAsync("user_"..player.UserId) ~= nil then local NewValue = Instance.new("NumberValue",LeaderStatsModel) --What's being saved. Cash, level, exp, and etc.. NewValue.Name = "Insert whatever you want here" --Name of that value. EX: Cash, level, exp, and etc NewValue.Value = PrimaryData:GetAsync("user_"..player.UserId) -- That value else --set their data to default end end)