Turn chess game class into an event emitter