fix TypeError: Uncaught, unspecified "error" event.

events.js:74
        throw TypeError('Uncaught, unspecified "error" event.');
              ^
TypeError: Uncaught, unspecified "error" event.
    at TypeError (<anonymous>)
    at WebSocket.EventEmitter.emit (events.js:74:15)
    at Receiver.self._receiver.onerror (node_modules/xbmc-ws/node_modules/ws/lib/WebSocket.js:719:10)
    at Receiver.error (node_modules/xbmc-ws/node_modules/ws/lib/Receiver.js:301:8)
    at Receiver.opcodes.1.finish (node_modules/xbmc-ws/node_modules/ws/lib/Receiver.js:394:16)
    at Receiver.<anonymous> (node_modules/xbmc-ws/node_modules/ws/lib/Receiver.js:384:31)
    at Receiver.add (node_modules/xbmc-ws/node_modules/ws/lib/Receiver.js:93:24)
    at Socket.firstHandler (node_modules/xbmc-ws/node_modules/ws/lib/WebSocket.js:678:22)
    at Socket.EventEmitter.emit (events.js:95:17)
    at Socket.<anonymous> (_stream_readable.js:746:14)
add events for error close and connection
move init to init function to allow reconnection
add examples