hey,

I am developing this game of snake, just like the nokia phones have. anyway i have worked on windows till now, but now i am using geany on linux. so there are quite some methods which are not standardised for all platforms. one of them is gotoxy() and i have found that there is ncurses() instead on linux. but i dont know the syntax. if anyone out there knows please help me, or if there is some other method to mess with the coordinates of the screen.

Thanks

Mr.web_master,
I've searched for a function similar to gotoxy() in ncurses .
I think i found this function:
1-

mvaddch(row,col,ch);

Prints the ch in the given row and column (similar to x=row and y=column)
2-

move(row,col);

move(row,col)
move the cursor to the given position

Therefore the mvaddch function can be written like this:-

move(row,col);
addch(ch);

.

Thanks for the reply Ahmed but can u tell me which library this method is in...coz i am unable to find it....

Thanks.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.