moved tick into game object and some keyboard things

P for pause, D for next frame