I would not load the code into the game.
Instead of that, the program should generate a number that indexes the list.
With that index can select a code.
For security and other reasons, the index should be encrypted.
At the selection stage must decrypt the index and get the code.
So, the whole process:
1. player win the game
2. the program generates the index
3. the program encrypts the index
4. the program sends the index to the server
5. the server decrypts the index
6. the server selects the code
7. the server sends back the code
8. the program shows the code

Just an idea. Use it, change it or throw it.

Last edited by Aku_Aku; 05/14/17 15:15.