So, I have an application for hybrid games, and I have a reward system in my game:
if(Date.now() - lastFreeCoinsTime > 3600000){ //lastFreeCoinsTime is also Date.now() giveCoins(); lastFreeCoinsTime = Date.now(); }
Every hour you can get X number of coins. what I learned can be easily manipulated by following these steps: Phone settings: change date (for example, 18/03 → 23/03) Now you can get the reward again. How can I avoid this?
I don’t think you can avoid certain behaviors, but you can stop someone from abusing them again and again by reducing their coins again if the current time has ever been before lastFreeCoinsTime. If the makers of Candy Crush weren't able to get around this, it should be pretty tricky.
lastFreeCoinsTime
, , , . , , ( ) . , , , . , , (, ), .
, "" . - , - "freemium", , , , . , , ? , . , ? , - , .
Source: https://habr.com/ru/post/1672608/More articles:Failed to load file or assembly "System.ValueTuple" - c #ExtJS changes the default position of buttons in MessageBox (ExtJS 4.2.1) - javascriptAndroid, String.split (String regex) does not break the entire string - javaSpring cannot configure authorization server - javaAre atomic variables a guarantee of memory visibility? - javaНастройка ActionCable с помощью приложения Elasticache для Rails 5.0 на эластичном бобовом стебле - ruby-on-railsPassing a pointer to an array in a function (C ++) - c ++Anyway, to make a numpy array operation faster? - pythonMulti-part graph - time (year) x-axis interval overlaying several years of data - javascriptКак получить значение ключа массива из запроса в golang - arraysAll Articles