added state machine, including pause, and an opening splash