How do I build a frequent flyer system?

Hello all, I was wondering how I can make a Frequent Flyer System for my airline but I don’t know where to start. I have even looked so many places on the internet, but there doesn’t seem to be a tutorial which makes it more complicating.

I have also tried looking for answers on the Dev Forum but there is no tutorial or any kind of solution to be found anywhere. Can somebody please tell me how I can accomplish this, please include detailed steps so I can clearly understand.

Thank you :slight_smile:

Please correct me if I have done something wrong.

I would use datastores to store the last time they logged on, how many times in the past week or so, or things like how many times per a day they log on to the game.
Hope this helps!

1 Like

I would use a datastore. If my datastore returns a specific amount or greater, I would use BadgeService and award them a badge or whatever they would need. Since I’m on mobile, I’ll just explain how this’ll work:

Once the user books or checks-in for a flight or joins a game, use a function and call for how many times a player has flown from the datastore key. If the amount is over a specific amount then you can use BadgeService to award a badge or use the if statement to continue your function and add the flight to the datastore.

Here’s some handy links:

Datastore tutorial: Roblox DataStore Tutorial - Data Stores & Saving Data - Scripting Tutorial - YouTube

Datastore Wiki: Data Stores | Documentation - Roblox Creator Hub

BadgeService: BadgeService | Documentation - Roblox Creator Hub

1 Like

Good Idea. What about when my frequent flyers want to purchase something or upgrade to a higher class without owning the tshirt?

In the datastore, simply add true to if their a frequent flyer or not.

1 Like

So I make each tier a value? Or do I just make frequent flyer a value

You could add a tier value, like a level system. For example, 0 = economy, 1 = Frequent Flier, 2 = economy +, 3 = First class, ect.

If you used this approach I would recommend saving the level each player has in the datastore.
Hope this helps!

1 Like