#1376 Adding some defensiveness to the OpenAl sound setup

Added some comments where appropriate, moved the hardware init code into its own method, added a state flag to know when the sound hardware was setup or not, and added more aggressive handling of hardware setup errors. See issue #1376.