Originally posted by Quantrizi
Good point...heh. But, would you still have to include conio.o *gotoxy is in the conio header(s)*
Nope, gotoxy isnt in conio.h, I did the function gotoxy():
functions.h
Code:
#include <iostream>
#include <conio.h>
#include <stdlib.h>
#include <windows.h>
using namespace std;
HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
HANDLE hInput = GetStdHandle(STD_INPUT_HANDLE);
// Declerations
void gotoxy(int,int);
void SetColor(short);
// Definitions
void SetColor(short Color)
{
SetConsoleTextAttribute(hConsole, Color);
}
void gotoxy(int x, int y)
{
COORD CursorPosition;
CursorPosition.X = x;
CursorPosition.Y = y;
SetConsoleCursorPosition(hConsole, CursorPosition);
}