I made this like random lottery.
- Generates random number from 1 to 10000
- If it is smaller than 5000 double the value of your coins
- if not take them away
When I tested that system I could make that your winning would be more than 2 times bigger by inspecting elements going to source and finding my JavaScript file and changing bet * 2 into bet * 999.
Now I need to remake it because I don't want that my websites users to cheat.
Instead of adding script from script file I wrote it directly in the HTML page between <script> code </script>
and then I felt like god because I thought I fixed that.
Is this proper way to deal with this?