amiconf.h

Go to the documentation of this file.
00001 /*      SCCS Id: @(#)amiconf.h  3.4     2000/01/12      */
00002 /* Copyright (c) Kenneth Lorber, Bethesda, Maryland, 1990, 1991, 1992, 1993. */
00003 /* NetHack may be freely redistributed.  See license for details. */
00004 
00005 #ifndef AMICONF_H
00006 #define AMICONF_H
00007 
00008 #undef abs              /* avoid using macro form of abs */
00009 #ifndef __SASC_60
00010 # undef min             /* this gets redefined */
00011 # undef max             /* this gets redefined */
00012 #endif
00013 
00014 #include <time.h>       /* get time_t defined before use! */
00015 
00016 #ifdef __SASC_60        /* since SAS can prevent re-inclusion */
00017 #include <stdlib.h>     /* general things, including builtins */
00018 #include <string.h>
00019 #endif
00020 
00021 #ifdef AZTEC_50
00022 #include <stdlib.h>
00023 # define AZTEC_C_WORKAROUND /* Bug which turns up in sounds.c. Bummer... */
00024 # define NO_SIGNAL      /* 5.0 signal handling doesn't like SIGINT... */
00025 #endif
00026 
00027 #ifdef _DCC
00028 #include <stdlib.h>
00029 # define _SIZE_T
00030 # define DCC30_BUG      /* A bitfield bug (from dog.c, others) in DICE 3.0. */
00031 #endif
00032 
00033 #ifndef __GNUC__
00034 typedef long off_t;
00035 #endif
00036 
00037 #define MICRO           /* must be defined to allow some inclusions */
00038 
00039 #define NOCWD_ASSUMPTIONS       /* Allow paths to be specified for HACKDIR,
00040                                    LEVELDIR, SAVEDIR, BONESDIR, DATADIR,
00041                                    SCOREDIR, LOCKDIR, CONFIGDIR, and TROUBLEDIR */
00042 
00043 /* data librarian defs */
00044 #ifndef NOCWD_ASSUMPTIONS
00045 # define DLBFILE        "NetHack:nhdat"         /* main library */
00046 # define DLBFILE2       "NetHack:nhsdat"        /* sound library */
00047 #else
00048 # define DLBFILE        "nhdat"                 /* main library */
00049 # define DLBFILE2       "nhsdat"                /* sound library */
00050 #endif
00051 
00052 #define FILENAME_CMP    stricmp                 /* case insensitive */
00053 
00054 #ifndef __SASC_60
00055 # define O_BINARY       0
00056 #endif
00057 
00058 /* Compile in New Intuition look for 2.0 */
00059 #ifdef  IDCMP_CLOSEWINDOW
00060 # ifndef INTUI_NEW_LOOK
00061 #  define       INTUI_NEW_LOOK  1
00062 # endif
00063 #endif
00064 
00065 #define MFLOPPY         /* You'll probably want this; provides assistance
00066                          * for typical personal computer configurations
00067                          */
00068 #define RANDOM
00069 
00070 /* ### amidos.c ### */
00071 
00072 extern void  FDECL(nethack_exit, (int));
00073 
00074 /* ### amiwbench.c ### */
00075 
00076 extern void NDECL(ami_wbench_init);
00077 extern void NDECL(ami_wbench_args);
00078 extern int FDECL(ami_wbench_getsave, (int));
00079 extern void FDECL(ami_wbench_unlink, (char *));
00080 extern int FDECL(ami_wbench_iconsize, (char *));
00081 extern void FDECL(ami_wbench_iconwrite, (char *));
00082 extern int FDECL(ami_wbench_badopt, (const char *));
00083 extern void NDECL(ami_wbench_cleanup);
00084 extern void FDECL(getlind, (const char *,char *,const char *));
00085 
00086 /* ### winreq.c ### */
00087 
00088 extern void amii_setpens(int);
00089 
00090 extern void FDECL(exit, (int));
00091 extern void NDECL(CleanUp);
00092 extern void FDECL(Abort, (long));
00093 extern int NDECL(getpid);
00094 extern char *FDECL(CopyFile, (const char *, const char *));
00095 extern int NDECL(kbhit);
00096 extern int NDECL(WindowGetchar);
00097 extern void FDECL(ami_argset, (int *, char *[]));
00098 extern void FDECL(ami_mkargline, (int *, char **[]));
00099 extern void ami_wininit_data(void);
00100 
00101 #define FromWBench 0 /* A hint for compiler ... */
00102 /* extern boolean FromWBench;   /* how were we run? */
00103 extern int ami_argc;
00104 extern char **ami_argv;
00105 
00106 #ifndef MICRO_H
00107 #include "micro.h"
00108 #endif
00109 
00110 #ifndef PCCONF_H
00111 #include "pcconf.h"     /* remainder of stuff is almost same as the PC */
00112 #endif
00113 
00114 #define remove(x)       unlink(x)
00115 
00116 /* DICE wants rewind() to return void.  We want it to return int. */
00117 #if defined(_DCC) || defined(__GNUC__)
00118 # define rewind(f)      fseek(f, 0, 0)
00119 #endif
00120 
00121 #ifdef AZTEC_C
00122 extern FILE *FDECL(freopen, (const char *, const char *, FILE *));
00123 extern char *FDECL(gets, (char *));
00124 #endif
00125 
00126 #define msmsg           printf
00127 
00128 /*
00129  * If AZTEC_C  we can't use the long cpath in vision.c....
00130  */
00131 #ifdef AZTEC_C
00132 # undef MACRO_CPATH
00133 #endif
00134 
00135 /*
00136  *  (Possibly) configurable Amiga options:
00137  */
00138 
00139 #define TEXTCOLOR               /* Use colored monsters and objects */
00140 #define HACKFONT                /* Use special hack.font */
00141 #define SHELL                   /* Have a shell escape command (!) */
00142 #define MAIL                    /* Get mail at unexpected occasions */
00143 #define DEFAULT_ICON "NetHack:default.icon"     /* private icon */
00144 #define AMIFLUSH                /* toss typeahead (select flush in .cnf) */
00145 /* #define OPT_DISPMAP          /* enable fast_map option */
00146 
00147 /* new window system options */
00148                         /* WRONG - AMIGA_INTUITION should go away */
00149 #ifdef AMII_GRAPHICS
00150 # define AMIGA_INTUITION        /* high power graphics interface (amii) */
00151 #endif
00152 
00153 #define CHANGE_COLOR    1
00154 
00155 #ifdef  TEXTCOLOR
00156 #  define       DEPTH   6       /* Maximum depth of the screen allowed */
00157 #else
00158 # define        DEPTH   2       /* Four colors...sigh... */
00159 #endif
00160 
00161 #define AMII_MAXCOLORS  (1L<<DEPTH)
00162 typedef unsigned short AMII_COLOR_TYPE;
00163 
00164 #define PORT_HELP       "nethack:amii.hlp"
00165 
00166 #undef  TERMLIB
00167 
00168 #define AMII_MUFFLED_VOLUME     40
00169 #define AMII_SOFT_VOLUME        50
00170 #define AMII_OKAY_VOLUME        60
00171 #define AMII_LOUDER_VOLUME      80
00172 
00173 #ifdef TTY_GRAPHICS
00174 # define ANSI_DEFAULT
00175 #endif
00176 
00177 extern int amibbs;      /* BBS mode? */
00178 
00179 #ifdef AMII_GRAPHICS
00180 extern int amii_numcolors;
00181 void FDECL( amii_setpens, (int) );
00182 #endif
00183 
00184 /* for cmd.c: override version in micro.h */
00185 #ifdef __SASC_60
00186 # undef M
00187 # define M(c) ((c) - 128 )
00188 #endif
00189 
00190 #endif /* AMICONF_H */