equal
deleted
inserted
replaced
213 * you should still call clear() yourself! |
213 * you should still call clear() yourself! |
214 */ |
214 */ |
215 int AyStarMain_Main(AyStar *aystar) { |
215 int AyStarMain_Main(AyStar *aystar) { |
216 int r, i = 0; |
216 int r, i = 0; |
217 // Loop through the OpenList |
217 // Loop through the OpenList |
218 // Quit if result is no AYSTAR_STILL_BUSY or is more then loops_per_tick |
218 // Quit if result is no AYSTAR_STILL_BUSY or is more than loops_per_tick |
219 while ((r = aystar->loop(aystar)) == AYSTAR_STILL_BUSY && (aystar->loops_per_tick == 0 || ++i < aystar->loops_per_tick)) { } |
219 while ((r = aystar->loop(aystar)) == AYSTAR_STILL_BUSY && (aystar->loops_per_tick == 0 || ++i < aystar->loops_per_tick)) { } |
220 #ifdef AYSTAR_DEBUG |
220 #ifdef AYSTAR_DEBUG |
221 if (r == AYSTAR_FOUND_END_NODE) |
221 if (r == AYSTAR_FOUND_END_NODE) |
222 printf("[AyStar] Found path!\n"); |
222 printf("[AyStar] Found path!\n"); |
223 else if (r == AYSTAR_EMPTY_OPENLIST) |
223 else if (r == AYSTAR_EMPTY_OPENLIST) |