Help me create a testperiod of my game

Hello out there!

I am new on Unity and Programmning. I have only been working with this for a few months. Now i have a problem and thought that maybe you guys could help me out.

I have a few people who are going to test my game. I want the game to only be playable for 1 day, after that no mather how much they reinstall the game. they should not be able to play that version of the game again. Anyone with some good advices on how to solve this problem?

My idea is to use “System.DateTime.now” or something like that but if the user changes the date on the system, then “System.DateTime.Now” make no sense. or?

Sorry for my bad English, i hope you understand and can help me with this.

I would check the date on a webserver, so they cannot modify the system date. And if the date is not equal the one you want, dont load anything

1 Like

To make it for offline mode, maybe something like this: Remember the date on the first run, save it. Then on every other first run, check if the “new” date is behind the one you remembered, you know it’s been manipulated.
But then, they can just move their system clock to startTime+3 hours, and this check would fail.
For that, maybe if you count the number of minutes/hours while the app is opened, and make a limit of 6 hours or something (or how long you expect for the game to be played in one day). So that max open game time is 6 hours.

Or remember the time on exit also, and check if it was changed behind next time the app starts. This would all fail if time changes while the app is running, but if they try that hard, they probably deserve the free time.

The webserver one is definetly the best one though but it does require a 100% internet access on start.

1 Like

you can’t stop a user messing with their local environment to get around timelocks. You need to look at a online solution.

1 Like

Thank you guys, I will try one of your ideas later @Defero :wink:

Ok, i missread the situation. I don’t know if there is a way to permanently store that data for it to work. If they uninstall and delete the saved data. The reinstall would work again for them.

Nothing will really protect your game like that - they could crack the game to remove the check entirely or redirect the server request to a different / local server that always returns the correct value. You’re better off to provide a compact version of the game with only a single test level (or whatever is appropriate for your particular game).

Is it really that important that it could justify the amount of time you would be spending to implement a solution that can never give you 100% protection? Sounds like a waste of time to me to be honest.

1 Like