Understanding the processes of X client now, starting to structure the main window and game logic system