Ban System Questions

Hi there,

  If I were to create a ban system, and I wanted the player that got banned to only be banned for a week, For Example, Then Would I do osTime Then add A week on to it, then say If the osTime is greater then that added time,  The player is no longer banned.

Would This work? I am new to OSTime, So I don’t understand It fully.

Yes, this would work

30 characters

Another option is when the player gets banned just save the os.time() when they were banned and when they rejoin use what is saved in the DataStore with the current os.time() to find the time that has passed since they were banned. I think the gain from this is that you can easily alter how long certain bans should last and it would effect everyone who was banned for that same reason.

It’s easier if you save their os.time() on a database, then when they join check if os.time() - player's Os.time() > 604800 -- seconds in a week

If so, either delete their database or ignore it and continue the code. If returns false, kick em