moved multipeer code outside of app delegate on OSX