Installation
Installation
Option 1: Using the Model
Option 2: Direct Asset ID
local DataHandler = require(108002867325509)Configuration
local DataHandler = require(game.ReplicatedStorage:WaitForChild("DataHandler"))
-- Update the configuration with the desired values
DataHandler.Config = {
DataStoreName = "PlayerDataStore", -- Name of the DataStore for player data
Keys = {"stats"}, -- Keys to load for a player
LeaderStats = {} -- Table for leader stats
}Functions
DataHandler:SaveData(player, key, value)
DataHandler:SaveData(player, key, value)DataHandler:LoadData(userId, key)
DataHandler:LoadData(userId, key)DataHandler:DeleteData(userId, key)
DataHandler:DeleteData(userId, key)DataHandler:GetPlayerData(userId)
DataHandler:GetPlayerData(userId)DataHandler:CreateLeaderStats(player, statsTable)
DataHandler:CreateLeaderStats(player, statsTable)Last updated