Is there a way I can put stats other then leaderstats?

  1. I want a way to save stats, for example “money” somewhere other then leaderstats.

  2. I’m horrible at scripting, and I don’t know how I would save it.

  3. I’ve read all over the Dev Hub.

I’m new to scripting, and I have no idea how to do this. Please give me any ideas, or examples. Thanks for reading :slight_smile:

From my knowledge, datastore (leaderstats) in a way, is the only way to save data.

Yes, leaderstats has nothing to do with data saving. It’s just a method of displaying saved data.

Edit: Related topic:

6 Likes

Datastores are completely separate and unrelated to leaderstats.

3 Likes

I want this, so the leaderstats wont be super extended (mainly) @ pooglies @posatta can you guys give me examples of datastores?

Like posatta said, leaderstats display saved data. However, leaderstats is not the only way to have data, while leaderstats is the way of displaying it, you could just store a value within the player, it won’t be displayed like leaderstats.

1 Like

leaderstats has nothing to do with saving, its for displaying stats on the Default Roblox scoreboard.

https://developer.roblox.com/en-us/articles/Data-store
https://developer.roblox.com/en-us/api-reference/class/DataStoreService
With this you can save data, be sure to read about the limitations, although i recommend Datastore2 to try to avoid that

You could have the server store the “money” somewhere (within the player, like @Creeperthekid32 said), and have a local script :Connect() to it to change a Gui or something.
https://developer.roblox.com/en-us/api-reference/event/NumberValue/Changed

1 Like

I understand that leaderstats is not datastore, but it could also be used as an inefficient way to save stuff.

It’s not really inefficient if it just outright doesn’t save.

Saving =/= Storing (ty @Creeperthekid32)

1 Like

leaderstats is a folder that stores values within the player, DataStores can be used to save the values within leaderstats, which doesn’t mean that leaderstats is a method of saving.

1 Like

@Pooglies @Creeperthekid32 @MRePotatoes I don’t want to use leaderstats, because its going to fill up the leaderboard and I don’t want that. Unless theres a way to hide the leaderboard.

To hide the leaderboard, you just don’t create a leaderstats folder in the first place. The leaderboard only is displayed if there are values within a folder, leaderstats, stored in the player.

My method I can think of saving data without using leaderstats is to have a value stored somewhere, in this example I will use ReplicatedStorage. Then you just DataStore it from there, which this is most of the stuff that @posatta and @MRePotatoes had linked, definitely check those links out.

Safest bet, you should use that.

or within ReplicatedStorage, be sure to create a value for every players.