GhostMonk3y/CPSC481_ChessGame — pull request #1 by sorwanichpan (2014-10-04 05:57:52+00:00)
Title: Added Rook and other tid bits

Hey guys,

Too lazy to type all of this into my phone. So I started work on the Rook piece and everything works in terms of it being able to move vertically and horizontally correctly (No more out of bounds error and more than one space at a time!).

I'm still working on the row and column scanning check for any occupying pieces in the way of Rook. I have a pretty good idea of how it should work, and I should be able to hammer that out tomorrow. I'll try to integrate in some Check/Checkmate function for the Rook if I can.

The rook is still using henry's king stalking distance algorithm. So if you run the game the Rook will make the closest possible move to the enemy King and chase it (whilst staying a safe distance away). I'm thinking about modifying this to have it look for the shortest distance to a check on the king instead (and to stop moving if the king is in check).

In addition to all that, finally added in my unicode representation and orientation fix. Also the screen will clear everything a new move is made instead of printing out the new board below. Its superficial, but it makes the game looks nicer.

Oh and most importantly, our code is getting very crowded. I think it may be nearing the time partitioning things off into different modules so we can test things easier. I added a global bool (TESTINGROOK) at the top. It was originally for alternating moves for the King/Rook, but it didn't work. I kept it as a way to flip between testing Rook or the King instead. If you want to test the King, make sure you set it to False

The code is uploaded on Drive as well.
--Sorasit