Browse Source

refactoring: lab_can_move

remotes/origin/Joe
Joe Lukas Kalb 11 months ago
parent
commit
2302392b0c
  1. 8
      src/main/c/labyrinth.c

8
src/main/c/labyrinth.c

@ -70,13 +70,7 @@ short lab_can_move(Field_State** field, unsigned short x, unsigned short y, Dire
if (direction == N && field[x][y] == SOLUTION){
return 1;
}
if (direction == E && field[x][y] == SOLUTION){
return 1;
}
if (direction == S && field[x][y] == SOLUTION){
return 1;
}
if (direction == W && field[x][y] == SOLUTION){
if (field[x][y] == SOLUTION){
return 1;
}

Loading…
Cancel
Save