// DEBUG - there are more globals
//
-#include "16_in.h"
-
-// Global variables
- boolean JoystickCalibrated=false; // MDM (GAMERS EDGE) - added
- ControlType ControlTypeUsed; // MDM (GAMERS EDGE) - added
-
- boolean Keyboard[NumCodes],
- JoysPresent[MaxJoys],
- MousePresent;
- boolean Paused;
- char LastASCII;
- ScanCode LastScan;
- KeyboardDef KbdDefs[MaxKbds] = {{0x1d,0x38,0x47,0x48,0x49,0x4b,0x4d,0x4f,0x50,0x51}};
- JoystickDef JoyDefs[MaxJoys];
- ControlType Controls[MaxPlayers];
-
-#ifdef DEMO0
- Demo DemoMode = demo_Off;\r
- byte __segment *DemoBuffer;\r
- word DemoOffset,DemoSize;
-#endif
-
-// Internal variables
-static boolean IN_Started;
-static boolean CapsLock;
-static ScanCode CurCode,LastCode;
-static byte far ASCIINames[] = // Unshifted ASCII for scan codes
- {
-// 0 1 2 3 4 5 6 7 8 9 A B C D E F
- 0 ,27 ,'1','2','3','4','5','6','7','8','9','0','-','=',8 ,9 , // 0
- 'q','w','e','r','t','y','u','i','o','p','[',']',13 ,0 ,'a','s', // 1
- 'd','f','g','h','j','k','l',';',39 ,'`',0 ,92 ,'z','x','c','v', // 2
- 'b','n','m',',','.','/',0 ,'*',0 ,' ',0 ,0 ,0 ,0 ,0 ,0 , // 3
- 0 ,0 ,0 ,0 ,0 ,0 ,0 ,'7','8','9','-','4','5','6','+','1', // 4
- '2','3','0',127,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 , // 5
- 0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 , // 6
- 0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 ,0 // 7
- },
- far ShiftNames[] = // Shifted ASCII for scan codes
- {
-// 0 1 2 3 4 5 6 7 8 9 A B C D E F
- 0 ,27 ,'!','@','#','$','%','^','&','*','(',')','_','+',8 ,9 , // 0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 0
- *ScanNames[] = // Scan code names with single chars
- {
- "?","?","1","2","3","4","5","6","7","8","9","0","-","+","?","?",
- "Q","W","E","R","T","Y","U","I","O","P","[","]","|","?","A","S",
- "D","F","G","H","J","K","L",";","\"","?","?","?","Z","X","C","V",
- "B","N","M",",",".","/","?","?","?","?","?","?","?","?","?","?",
- "?","?","?","?","?","?","?","?","\xf","?","-","\x15","5","\x11","+","?",
- "\x13","?","?","?","?","?","?","?","?","?","?","?","?","?","?","?",
- "?","?","?","?","?","?","?","?","?","?","?","?","?","?","?","?",
- "?","?","?","?","?","?","?","?","?","?","?","?","?","?","?","?"
- }, // DEBUG - consolidate these
-#endif
-
- far ExtScanCodes[] = // Scan codes with >1 char names
- {
- 1,0xe,0xf,0x1d,0x2a,0x39,0x3a,0x3b,0x3c,0x3d,0x3e,
- 0x3f,0x40,0x41,0x42,0x43,0x44,0x57,0x59,0x46,0x1c,0x36,
- 0x37,0x38,0x47,0x49,0x4f,0x51,0x52,0x53,0x45,0x48,
- 0x50,0x4b,0x4d,0x00
- };
-#if 0
- *ExtScanNames[] = // Names corresponding to ExtScanCodes
- {
- "Esc","BkSp","Tab","Ctrl","LShft","Space","CapsLk","F1","F2","F3","F4",
- "F5","F6","F7","F8","F9","F10","F11","F12","ScrlLk","Enter","RShft",
- "PrtSc","Alt","Home","PgUp","End","PgDn","Ins","Del","NumLk","Up",
- "Down","Left","Right",""
- };
-#endif
-static Direction DirTable[] = // Quick lookup for total direction
- {
- dir_NorthWest, dir_North, dir_NorthEast,
- dir_West, dir_None, dir_East,
- dir_SouthWest, dir_South, dir_SouthEast
- };
-
-static void (*INL_KeyHook)(void);
-static void interrupt (*OldKeyVect)(void);
-
-static char *ParmStrings[] = {"nojoys","nomouse",nil};
+#include "src/lib/16_in.h"
// Internal routines