Now … I wonder , is there any way to make random code generator (numbers+ ABCD… and with capitals)
That will save the code untill somone use that code and then delete that code?
1 computer will generate the code while redstone signal/the owner will tell it and 1
computer will recive that code and check if the input = to the code and then delete the code…
if its possible - can it have multiply codes & uses to the codes?
For example - I made map and i want that people will put diamond per code that have 10 uses or
Iron/coal per 1 enter… is that possible?
How I would do it…
Here is a good free random code generator,
http://www.generaterandomcodes.com/free-generate-random-codes-toolLimited to 20K, but you can use prefixes and run it many times ;)/>
- if that's not enough, then maybe use md5 with simple string and number increments ?:-/
Dump codes in mysql db using phpmyadmin
php script to receive ajax request, but need to make sure request comes from your own scripts, either with api key or some other way. HTTPS helps.
if the code is found, add code to "used_codes" table and delete from master_codes table.
If you want "10 uses" then keep another field "uses", increment each time. mysql can increment a field for you. Then only move to used codes table when it reaches 10
Issues I can see;
Validating source of request, only need this if you expect hack attempts.
Catering for Errors, eg. if you send "success" response. Did the app actually received and used that response. Probably want another ping back to server to say, received success.
Hard to suggest any more based on your post.
Hope that helps