Is this what you had in mind?
do
select game_state
case GAME_INIT
gosub INIT
endcase
case GAME_INTRO
gosub INTRO
endcase
case GAME_RUN
gosub PLAYER_INPUTS
gosub PLAYER_CONTROL
gosub DO_LOGIC
gosub WORLD_UPDATE
sync
endcase
case 1 GAME_EXIT
gosub EXIT_GAME
endcase
endselect
loop
What? More specific? But that's not possible. You see, every game is different. Every game has it's own problems and solutions, and game programming is mostly the teeth-gnashing kind of programming because you need to fit the running of a whole world into measly 50-60 thousandths of a second. God at least had seven days...
I'm having you on, a bit. Sorry about that. But what I said is true. Game programming is hard, and apart from generalities -- which we'll gladly help with if we can -- you have to write your game yourself. None of us knows what kind of game you want.
Cheers, and good luck!
-----
They SAID that given enough time a million monkeys with typewriters could recreate the collected works of William Shakespeare... Internet sure proved them wrong.
-----