saved 12 bytes (yes, I really needed them)

This commit is contained in:
Christian Kroll 2011-11-01 14:56:24 +00:00
parent 84512b4740
commit 0b49336643
1 changed files with 2 additions and 2 deletions

View File

@ -269,12 +269,12 @@ static void snake_autoRoute(snake_protagonist_t *pprotSnake,
}
}
for (uint8_t i = 4; i--;)
for (uint8_t i = 0; i < 4; ++i)
{
pixel pxTest = snake_applyDirection(pxHead, pprotSnake->dir);
if (get_pixel(pxTest))
{
for (uint8_t j = pApples->nAppleCount; j--;)
for (uint8_t j = 0; j < pApples->nAppleCount; ++j)
{
if ((pxTest.x == pApples->aApples[j].x) &&
(pxTest.y == pApples->aApples[j].y))