Use unique_ptr in main loop.
Reindent.
Use unique_ptr with input events.
Use the C++11 initializer syntax for static maps.