cleaned up the sound code