The compiler doesn't care about white space.
So what's wrong with
Code:
if ( (temp_take_piece[coordinate_x - 1][coordinate_y + (1 * multiplyer)] == 'b') ||
(temp_take_piece[coordinate_x - 1][coordinate_y + 1] == 'B') ||
(temp_take_piece[coordinate_x - 1][coordinate_y + (1 * multiplyer)] == 'w') ||
(temp_take_piece[coordinate_x - 1][coordinate_y + 1] == 'W')
)
Or just make a function out of it.
Code:
int checkTakePiece(temp_take_piece,coordinate_x,coordinate_y,multiplyer) {
char lc = temp_take_piece[coordinate_x - 1][coordinate_y + (1 * multiplyer)];
char uc = temp_take_piece[coordinate_x - 1][coordinate_y + 1];
return lc == 'b' || lc == 'w' || uc == 'B' || uc == 'W';
}
///
if ( checkTakePiece(temp_take_piece,coordinate_x,coordinate_y,multiplyer) ) {
// do stuff
}