How to prevent a player from playing the game for a specific period of time? [Backend Suggestion]

Hello everyone,

I want to make a game where the players can do crimes but when they get caught in the game, I want them not to be able to play the game for a specific period of time. Let’s say 2 minutes. I need a server to save the time when the player gets caught and depending on the server time, I can compute if 2 minutes passed.

My question is what kind of backend system do I need to make this? I heard PlayFab and other backend systems to save players’ data but can I compute if 2 minutes passed or not? Or should I have my own server?

Why bother with anything like that for 2 min on mobile?
Just run some ads as time in prison. Or allow player do something else.

Mind, chances are you will force boredom to your player. Essentially asking player to stop playing.

But on other hand, we got games already, which allow only few actions per day …

I just simplified what I want to do. All I need is to prevent player from doing some actions. How can I achieve this? It should be something related to backend

well can you read time in back end? if yes, use a if block that check elapsed time and branch to whatever state you need.

@ you could go as simple, as Unity web request via PHP to communicate with DB.
Then you don’t need any 3rd party assets.