Originally Posted by
cyberfish
Thanks for your offer, really appreciated it. However, it is quite complicated as I am sorting a list of chess moves generated by my chess engine during its search in the order of likelihood to be a good move. The comparison operator does things like static exchange evaluation (count pieces from both sides attacking on the destination square to estimate material gain/lose), history heuristic (how many times has a move been proven useful in other parts of the search tree), and other minor criterias. Therefore, I think it would be too context-dependent for anyone to help just by looking at that function alone.
Thanks