void setAngleToRight(AngleUnit in_angleUnit) { float new_angle = in_angleUnit.getCurrentAngleBase() + 90; if (new_angle > 360) { new_angle %= 360; } in_angleUnit.setCurrentAngle(new_angle); }
void setAngleToLeft(AngleUnit in_angleUnit) { float new_angle = in_angleUnit.getCurrentAngleBase() - 90; if (new_angle > 360) { new_angle %= 360; } if (new_angle < 0) { new_angle += 360; } in_angleUnit.setCurrentAngle(new_angle); }