made server asynchronous, bug fixes, added double down option