ios app code for the game