How would I go about removing a particular players data in DataStore2? I’m familiar with regular datastores, but I’ve been asked to help a friend out with his already existing game, and I’ve never used DataStore2.
But I’m not sure if ClearCache() removes ALL data or if it’d remove for a particular player.
I’m too scared to try anything on the chance I remove ALL existing data for a game that hundreds of people have data saved on already. This is the only relevant information in the script I believe.
local storage = require(numbers)
local statStore = storage(storeKey, player)
local stats = statStore:Get()
I think :ClearCache() removes the data updated in that playing session.
But I think you can simply remove the players data by doing statStore:Set(nil)?