Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How do I reset datastores?

I want to reset the data stores for my game. Is there any way to do this without changing the name of the data store or making a new game?

3 comments

0

If you REALLY just want to reset them instead of simply renaming them, you'll have to write a script that goes through everything 1 by 1 and removes everything. Otherwise, go with eLunate's answer.

0

You're trying to give him false hope. Roblox doesn't allow you to aggregate datastore keys - There's no way to do that.

0

There's a function called RemoveAsync() so try that.

1 answer

You don't.

When you want to reset data, you don't delete the old data - You just don't load it. This either means changing the name of the datastore, or changing how you generate the keys: If you're generating the keys based such as "user_" .. Player.UserId, then resetting all player data is simple as changing user_ to something else.

This is an unfortunate limitation in how Roblox handles datastores, however there is not a better way to manage this as Roblox only exposes an in-game API and expects persistence for the foreseeable future; They also expect you to use a testing database for testing, or to not enable Studio API access.

3 comments

0

kid stfu

0

LMFAO ^

0

Then roblox is wasting server space

This discussion is preserved as it was. New answers, comments, and votes are closed.