changing the way legal moves are calculated to be more functional

Plus, a straight attacking function helps with board evaluation