I’ve gone through countless forum posts and been through many ‘solutions’ that don’t resolve my issue, so maybe someone can help me here lol
I need to create a Global Leaderboard for certain stats within the game; simple right? wrong. ( at least with the way I save my data )
I save all of my data within one data store, under one key ( e.g ‘Stats_3$*1!’ )
All of the data saved within the data store is saved within different ‘categories’ ( different tables )
e.g
leaderstats = {
{Name = "Bubbles", Value = 0},
{Name = "Crystals", Value = 0},
{Name = "Prestige", Value = 0},
},
BubbleData = {
{Name = "BubbleCooldown", Value = 1.5},
{Name = "TotalBubbles", Value = 0},
{Name = "BubblesPerBlow", Value = 1},
{Name = "Multiplier", Value = 1},
{Name = "BubbleValue", Value = 1},
{Name = "BubbleCapacity", Value = 10},
{Name = "CrystalValue", Value = 1},
{Name = "CrystalMultiplier", Value = 1},
{Name = "TotalCrystals", Value = 0},
{Name = "AutoBlow", Value = 0},
{Name = "BubblesPopped", Value = 0},
{Name = "GoldBubbleChance", Value = 5},
{Name = "EquippedBubble", Value = "Blue"},
{Name = "TimePlayed", Value = 0},
},
InventoryData = {
{Name = "Blue", Value = true},
{Name = "Green", Value = false},
{Name = "Red", Value = false},
{Name = "Purple", Value = false},
{Name = "UFO", Value = false},
{Name = "RedSlime", Value = false},
{Name = "RedHeart", Value = false},
{Name = "PurpleFlower", Value = false},
{Name = "PurpleHeart", Value = false},
{Name = "PinkFlower", Value = false},
{Name = "PalmTree", Value = false},
{Name = "GreenSlime", Value = false},
{Name = "GreenFlower", Value = false},
{Name = "GreenHeart", Value = false},
{Name = "GoldFlower", Value = false},
{Name = "Flower", Value = false},
{Name = "EvilSlime", Value = false},
{Name = "Cactus", Value = false},
{Name = "BlueSlime", Value = false},
{Name = "BlueHeart", Value = false},
{Name = "YellowDuck", Value = false},
{Name = "SpecialKraken", Value = false},
{Name = "RedKraken", Value = false},
{Name = "RedDuck", Value = false},
{Name = "OrangeFrog", Value = false},
{Name = "GreenFrog", Value = false},
{Name = "GreenDuck", Value = false},
{Name = "BlueFrog", Value = false},
{Name = "GreenKraken", Value = false},
{Name = "Sun", Value = false},
},
LevelData = {
{Name = "Level", Value = 1},
{Name = "XP", Value = 0},
{Name = "Multiplier", Value = 1},
},
UpgradeData = {
{Name = "Tapper", Value = 0},
{Name = "Gold Tapper", Value = 0},
{Name = "Evil Tapper", Value = 0},
{Name = "Wand", Value = 0},
{Name = "Mining Away", Value = 0},
{Name = "Bubble Potion", Value = 0},
{Name = "Better Pick", Value = 0},
{Name = "Paper Bag", Value = 0},
{Name = "Bubble Potion+", Value = 0},
{Name = "Golden Touch", Value = 0},
{Name = "Bombs Away", Value = 0},
{Name = "School Bag", Value = 0},
{Name = "Watch", Value = 0},
{Name = "Auto Wand I", Value = 0},
{Name = "Mouse", Value = 0},
{Name = "Gold Pick", Value = 0},
{Name = "XTRA XP", Value = 0},
{Name = "Mouse+", Value = 0},
{Name = "Gold Bag", Value = 0},
{Name = "Auto Wand II", Value = 0},
{Name = "Golden Bombs", Value = 0},
{Name = "Better Watch", Value = 0},
{Name = "Mouse++", Value = 0},
},
Codes = {
{Name = "Beta", Value = 0},
{Name = "BUBBLES", Value = 0},
{Name = "Sunny", Value = 0},
{Name = "Chris Tal", Value = 0}
}
When the game is loaded, those ‘categories’ ( the tables ) are instantiated as folders, with the respective stat values created within.
All of the data is saved within one data store to sorta avoid datastore overloading and crashing
Lets say I want to create a global leaderboard using OrderedDataStore, for the stat ‘Bubbles’. I’d have to retrieve the data from [“leaderstats”] and then [“Bubbles”]. I can’t do that with OrderedDataStores ( to my knowledge )
I’ve been trying to figure out how I’d do it, and I’ve tried countless methods but nothing has worked. I was wondering if someone knew HOW I’d go about retrieving the ordered data in my situation.