How to make a badge for playing 7 days

Hello

  1. What do you want to achieve? A script that awards a badge when you pay for 7 days in a row

  2. What is the issue? I cannot find a script like that

  3. What solutions have you tried so far? I looked here, the toolbox, youtube, etc

Any help is appreciated!

1 Like

I’m not gonna provide an actual script but basically the first time the player joins, save the time they logged on using os.time or tick and their streak (1).

Then, if they log on again, subtract the value you saved last time by os.time and see if it’s been more than 24 hours; if it has, increase their streak [if it hasn’t then don’t increase the streak or save the time].

Keep repeating this until their streak is 7 and THEN give them their badge.

I’m pretty sure there is a tutorial on this somewhere on YouTube but if you feel confident, try to implement it using only this description


P.S.

If you need me to elaborate more, I’d be happy to do so.

Edit: don’t know if OP ever saw these posts

data stores, log when they first joined using os.time and give it to then once that number reaches over 7 days in seconds

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.