More changes to audio system

Ensure proper line closure, changed audiolooper to a static class,
fixed a certain locking issue