Coding advice: Game Selection User Interface

Hello,

I am trying to create a game inside the arduino code. I am looking for some pointers on how to go about doing it. The steps are:

  • Arduino on
  • LCD Displays "Select Game Type"
  • LCD Displays "Select # of Players 1-4"
  • Code goes to that specific game

I know how I will code the games I'm just curious about the possible ways to go about the selection of the game. Right now I'am thinking of using Switch Cases for each part. So the user selects the game type Case 1, user then selects number of players Case 2, and then from there the code goes to which ever Case matches the selected game.

I am open to other possible ways to go about it, I searched the google but the only links I find are about making Pong.

Thank you,

Scooter

Right now I'am thinking of using Switch Cases for each part.

Nothing wrong with that approach, except that switch and case are the actual names.

How will the use actually make the selections?

It will be through push buttons, when they press it the LCD will display the title of the next game or the number of players. Its a 2X16 LCD screen.

You could store your games in array and select it by key..

0=>firstGame, 1=>seccondGame, ect.

And check if number that user entered is in array, else throw error at them.

(I'm PHP programmer so sorry if my logic do not apply to arduino code.)