about summary refs log tree commit diff
path: root/include/platform/getch.h
diff options
context:
space:
mode:
authorNakidai <plaza521@inbox.ru>2024-07-05 07:16:05 +0300
committerNakidai <plaza521@inbox.ru>2024-07-05 07:19:48 +0300
commitaea40f3877e36e95f2a70e3eeb0569fd156e3841 (patch)
treee6bd202ac4e5499db3b9983fc46e3b880a20f5ff /include/platform/getch.h
parenta9c159f5f7bf3479c3236735960597b4bc36a204 (diff)
download3cl-aea40f3877e36e95f2a70e3eeb0569fd156e3841.tar.gz
3cl-aea40f3877e36e95f2a70e3eeb0569fd156e3841.zip
Add almost all
Only continue operation and "blocks" of code are left. Now I'm gonna
sleep

And yes, I understand that code need to be refactored, and if I will not
get bored with writing this thing I will rewrite it in a better way, cuz
now code is awful
Diffstat (limited to 'include/platform/getch.h')
-rw-r--r--include/platform/getch.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/include/platform/getch.h b/include/platform/getch.h
new file mode 100644
index 0000000..490b536
--- /dev/null
+++ b/include/platform/getch.h
@@ -0,0 +1,13 @@
+#ifndef __GETCH_H__
+#define __GETCH_H__
+
+#ifdef _WIN32
+#include <conio.h>
+#define getch _getche
+#else
+int getch(void);
+#endif /* _WIN32 */
+
+void getch_init(void);
+
+#endif /* __GETCH_H__ */