3 // ID_US.h - Header file for the User Manager
\r
5 // By Jason Blochowiak
\r
6 // Open Watcom port by sparky4
\r
12 #include "src/lib/16_head.h"
\r
15 #define __DEBUG_UserMgr__
\r
18 //#define HELPTEXTLINKED
\r
23 #define MaxHelpLines 500
\r
25 #define MaxHighName 57
\r
29 char name[MaxHighName + 1];
\r
31 word completed,episode;
\r
34 #define MaxGameName 32
\r
35 #define MaxSaveGames 6
\r
41 char name[MaxGameName + 1];
\r
44 #define MaxString 128 // Maximum input string size
\r
51 } WindowRec; // Record used to save & restore screen windows
\r
61 // Hack import for TED launch support
\r
62 extern boolean tedlevel;
\r
63 extern int tedlevelnum;
\r
64 extern void TEDDeath(void);
\r
66 extern boolean ingame, // Set by game code if a game is in progress
\r
67 abortgame, // Set if a game load failed
\r
68 loadedgame, // Set if the current game was loaded
\r
71 extern char *abortprogram; // Set to error msg if program is dying
\r
72 extern GameDiff restartgame; // Normally gd_Continue, else starts game
\r
73 extern word PrintX,PrintY; // Current printing location in the window
\r
74 extern word WindowX,WindowY,// Current location of window
\r
75 WindowW,WindowH;// Current size of window
\r
77 extern boolean Button0,Button1,
\r
79 extern int CursorX,CursorY;
\r
81 extern void (*USL_MeasureString)(char far *,word *,word *),
\r
82 (*USL_DrawString)(char far *);
\r
84 extern boolean (*USL_SaveGame)(int),(*USL_LoadGame)(int);
\r
85 extern void (*USL_ResetGame)(void);
\r
86 extern SaveGame Games[MaxSaveGames];
\r
87 extern HighScore Scores[];
\r
89 #define US_HomeWindow() {PrintX = WindowX; PrintY = WindowY;}
\r
91 extern void US_Startup(void),
\r
94 US_InitRndT(boolean randomize),
\r
95 US_SetLoadSaveHooks(boolean (*load)(int),
\r
96 boolean (*save)(int),
\r
97 void (*reset)(void)),
\r
98 US_TextScreen(void),
\r
99 US_UpdateTextScreen(void),
\r
100 US_FinishTextScreen(void),
\r
101 US_DrawWindow(word x,word y,word w,word h),
\r
102 US_CenterWindow(word,word),
\r
103 US_SaveWindow(WindowRec *win),
\r
104 US_RestoreWindow(WindowRec *win),
\r
105 US_ClearWindow(void),
\r
106 US_SetPrintRoutines(void (*measure)(char far *,word *,word *),
\r
107 void (*print)(char far *)),
\r
108 US_PrintCentered(char far *s),
\r
109 US_CPrint(char far *s),
\r
110 US_CPrintLine(char far *s),
\r
111 US_Print(char far *s),
\r
112 US_PrintUnsigned(word n),
\r
113 US_PrintSigned(long n),
\r
114 US_StartCursor(void),
\r
115 US_ShutCursor(void),
\r
116 US_CheckHighScore(long score,word other),
\r
117 US_DisplayHighScores(int which);
\r
118 extern boolean US_UpdateCursor(void),
\r
119 US_LineInput(int x,int y,char *buf,char *def,boolean escok,
\r
120 int maxchars,int maxwidth);
\r
121 extern int US_CheckParm(char *parm,char **strings),
\r
124 void USL_PrintInCenter(char far *s,Rect r);
\r
125 char *USL_GiveSaveName(word game);
\r