handle love.graphics.arc being passed identical angles

--HG--
branch : minor
This commit is contained in:
Bill Meltsner
2011-03-19 10:13:11 -04:00
parent 33a2110b00
commit 9251c2b4b1
+1
View File
@@ -990,6 +990,7 @@ namespace opengl
void Graphics::arc(DrawMode mode, float x, float y, float radius, float angle1, float angle2, int points)
{
float angle = angle2 - angle1;
if (angle == 0) return;
while (angle < 0) angle += LOVE_M_PI * 2;
if(points <= 0) points = 1;
float angle_shift = (angle / points);