Added receiveBefore to MessageQueue

This uses wait_until instead of wait_for on its condition variable.
Lots of state machine work

- GameStateMachine is now issued ticks periodically
  regardless of whether or not it gets messages.
  This allows it to change states, etc.

- Added a bunch of comments.