I am currently learning about datastore in Roblox. Sometimes it gets a little annoying not knowing how it fully works.
So I am making a DCO (difficulty chart obby) game and I am using datastore to save your progress. But I want to make a rebirth system and it won’t let me clear the leader stats value because the value comes from the datastore.
I want to know how would I clear my datastore data for the leader stats through a script.
local Datastore = game:GetService("DataStoreService"):GetDataStore("Datastore")
Datastore:SetAsync("hello",true) -- set something, just to test
Datastore:RemoveAsync("hello") -- hooray we removed it
No, true is the value stored in hello, removing hello from the datastore would make any future attempts to retrieve hello return nil because the key wouldn’t exist anymore