typedef signed long int sdiword;\r
\r
typedef enum {false,true} boolean;\r
+typedef enum {ichi,ni,san,yon,go,roku,shichi,hachi,kyu,ju,juichi,juni,jusan,juyon,jugo,juroku} nibble;\r
+//typedef unsigned nibb:4 nibble;\r
+\r
+#define HI_NIBBLE(b) (((b) >> 4) & 0x0F)\r
+#define LO_NIBBLE(b) ((b) & 0x0F)\r
/*typedef unsigned memseg;\r
\r
memptr should be replaced by memseg in code.\r
#ifdef __WATCOMC__\r
#define _argv __argv\r
#define _argc __argc\r
+\r
+//from http://www.verycomputer.com/3_65d875cc818b54ec_1.htm\r
+void clrscr(void);\r
+#pragma aux clrscr= \\r
+ " mov ah, 0fh " \\r
+ " int 10h " \\r
+ " xor ah, ah " \\r
+ " int 10h " ;\r
+//from http://stackoverflow.com/questions/18425748/gotoxy-function-using-printf-s-position\r
+inline void gotoxy(int x,int y)\r
+{\r
+ printf("\x1B[%d;%df", y, x);\r
+ fflush(stdout); // @jxh\r
+}\r
#endif\r
\r
#endif/*_TYPE_H_*/\r