partially fix #checkmate. still need to fix last bugs and write test