Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if ((colorCompare == '#') && (orientation == 1))
- {
- this->orientation = 4;
- }
- else if ((colorCompare == '#') && (orientation == 2))
- {
- this->orientation = 1;
- }
- else if ((colorCompare == '#') && (orientation == 3))
- {
- this->orientation = 2;
- }
- else if ((colorCompare == '#') && (orientation == 4))
- {
- this->orientation = 3;
- }
- else
- {
- this->orientation++;
- }
- }
- int moveAnt()
- {
- if (orientation == 1)
- {
- this->row_x -= 1;
- }
- else if (orientation == 2)
- {
- this->column_y += 1;
- }
- else if (orientation == 3)
- {
- this->row_x + 1;
- }
- else if (orientation == 4)
- {
- this->column_y - 1;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement