Update piecelogic.py

Fix queen
Restucture functions