|
|
|
|
@ -38,12 +38,15 @@ template <DirectionX DirX, DirectionY DirY>
|
|
|
|
|
void DrawMapLineSteep(const Surface &out, Point from, int width, std::uint8_t colorIndex) |
|
|
|
|
{ |
|
|
|
|
while (width-- > 0) { |
|
|
|
|
out.SetPixel({ from.x, from.y + 1 }, 0); |
|
|
|
|
out.SetPixel(from, colorIndex); |
|
|
|
|
from.y += static_cast<int>(DirY); |
|
|
|
|
out.SetPixel({ from.x, from.y + 1 }, 0); |
|
|
|
|
out.SetPixel(from, colorIndex); |
|
|
|
|
from.y += static_cast<int>(DirY); |
|
|
|
|
from.x += static_cast<int>(DirX); |
|
|
|
|
} |
|
|
|
|
out.SetPixel({ from.x, from.y + 1 }, 0); |
|
|
|
|
out.SetPixel(from, colorIndex); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|