Skip to content
Snippets Groups Projects
Commit e4fe05f7 authored by KosmX's avatar KosmX
Browse files

xd

parent 8cf2f863
No related branches found
No related tags found
No related merge requests found
...@@ -17,8 +17,10 @@ ...@@ -17,8 +17,10 @@
//This package is designed to do the basic operations like get char without waiting for enter or sleep //This package is designed to do the basic operations like get char without waiting for enter or sleep
//and be able to compile on multiple OS like linux and windows. //and be able to compile on multiple OS like linux and windows.
//returns the char or EOF
int getNextChar(){
//get next character if available }
struct Vec2i getWindowSize(){ struct Vec2i getWindowSize(){
......
...@@ -48,9 +48,14 @@ void xp3(){ ...@@ -48,9 +48,14 @@ void xp3(){
} }
void xp4(){ void xp4(){
Sleep(1000); int i;
char c = _getch(); char c;
printf("\nchar: %c\n", c); Sleep(5000);
while(_kbhit()){
c = getch();
printf("%c", c);
}
} }
int main(int argc, char const *argv[]) int main(int argc, char const *argv[])
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment