The move is blocked if the target piece belongs to ourselves. When capturing actually happens, the target piece is removed from piecesBox, the collection data type used to contain all chess pieces on board, or in game.
GitHub repo:
https://github.com/zhijunsheng/chess-...