It is interesting and fun to type and interpreting ideas as a game, good job!
I only got stuck on the Q's and B's, no idea could work out, but maybe that's just me.
yeah I forgot to fix the grammer of the rule to make it match the code. (#p’s == #Q’s == #B's)