thachthen_it Admin
Tổng số bài gửi : 53 Reputation : 0 Join date : 19/05/2011 Age : 32 Đến từ : trà vinh
| Tiêu đề: hàm hiện thị 1 kí tự tại tọa độ (x,y) với màu tùy chọn Mon Aug 22, 2011 10:48 pm | |
| cái này dùng trong windows.h - Code:
-
void atchar(unsigned char what,int x,int y,int color) { static HANDLE hout; static bool first=TRUE; COORD Position; if(first) { hout=GetStdHandle(STD_OUTPUT_HANDLE); first=FALSE; } Position.X=x; Position.Y=y; SetConsoleCursorPosition(hout,Position); textcolor(color); cout<<what<<flush; }
| |
|