mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-01-19 00:37:25 +01:00
[python/turtle] Clean Turtle::PawPosition
This commit is contained in:
@@ -330,7 +330,7 @@ void Turtle::drawPaw(PawType type, PawPosition pos) {
|
||||
|
||||
// Compute the paw offset from the turtle center
|
||||
float currentAngle = angles[(int) type];
|
||||
float crawlDelta = (((int)pos) - 2.0f) * crawlOffset;
|
||||
float crawlDelta = ((float)((int)pos)) * crawlOffset;
|
||||
float pawX = pawOffset * sin(m_heading+currentAngle) + crawlDelta * sin(m_heading);
|
||||
float pawY = - pawOffset * cos(m_heading+currentAngle) - crawlDelta * cos(m_heading);
|
||||
KDCoordinate pawOffsetX = ((int)pawX) - (pawX < 0 ? 1 : 0);
|
||||
|
||||
Reference in New Issue
Block a user