Don't update pieceCount for ALL_PIECES

It is currently unused and only adds
overhead for nothing.

Also set proper type of chess960.

No functional change.
Merge remote-tracking branch 'upstream/master'