Курсовая работа: Поиск в лабиринте
gui->Fill(sx+(j*edge)-edge / 2, sy+(i*edge)-edge / 2, RED);
}
}
}
void tLabirint::GetCoords()
{
/*
start.x=1;
start.y=1;
finish.x=5;
finish.y=4;
*/
FILE *f;
char ch;
int i,j,n;
f = fopen("input.txt", "rt");
fread(&ch,sizeof(ch), 1, f);
n = atoi(&ch);
fread(&ch, sizeof(ch), 1, f);
//Chitat' startovuyu pozitciu:X
fread(&ch,sizeof(ch), 1, f);
start.x = atoi(&ch);
fread(&ch, sizeof(ch), 1, f);
//Chitat' startovuyu pozitciu:Y
fread(&ch,sizeof(ch), 1, f);
start.y = atoi(&ch);
fread(&ch, sizeof(ch), 1, f);
//Chitat' final'nuyu pozitciu:X
fread(&ch,sizeof(ch), 1, f);