* Rotate the direction by 90 degrees. * @param dir Direction to rotate. * @return Rotated direction. */
| 121 | * @return Rotated direction. |
| 122 | */ |
| 123 | static inline Direction2 rotate90(Direction2 dir) |
| 124 | { |
| 125 | return rotate45(dir, 2); |
| 126 | } |
| 127 | |
| 128 | /** |
| 129 | * Rotate the direction by 180 degrees. |