-+-+-+-+-+-+-+-+ START OF PART 25 -+-+-+-+-+-+-+-+ X month = date+4; date`5B7`5D=0; /* point to and NULL terminate month */ X X if (((hour>=8 && hour<17)) /* 8AM - 5PM */ X && strncmp("Sat",date,3)!=0 /* not a Saturday */ X && strncmp("Sun",date,3)!=0) /* not a Sunday */ X `7B X /* now check for a .holidays datafile */ X lflush(); X if (lopen(holifile) >= 0) X for ( ; ; ) X `7B X if ((p=lgetw())==0) break; X if (strlen(p)<6) continue; X if ((strncmp(p,month,3)==0) && (day==atoi(p+4)) && (year V==atoi(p+7))) X return(0); /* a holiday */ X `7D X lrclose(); lcreat((char*)0); X return(1); X `7D X return(0); X `7D X#endif TIMECHECK $ CALL UNPACK MAIN.C;1 24980147 $ create 'f' X# X# This is a makefile for OS/2 LARN V12.3 X# X# This is written for MSC V6.00; it assumes NMAKE. X# X# This could probably build a DOS larn also, if the definition X# of OS2LARN was removed from the cc command. X# X# XOBJ = obj\`20 XCDEFS = -DOS2LARN -DDGK -DMSDOS -DSYSV -DDGK_MSDOS -DNOVARARGS Xcc = cl $(CDEFS) -nologo -Zi -c -AL -Fo$(OBJ) X XOBJS = $(OBJ)action.obj $(OBJ)bill.obj \ X $(OBJ)config.obj $(OBJ)create.obj \ X $(OBJ)data.obj $(OBJ)diag.obj \ X $(OBJ)display.obj $(OBJ)fgetlr.obj \ X $(OBJ)fortune.obj $(OBJ)global.obj \ X $(OBJ)help.obj $(OBJ)io.obj \ X $(OBJ)main.obj $(OBJ)monster.obj \ X $(OBJ)moreobj.obj $(OBJ)movem.obj \ X $(OBJ)msdos.obj $(OBJ)nap.obj \ X $(OBJ)object.obj $(OBJ)regen.obj \ X $(OBJ)savelev.obj $(OBJ)scores.obj \ X $(OBJ)signal.obj $(OBJ)spells.obj \ X $(OBJ)spheres.obj $(OBJ)store.obj \ X $(OBJ)tgetent.obj $(OBJ)tgetstr.obj \ X $(OBJ)tgoto.obj $(OBJ)tputs.obj \ X $(OBJ)tok.obj $(OBJ)vms.obj`09 \ X $(OBJ)iventory.obj X Xlarn.exe : $(OBJS) X link /CODEVIEW @os2larn.lnk X X$(OBJ)action.obj : action.c X $(cc) action.c X X$(OBJ)bill.obj : bill.c X $(cc) bill.c X X$(OBJ)config.obj : config.c X $(cc) config.c X X$(OBJ)create.obj : create.c X $(cc) create.c X X$(OBJ)data.obj : data.c X $(cc) data.c X X$(OBJ)diag.obj : diag.c X $(cc) diag.c X X$(OBJ)display.obj : display.c X $(cc) display.c X X$(OBJ)fgetlr.obj : fgetlr.c X $(cc) fgetlr.c X X$(OBJ)fortune.obj : fortune.c X $(cc) fortune.c X X$(OBJ)global.obj : global.c X $(cc) global.c X X$(OBJ)help.obj : help.c X $(cc) help.c X X$(OBJ)io.obj : io.c X $(cc) io.c X X$(OBJ)iventory.obj : iventory.c X $(cc) iventory.c X X$(OBJ)main.obj : main.c X $(cc) main.c X X$(OBJ)monster.obj : monster.c X $(cc) monster.c X X$(OBJ)moreobj.obj : moreobj.c X $(cc) moreobj.c X X$(OBJ)movem.obj : movem.c X $(cc) movem.c X X$(OBJ)msdos.obj : msdos.c X $(cc) msdos.c X X$(OBJ)nap.obj : nap.c X $(cc) nap.c X X$(OBJ)object.obj : object.c X $(cc) object.c X X$(OBJ)regen.obj : regen.c X $(cc) regen.c X X$(OBJ)savelev.obj : savelev.c X $(cc) savelev.c X X$(OBJ)scores.obj : scores.c X $(cc) scores.c X X$(OBJ)signal.obj : signal.c X $(cc) signal.c X X$(OBJ)spells.obj : spells.c X $(cc) spells.c X X$(OBJ)spheres.obj : spheres.c X $(cc) spheres.c X X$(OBJ)store.obj : store.c X $(cc) store.c X X$(OBJ)tgetent.obj : tgetent.c X $(cc) tgetent.c X X$(OBJ)tgetstr.obj : tgetstr.c X $(cc) tgetstr.c X X$(OBJ)tgoto.obj : tgoto.c X $(cc) tgoto.c X X$(OBJ)tputs.obj : tputs.c X $(cc) tputs.c X X$(OBJ)tok.obj : tok.c X $(cc) tok.c X X$(OBJ)vms.obj : vms.c X $(cc) vms.c $ CALL UNPACK MAKEFILE.OS2;1 863588168 $ create 'f' X############################################################################ X# X# A list of available compile-time defines: X# X# BSD - use BSD specific features (mostly timer and signal stuff V) X# BSD4.1 - use BSD4.1 to avoid some 4.2 dependencies (must be used V with X# BSD above; do not mix with SYSV) X# DECRainbow - DEC Rainbow specific display code. X# DOCHECKPOINTS - if not defined, checkpoint files are periodically writte Vn X# by the larn process (no forking) if enabled in the .larn Vopts X# description file. Checkpointing is handy on an unreliab Vle X# system, but takes CPU. Inclusion of DOCHECKPOINTS will c Vause X# fork()ing to perform the checkpoints (again if enabled i Vn X# the .larnopts file). This usually avoids pauses in larn X# while the checkpointing is being done (on large machines V). X# EXTRA - incorporates code to gather additional performance stats X# FLUSHNO=# - Set the input queue excess flushing threshold (default 5 V) X# HIDEBYLINK - if defined, the program attempts to hide from ps X# MACRORND - Define to use macro version of rnd() and rund() (fast & V big) X# MAIL - system supports mail messages (see bill.c). Not useful V on X# non-networked machines. X# MSDOS - MS-DOS specific code. X# OS2LARN - OS/2 Specific code. MSDOS must be defined. X# NONAP - causes napms() to return immediately instead of delaying X# n milliseconds. This define may be needed on some syste Vms X# if the nap stuff does not work correctly (possible hang) V. X# nap() is primarilly used to delay for effect when castin Vg X# missile type spells. X# NOVARARGS - Define for systems that don't have varargs (a default X# varargs will be used). X# RFCMAIL - mail messages are RFC822 conformant. Must be used with X# MAIL above. X# SAVEINHOME - put save files in users HOME instead of LARNHOME (defaul Vt) X# SIG_RETURNS_INT - define if signal() returns (int *)() instead of X# (void *)() X# SYSV - use system III/V (instead of V7) type ioctl calls X# TIMECHECK - incorporates code to disable play during working hours ( V8-5) X# UIDSCORE - Define to use user id's to manage scoreboard. Leaving t Vhis X# out will cause player id's from the file ".playerids" to X# be used instead. (.playerids is created upon demand). X# Only one entry per id # is allowed in each scoreboard X# (winning & non-winning). X# VT100 - Compile for using vt100 family of terminals. Omission o Vf X# this define will cause larn to use termcap. X# WIZID=xxx - this is the userid (or playerid) of the wizard. Default V is X# zero (superuser), which disables all wizard functions. X# Players must have this userid (or playerid) in order to X# become the non-scoring wizard player. Definition of WIZ VID X# to non-zero will enable the special wizard debugging X# commands. For root to become wizard, use WIZID= -1. X# X############################################################################ X# X# Configuration options X# LARNHOME is the directory where the larn data files will be installed. X# BINDIR is the directory where the larn binary will be installed. X# XLARNHOME = # The current directory unless changed in larn.opt XBINDIR = c:\games XCC= tcc XOPTIONS = -DSYSV -DMSDOS -DNOVARARGS X X######################################################################## X# XOBJS= action.obj \ X bill.obj \ X config.obj \ X create.obj \ X data.obj \ X diag.obj \ X display.obj \ X fgetlr.obj \ X fortune.obj \ X global.obj \ X help.obj \ X iventory.obj\ X io.obj \ X main.obj \ X monster.obj \ X moreobj.obj \ X movem.obj \ X msdos.obj \ X nap.obj \ X object.obj \ X regen.obj \ X savelev.obj \ X scores.obj \ X signal.obj \ X spheres.obj \ X spells.obj \ X store.obj \ X tgetent.obj \ X tgetstr.obj \ X tgoto.obj \ X tok.obj \ X tputs.obj \ X vms.obj X XDOTFILES= larn.hlp larn.maz larn.ftn # larn.opt X X# merge literal strings X# large memory model X# include file directory pointer X# use extended memory during compile X# XFLAGS= $(OPTIONS) -d -ml -I\TCPP\INCLUDE -Qx X X# case-sensitive link, no map file X# Xlarn: larn123.exe Xlarn123.exe: $(OBJS) X tlink \TCPP\LIB\C0L @tlink.rsp, larn123,,\TCPP\LIB\EMU \TCPP\LIB\MATHL \ VTCPP\LIB\CL /c /x X X.c.obj: X $(CC) -c $(FLAGS) $< X Xaction.obj: action.c header.h larndefs.h monsters.h objects.h player.h Xbill.obj: bill.c header.h larndefs.h Xconfig.obj: config.c header.h larndefs.h Xcreate.obj: create.c header.h larndefs.h monsters.h objects.h player.h Xdata.obj: data.c header.h monsters.h objects.h Xdiag.obj: diag.c header.h larndefs.h monsters.h objects.h player.h Xdisplay.obj: display.c header.h larndefs.h objects.h player.h Xfgetlr.obj: fgetlr.c Xfortune.obj: fortune.c header.h Xglobal.obj: global.c header.h larndefs.h monsters.h objects.h player.h Xhelp.obj: help.c header.h larndefs.h Xiventory.obj: iventory.c header.h larndefs.h objects.h player.h Xio.obj: io.c header.h larndefs.h Xmain.obj: main.c header.h larndefs.h monsters.h objects.h player.h p Vatchlev.h Xmonster.obj: monster.c header.h larndefs.h monsters.h objects.h player.h Xmoreobj.obj: moreobj.c header.h larndefs.h monsters.h objects.h player.h Xmovem.obj: movem.c header.h larndefs.h monsters.h objects.h player.h Xmsdos.obj: msdos.c header.h larndefs.h Xnap.obj: nap.c Xobject.obj: object.c header.h larndefs.h monsters.h objects.h player.h Xregen.obj: regen.c header.h larndefs.h monsters.h player.h Xsavelev.obj: savelev.c header.h larndefs.h Xscores.obj: scores.c header.h larndefs.h monsters.h objects.h player.h Xsignal.obj: signal.c header.h larndefs.h Xspheres.obj: spheres.c header.h larndefs.h monsters.h objects.h player.h Xspells.obj: spells.c header.h larndefs.h monsters.h objects.h player.h Xstore.obj: store.c header.h larndefs.h objects.h player.h Xtgetent.obj: tgetent.c Xtgetstr.obj: tgetstr.c Xtgoto.obj: tgoto.c Xtok.obj: tok.c header.h larndefs.h monsters.h objects.h player.h Xtputs.obj: tputs.c Xvms.obj: vms.c header.h larndefs.h X Xinstall: X exepack larn123.exe $(BINDIR)\larn123.exe X exemod $(BINDIR)\larn123.exe /max 1 $ CALL UNPACK MAKEFILE.PC;1 269407917 $ create 'f' X# XOBJ=`09action.o bill.o config.o create.o data.o diag.o display.o \ X`09fortune.o global.o help.o io.o iventory.o main.o monster.o \ X`09moreobj.o movem.o msdos.o nap.o object.o regen.o savelev.o \ X`09scores.o signal.o spells.o spheres.o store.o \ X`09tok.o vms.o X# X# X X# Add -DSIG_RTNS_INT to the CFLAGS line for older Unixes that return X# int ptr rather than void ptr from the call to signal(). X# XCFLAGS= -DBSD -D'LARNHOME="/usr/users/routley/larncc/"' X Xlarn123: $(OBJ) X`09cc -o larn123 $(OBJ) -ltermcap X X.c.o:`20 X`09cc $(CFLAGS) -c $*.c`20 X X.c: header.h larndefs.h player.h monsters.h objects.h patchlev.h X $ CALL UNPACK MAKEFILE.UNIX;1 620984197 $ create 'f' X File Name`09`09Archive #`09Description X----------------------------------------------------------- X MANIFEST 1`09This shipping list X Makefile.unix 2`09Makefile for U*ix. X README 1`09General readme X action.c 9`09 X bill.c 8`09 X config.c 12`09 X create.c 8`09 X data.c 4`09 X descrip.mms 12`09MMS build file for VAX/VMS X diag.c 9`09 X display.c 5`09 X fgetlr.c 12`09Termcap support for VMS/MS-DOS. X fortune.c 10`09 X global.c 2`09 X header.h 12`09 X help.c 12`09 X io.c 3`09 X iventory.c 10`09 X larn.ftn 12`09Fortune File X larn.maz 7`09Maze file X larn.opt 12`09Sample options file. Rename to .larnopts fo Vr U*ix. X larn123.doc 7`09Documentation for Larn V12.3 X larn123.fix 11`09List of changes since Larn V12.0 X larndefs.h 12`09 X larnhlp.txt 9`09Help file without ansi escape sequences X larnhlp.uue 10`09Uuencoded help file with ansi escape sequenc Ves X main.c 1`09 X makefile.os2 12`09OS/2-Microsoft C Makefile X makefile.pc 11`09MS-DOS, Turbo C++ Makefile X monster.c 6`09 X monsters.h 9`09 X moreobj.c 3`09 X movem.c 4`09 X msdos.c 10`09MS-DOS Specific code. X nansi.doc 11`09Docs for NANSI.SYS, a MS-DOS ANSI.SYS replac Vement X nansisys.uue 12`09UUENCODED NANSI.SYS X nap.c 12`09 X object.c 2`09 X objects.h 12`09 X os2larn.def 5`09OS/2 Build support X os2larn.lnk 4`09OS/2 Build support X patchlev.h 3`09 X player.h 12`09 X regen.c 11`09 X savelev.c 12`09 X scores.c 8`09 X signal.c 11`09 X spells.c 6`09 X spheres.c 11`09 X store.c 5`09 X termcap.pc 5`09Termcap file for MS-DOS. X termcap.vms 12`09Termcap file for VMS. X tgetent.c 10`09Termcap support for VMS/MS-DOS. X tgetstr.c 11`09Termcap support for VMS/MS-DOS. X tgoto.c 1`09Termcap support for VMS/MS-DOS. X tlink.rsp 4`09Turbo C++ MS-DOS Build support X tok.c 9`09 X tputs.c 7`09Termcap support for VMS/MS-DOS. X vms.c 11`09VMS Specific code. X vmsreadme.txt 6`09VMS Specific Readme $ CALL UNPACK MANIFEST.;1 36763093 $ create 'f' X/* X * monster.c X * +-+-+-+-+-+-+-+- END OF PART 25 +-+-+-+-+-+-+-+-