This will require a better way to initialize application state; I have some ideas on this but it might need a bit more work.