diff options
author | jonas <himself@jonasgunz.de> | 2019-01-25 17:04:57 +0100 |
---|---|---|
committer | jonas <himself@jonasgunz.de> | 2019-01-25 17:04:57 +0100 |
commit | 312f2c0a2a42c776863af69b7c4be55597287da4 (patch) | |
tree | 64010c094d263a94d7175f8d91182ce6a6afc0e7 /cRender.cpp | |
parent | 878672afb99085e4800f080cb3980657ced17369 (diff) | |
download | termgl-312f2c0a2a42c776863af69b7c4be55597287da4.tar.gz |
c
Diffstat (limited to 'cRender.cpp')
-rw-r--r-- | cRender.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cRender.cpp b/cRender.cpp index f563199..9fbdc8f 100644 --- a/cRender.cpp +++ b/cRender.cpp @@ -115,7 +115,7 @@ int cRender::drawLine(char _c, sPos _pos1, sPos _pos2, bool _overrideCollision, { drawPoint(_c, sPos{i + _pos1.x, (int)(i * fGradient + _pos1.y + 0.5)}, _overrideCollision, _color); //+0.5 for rounding error - if(abs(fGradient) > 1) + if(std::abs(fGradient) > 1.0) { int dy = (int)(((i + 1) * fGradient + _pos1.y + 0.5) - (i * fGradient + _pos1.y + 0.5)); |