\r
#include "src/lib/16_head.h"\r
\r
-/* Function: Wait **********************************************************\r
-*\r
-* Parameters: wait - time in microseconds\r
-*\r
-* Description: pauses for a specified number of microseconds.\r
-*\r
-*/\r
-void wait(clock_t wait){\r
- clock_t goal;\r
-\r
- if(!wait) return;\r
-\r
- goal = wait + clock();\r
- while((goal > clock()) && !kbhit()) ;\r
-} /* End of wait */\r
-\r
long int\r
filesize(FILE *fp)\r
{\r
return(-1);\r
}\r
\r
-//===========================================================================\r
-\r
-/*\r
-==========================\r
-=\r
-= Quit\r
-=\r
-==========================\r
-*/\r
-\r
-void Quit (char *error)\r
-{\r
- unsigned finscreen;\r
- memptr screen;\r
- union REGS in, out;\r
-\r
- //ClearMemory ();\r
- if (!*error)\r
- {\r
- //WriteConfig ();\r
- }\r
- else\r
- {\r
- //CA_CacheGrChunk (ERRORSCREEN);\r
- //screen = grsegs[ERRORSCREEN];\r
- }\r
-\r
- //ShutdownId ();\r
- //IN_Shutdown();\r
- //modexLeave();\r
- in.h.ah = 0x00;\r
- in.h.al = 0x3;\r
- int86(0x10, &in, &out);\r
-\r
- if (error && *error)\r
- {\r
- movedata ((unsigned)screen,7,0xb800,0,7*160);\r
- //gotoxy (10,4);\r
- puts(error);\r
- //gotoxy (1,8);\r
- exit(1);\r
- }\r
- else\r
- if (!error || !(*error))\r
- {\r
- //clrscr();\r
- //#ifndef JAPAN\r
- movedata ((unsigned)screen,7,0xb800,0,4000);\r
- //gotoxy(1,24);\r
- //#endif\r
-//asm mov bh,0\r
-//asm mov dh,23 // row\r
-//asm mov dl,0 // collumn\r
-//asm mov ah,2\r
-//asm int 0x10\r
- }\r
-\r
- exit(0);\r
-}\r
-\r
-//===========================================================================\r
-\r
\r
byte dirchar(byte in)\r
{\r