fixed FPS and implemented mouse