Курсовая работа: Поиск в лабиринте
return count;
}
void tLabirint::DFS_Visit(int y, int x)
{
int i;
int cnt;
smezh sm;
if(flag==1)
{
exit;
}
/**/
color[y][x]=1;
delay(500);
count_p++;
path[count_p].x=x;
path[count_p].y=y;
setcolor(BLUE);
//defaultmouseoff;
gui->Circle(sx+x*edge-edge / 2, sy+y*edge-edge / 2, 3);
//defaultmouseon;
//printf("X-%d;Y-%d\n", x, y);
//getchar();
if((finish.x==x) && (finish.y==y))
flag=1;
/**/
cnt=GetCommon(y, x, sm);
for(i=1;i<=cnt;i++)
{