home *** CD-ROM | disk | FTP | other *** search
Text File | 1993-09-03 | 54.6 KB | 1,498 lines |
- Newsgroups: comp.sources.x
- From: jck@kimba.catt.citri.edu.au (Justin Kibell)
- Subject: v20i123: xboing - a simple blockout type game, Part16/26
- Message-ID: <1993Sep3.123421.8010@sparky.sterling.com>
- X-Md4-Signature: 94fc5c49fbfb8771d9ffca189f68180a
- Sender: chris@sparky.sterling.com (Chris Olson)
- Organization: Sterling Software
- Date: Fri, 3 Sep 1993 12:34:21 GMT
- Approved: chris@sterling.com
-
- Submitted-by: jck@kimba.catt.citri.edu.au (Justin Kibell)
- Posting-number: Volume 20, Issue 123
- Archive-name: xboing/part16
- Environment: X11, xpm, color
-
- #! /bin/sh
- # This is a shell archive. Remove anything before this line, then feed it
- # into a shell via "sh file" or similar. To overwrite existing files,
- # type "sh file -c".
- # Contents: INSTALL Makefile.std sounds/shoot.au.uue stage.c
- # Wrapped by chris@sparky on Fri Sep 3 07:14:47 1993
- PATH=/bin:/usr/bin:/usr/ucb:/usr/local/bin:/usr/lbin ; export PATH
- echo If this archive is complete, you will see the following message:
- echo ' "shar: End of archive 16 (of 26)."'
- if test -f 'INSTALL' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'INSTALL'\"
- else
- echo shar: Extracting \"'INSTALL'\" \(9988 characters\)
- sed "s/^X//" >'INSTALL' <<'END_OF_FILE'
- X XBoing Installation
- X ===================
- X
- X 6th August 1993
- X
- XRequirements
- X------------
- X
- X- You must be using X11R4 or X11R5. It may work on X11R3 but cannot test it!
- X- You must have the XPM pixmap library. The XPM library can be obtained from
- X the following sites:-
- X
- X avahi.inria.fr (138.96.24.30) - Latest revision. (Europe) V3.2g
- X - in /pub/xpm
- X export.lcs.mit.edu (18.30.0.238) - Latest revision. (America) V3.2g
- X - in /contrib
- X archie.au (139.130.4.6) - Latest revision. (Australia) V3.2g
- X - in /X11/contrib
- X
- X I have been successfully using version 3.2f, or version 3.2g. I haven't
- X tried any lower versions. The author of XPM is lehors@sophia.inria.fr
- X I suggest you use 3.2g as it has had the best reports. Any lower?
- X
- X- v1.6 has now been compiled and works on the following machines :-
- X
- X + SunOS 4.1.2 5 sun4c/sun4m
- X + SunOS Solaris 2.2 LX
- X + IRIX 4.0.5G 12171207 IP7
- X + SGI 310/GTX
- X + HP 9000/720 HP-UX 8.07
- X + DEC 2100
- X + DEC OSF/1 AXP
- X + DECstation 5000/133 ULTRIX 4.2 0 RISC
- X + AIX 3.2.3e rs6000/350
- X + NetBSD on i486
- X + Linux on i486.
- X + Intel 486 ESIX 4.0.4 X11R4
- X
- X- You must have a colour display. Sorry to all those B&W dudes.
- X
- X- An ANSI compiler would be nicer however I spent ages changing code with
- X all those lovely #ifdefs so you can use a non-ansi compiler. :-)
- X
- X- This game DOES NOT need Motif or Xt or anything except pure XLib.
- X
- X- The xnews Sun X server is not the quickest with this game. Be warned.
- X
- X
- XMakefiles
- X---------
- X
- XIncluded in this package is an Imakefile which generates a Makefile that will
- Xcompile XBoing using your system setup. For those people without imake, or
- Xwho can't get it to compile, a Makefile.std is also included.
- X
- X
- XCompilation
- X-----------
- X
- XEdit the Imakefile or the Makefile.std and change the default compiler to
- Xyour compiler. Also change the compiler flags if necessary.
- X
- XGo into the bitmaps directory and uudecode earth.xpm.Z.uue and then
- Xuncompress the resultant file.
- X
- XChange the $(XBOING_DIR) to point to the place where xboing is to be
- Xinstalled. In that directory xboing will create the highscore file and also
- Xplace the level data and sound data.
- X
- XNOTE: The user can now specify the sounds, level and highscore file locations
- X as environment variables. They are :-
- X
- XXBOING_SCORE_FILE = the highscore file to be used.
- XXBOING_LEVELS_DIR = the directory containing the levels.
- XXBOING_SOUND_DIR = the directory containing the sounds.
- X
- XAlso set the AUDIO_AVAILABLE flag to True or False to enable the audio in
- Xthe game if possible.
- X
- XCopy the desired audio code from audio directory to audio.c as listed below:-
- X LINUXaudio.c - SoundBlaster support on Linux for PC
- X SUNaudio.c - Sun workstation audio
- X NCDaudio.c - NCD xterminal sound server support
- X HPaudio.c - HP audio which is .au format?
- X NOaudio.c - Default - no audio support file.
- X
- XThe default will be no audio at all. ie: NOaudio.c
- X
- XPlease work on NOaudio.c if you have another machine that you want to post
- Xthe sound too. Note that I am not going to support and other file format than
- X.au as I'll have sound files everywhere. :-)
- X
- XIf you are on a Sun SparcStation and you want sound then copy SUNaudio.c to
- Xaudio.c and the sound routines should work. I hope.
- X
- XIf you have imake, type:
- X
- X xmkmf
- X make depend
- X make all
- X
- XX11R5 users can type 'xmkmf -a ; make all' if they like.
- X
- XIf you do not have imake, type:
- X
- X cp Makefile.std Makefile
- X make depend
- X make all
- X
- X
- XInstallation
- X------------
- X
- XTry 'xboing -setup' and see if the compilation has gone as you planned.
- XThis option will print out useful information about where xboing will look
- Xfor its data files.
- X
- XPlease note that you must be root to install the game. If you are not root
- Xthen you can just run XBoing from your own account.
- X
- XDon't forget to set the $(XBOING_DIR) in the Makefile/Imakefile and re-compile
- Xif you don't like where it will be installed.
- X
- XFor imake users, type:
- X
- X make install - install XBoing binary.
- X make install.man - install the manual page.
- X
- XIf you do not have imake then you must first edit the Makefile.std to check
- Xthat where you want the program to be installed.
- X
- X make install - install XBoing binary.
- X make install.man - install the manual page.
- X
- XYou should now have XBoing installed and it's manual page. If not, then please
- Xread Troubleshooting.
- X
- X
- XHighScore File
- X--------------
- X
- XIt is automatically created and chmoded to 0666. There will also be a personal
- Xhighscore file saved in each users account home directory. This keeps their
- Xpersonal highscores. If you have problems then touch one and chmod it to
- Xsomething that will work for you. ie: rw for all.
- X
- XNOTE: **** The highscore file format has changed since v1.5. Any old ones
- X will barf! Global files have one entry now. Just erase them please.
- X
- XTroubleshooting
- X---------------
- X
- XI was hoping you wouldn't be reading this but anyway ...
- X
- Xmake depend
- X
- X Some header files in xboing were not found. Check the includes and see
- X if the Imakefile/Makefile.std includes in the correct directory. If all
- X else fails then xmkmf/cp Ma..std Makefile again and forget it.
- X
- Xxpm.h
- X
- X You must have the Xpm library as explained in the requirements section.
- X XBoing uses the Xpm library extensively. If you have it then please check
- X that the XPMINCLUDE dir is set correctly in the Imakefile/Makefile.std
- X
- XHeader Files
- X
- X Maybe you have the X11 header files in another place. Please check the
- X Imakefile or Makefile.std and change the -I directories to your site.
- X If you are using imake then tell your sysop that imake didn't look
- X in the correct place for the X11 header files.
- X
- XHighscore file is corrupt
- X
- X I have changed the highscore file format since v1.5. Sorry but it is
- X much better now and will save times etc. Just delete the old one and
- X start again. The file locking will not work over NFS.
- X
- XStrange libraries needed
- X
- X Check the Imakefile or Makefile.std and make sure the sysop has installed
- X the Imake.rules correctly. If all else fails just remove them one by one
- X until it compiles.
- X
- XCrashes with bad drawable
- X
- X Make sure that the program is not compiled with -ansi as ansi trigraphs
- X may have been found during compilation and that stuffs up the pixmap data.
- X
- XColourmap is all black
- X
- X Don't use the -pointergrab option as some window managers barf when the
- X pointer is grabbed :-(
- X
- XSound not working & Levels not working
- X
- X Check your sound directory and make sure that you don't have any ENV vars
- X set that will be used first.
- X
- XAnsi trigraphs
- X
- X Try not to use -ansi as it can cause ANSI trigraphs in the data files and
- X that converts a few characters to one causing an XPM error. Bummer.
- X
- XIf you cannot get it working still and you have tried hard email at the
- Xaddress supplied and sen along 'xboing -setup' output, obviously if you have
- Xgot it compiled!!
- X
- XCopyright
- X---------
- X
- XXBoing:
- X
- X/*****************************************************************************
- X
- X (c) Copyright 1993, Justin C. Kibell, All Rights Reserved
- X email: jck@citri.edu.au
- X
- X Permission to use, copy, modify, and distribute this software and its
- X documentation without written agreement is hereby granted. You cannot sell
- X this software without written permission from the author. This entire
- X copyright notice must appear in all copies of this software.
- X
- X IN NO EVENT SHALL THE AUTHOR BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT,
- X SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF
- X THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE AUTHOR HAS BEEN ADVISED
- X OF THE POSSIBILITY OF SUCH DAMAGE.
- X
- X THE AUTHOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT LIMITED
- X TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- X PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE
- X AUTHOR HAS NO OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES,
- X ENHANCEMENTS, OR MODIFICATIONS.
- X
- X *****************************************************************************/
- X
- XXpm:
- X ----------------------------------------------------------------------------
- X/*
- X * Copyright 1990-93 GROUPE BULL
- X *
- X * Permission to use, copy, modify, and distribute this software and its
- X * documentation for any purpose and without fee is hereby granted, provided
- X * that the above copyright notice appear in all copies and that both that
- X * copyright notice and this permission notice appear in supporting
- X * documentation, and that the name of GROUPE BULL not be used in advertising
- X * or publicity pertaining to distribution of the software without specific,
- X * written prior permission. GROUPE BULL makes no representations about the
- X * suitability of this software for any purpose. It is provided "as is"
- X * without express or implied warranty.
- X *
- X * GROUPE BULL disclaims all warranties with regard to this software,
- X * including all implied warranties of merchantability and fitness,
- X * in no event shall GROUPE BULL be liable for any special,
- X * indirect or consequential damages or any damages
- X * whatsoever resulting from loss of use, data or profits,
- X * whether in an action of contract, negligence or other tortious
- X * action, arising out of or in connection with the use
- X * or performance of this software.
- X *
- X */
- X
- XArnaud LE HORS BULL Research FRANCE -- Koala Project
- X (XPM - X PixMap format version 2 & 3)
- X Internet: lehors@sophia.inria.fr
- XSurface Mail: Arnaud LE HORS, INRIA - Sophia Antipolis,
- X 2004, route des Lucioles, 06565 Valbonne Cedex -- FRANCE
- X Voice phone: (33) 93.65.77.71, Fax: (33) 93 65 77 66, Telex: 97 00 50 F
- X ----------------------------------------------------------------------------
- X
- X-------------------------------------------------------------------------------
- XJustin Kibell - jck@citri.edu.au - +61 3 282 2456 - Vic - Australia
- END_OF_FILE
- if test 9988 -ne `wc -c <'INSTALL'`; then
- echo shar: \"'INSTALL'\" unpacked with wrong size!
- fi
- # end of 'INSTALL'
- fi
- if test -f 'Makefile.std' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'Makefile.std'\"
- else
- echo shar: Extracting \"'Makefile.std'\" \(13670 characters\)
- sed "s/^X//" >'Makefile.std' <<'END_OF_FILE'
- X# Makefile generated by imake - do not edit!
- X# $XConsortium: imake.c,v 1.65 91/07/25 17:50:17 rws Exp $
- X#
- X# The cpp used on this machine replaces all newlines and multiple tabs and
- X# spaces in a macro expansion with a single space. Imake tries to compensate
- X# for this, but is not always successful.
- X#
- X
- X# -------------------------------------------------------------------------
- X# Makefile generated from "Imake.tmpl" and </tmp/IIf.a14933>
- X# $XConsortium: Imake.tmpl,v 1.139 91/09/16 08:52:48 rws Exp $
- X#
- X# Platform-specific parameters may be set in the appropriate <vendor>.cf
- X# configuration files. Site-specific parameters should be set in the file
- X# site.def. Full rebuilds are recommended if any parameters are changed.
- X#
- X# If your C preprocessor does not define any unique symbols, you will need
- X# to set BOOTSTRAPCFLAGS when rebuilding imake (usually when doing
- X# "make World" the first time).
- X#
- X
- X# -------------------------------------------------------------------------
- X# site-specific configuration parameters that need to come before
- X# the platform-specific parameters - edit site.def to change
- X
- X# site: $XConsortium: site.def,v 1.2 91/07/30 20:26:44 rws Exp $
- X
- X# -------------------------------------------------------------------------
- X# platform-specific configuration parameters - edit sun.cf to change
- X
- X# platform: $XConsortium: sun.cf,v 1.72.1.1 92/03/18 13:13:37 rws Exp $
- X
- X# operating system: SunOS 4.1.2
- X
- X# $XConsortium: sunLib.rules,v 1.7 91/12/20 11:19:47 rws Exp $
- X
- X# -------------------------------------------------------------------------
- X# site-specific configuration parameters that go after
- X# the platform-specific parameters - edit site.def to change
- X
- X# site: $XConsortium: site.def,v 1.2 91/07/30 20:26:44 rws Exp $
- X
- X SHELL = /bin/sh
- X
- X TOP = .
- X CURRENT_DIR = .
- X
- X AR = ar clq
- X BOOTSTRAPCFLAGS =
- X CC = cc
- X AS = as
- X
- X COMPRESS = compress
- X CPP = /lib/cpp $(STD_CPP_DEFINES)
- X PREPROCESSCMD = cc -E $(STD_CPP_DEFINES)
- X INSTALL = install
- X LD = ld
- X LINT = lint
- X LINTLIBFLAG = -C
- X LINTOPTS = -axz
- X LN = ln -s
- X MAKE = make
- X MV = mv
- X CP = cp
- X
- X RANLIB = ranlib
- X RANLIBINSTFLAGS =
- X
- X RM = rm -f
- X TROFF = psroff
- X MSMACROS = -ms
- X TBL = tbl
- X EQN = eqn
- X STD_INCLUDES =
- X STD_CPP_DEFINES =
- X STD_DEFINES =
- X EXTRA_LOAD_FLAGS =
- X EXTRA_LIBRARIES =
- X TAGS = ctags
- X
- X SHAREDCODEDEF = -DSHAREDCODE
- X SHLIBDEF = -DSUNSHLIB
- X
- X PROTO_DEFINES =
- X
- X INSTPGMFLAGS =
- X
- X INSTBINFLAGS = -m 0755
- X INSTUIDFLAGS = -m 4755
- X INSTLIBFLAGS = -m 0644
- X INSTINCFLAGS = -m 0444
- X INSTMANFLAGS = -m 0444
- X INSTDATFLAGS = -m 0444
- X INSTKMEMFLAGS = -g kmem -m 2755
- X
- X CDEBUGFLAGS = -O
- X CCOPTIONS = -pipe
- X
- X ALLINCLUDES = $(INCLUDES) $(EXTRA_INCLUDES) $(TOP_INCLUDES) $(STD_INCLUDES)
- X ALLDEFINES = $(ALLINCLUDES) $(STD_DEFINES) $(EXTRA_DEFINES) $(PROTO_DEFINES) $(DEFINES)
- X CFLAGS = $(CDEBUGFLAGS) $(CCOPTIONS) $(ALLDEFINES)
- X LINTFLAGS = $(LINTOPTS) -DLINT $(ALLDEFINES)
- X
- X LDLIBS = $(SYS_LIBRARIES) $(EXTRA_LIBRARIES)
- X
- X LDOPTIONS = $(CDEBUGFLAGS) $(CCOPTIONS) $(LOCAL_LDFLAGS)
- X
- X LDCOMBINEFLAGS = -X -r
- X DEPENDFLAGS =
- X
- X MACROFILE = sun.cf
- X RM_CMD = $(RM) *.CKP *.ln *.BAK *.bak *.o core errs ,* *~ *.a .emacs_* tags TAGS make.log MakeOut
- X
- X IMAKE_DEFINES =
- X
- X IRULESRC = $(CONFIGDIR)
- X IMAKE_CMD = $(IMAKE) -DUseInstalled -I$(IRULESRC) $(IMAKE_DEFINES)
- X
- X ICONFIGFILES = $(IRULESRC)/Imake.tmpl $(IRULESRC)/Imake.rules \
- X $(IRULESRC)/Project.tmpl $(IRULESRC)/site.def \
- X $(IRULESRC)/$(MACROFILE) $(EXTRA_ICONFIGFILES)
- X
- X# -------------------------------------------------------------------------
- X# X Window System Build Parameters
- X# $XConsortium: Project.tmpl,v 1.138.1.1 92/11/11 09:49:19 rws Exp $
- X
- X# -------------------------------------------------------------------------
- X# X Window System make variables; this need to be coordinated with rules
- X
- X PATHSEP = /
- X USRLIBDIR = /usr/lib
- X BINDIR = /usr/bin/X11
- X INCROOT = /usr/include
- X BUILDINCROOT = $(TOP)
- X BUILDINCDIR = $(BUILDINCROOT)/X11
- X BUILDINCTOP = ..
- X INCDIR = $(INCROOT)/X11
- X ADMDIR = /usr/adm
- X LIBDIR = $(USRLIBDIR)/X11
- X CONFIGDIR = $(LIBDIR)/config
- X LINTLIBDIR = $(USRLIBDIR)/lint
- X
- X FONTDIR = $(LIBDIR)/fonts
- X XINITDIR = $(LIBDIR)/xinit
- X XDMDIR = $(LIBDIR)/xdm
- X TWMDIR = $(LIBDIR)/twm
- X MANPATH = /usr/man
- X MANSOURCEPATH = $(MANPATH)/man
- X MANSUFFIX = n
- X LIBMANSUFFIX = 3
- X MANDIR = $(MANSOURCEPATH)$(MANSUFFIX)
- X LIBMANDIR = $(MANSOURCEPATH)$(LIBMANSUFFIX)
- X NLSDIR = $(LIBDIR)/nls
- X PEXAPIDIR = $(LIBDIR)/PEX
- X XAPPLOADDIR = $(LIBDIR)/app-defaults
- X FONTCFLAGS = -t
- X
- X INSTAPPFLAGS = $(INSTDATFLAGS)
- X
- X IMAKE = imake
- X DEPEND = makedepend
- X RGB = rgb
- X
- X FONTC = bdftopcf
- X
- X MKFONTDIR = mkfontdir
- X MKDIRHIER = /bin/sh $(BINDIR)/mkdirhier
- X
- X CONFIGSRC = $(TOP)/config
- X DOCUTILSRC = $(TOP)/doc/util
- X CLIENTSRC = $(TOP)/clients
- X DEMOSRC = $(TOP)/demos
- X LIBSRC = $(TOP)/lib
- X FONTSRC = $(TOP)/fonts
- X INCLUDESRC = $(TOP)/X11
- X SERVERSRC = $(TOP)/server
- X UTILSRC = $(TOP)/util
- X SCRIPTSRC = $(UTILSRC)/scripts
- X EXAMPLESRC = $(TOP)/examples
- X CONTRIBSRC = $(TOP)/../contrib
- X DOCSRC = $(TOP)/doc
- X RGBSRC = $(TOP)/rgb
- X DEPENDSRC = $(UTILSRC)/makedepend
- X IMAKESRC = $(CONFIGSRC)
- X XAUTHSRC = $(LIBSRC)/Xau
- X XLIBSRC = $(LIBSRC)/X
- X XMUSRC = $(LIBSRC)/Xmu
- X TOOLKITSRC = $(LIBSRC)/Xt
- X AWIDGETSRC = $(LIBSRC)/Xaw
- X OLDXLIBSRC = $(LIBSRC)/oldX
- X XDMCPLIBSRC = $(LIBSRC)/Xdmcp
- X BDFTOSNFSRC = $(FONTSRC)/bdftosnf
- X BDFTOSNFSRC = $(FONTSRC)/clients/bdftosnf
- X BDFTOPCFSRC = $(FONTSRC)/clients/bdftopcf
- X MKFONTDIRSRC = $(FONTSRC)/clients/mkfontdir
- X FSLIBSRC = $(FONTSRC)/lib/fs
- X FONTSERVERSRC = $(FONTSRC)/server
- X EXTENSIONSRC = $(TOP)/extensions
- X XILIBSRC = $(EXTENSIONSRC)/lib/xinput
- X PEXLIBSRC = $(EXTENSIONSRC)/lib/PEXlib
- X PHIGSLIBSRC = $(EXTENSIONSRC)/lib/PEX
- X
- X# $XConsortium: sunLib.tmpl,v 1.14.1.2 92/11/11 09:55:02 rws Exp $
- X
- XSHLIBLDFLAGS = -assert pure-text
- XPICFLAGS = -pic
- X
- X DEPEXTENSIONLIB =
- X EXTENSIONLIB = -lXext
- X
- X DEPXLIB = $(DEPEXTENSIONLIB)
- X XLIB = $(EXTENSIONLIB) -lX11
- X
- X DEPXMULIB = $(USRLIBDIR)/libXmu.sa.$(SOXMUREV)
- X XMULIBONLY = -lXmu
- X XMULIB = -lXmu
- X
- X DEPOLDXLIB =
- X OLDXLIB = -loldX
- X
- X DEPXTOOLLIB = $(USRLIBDIR)/libXt.sa.$(SOXTREV)
- X XTOOLLIB = -lXt
- X
- X DEPXAWLIB = $(USRLIBDIR)/libXaw.sa.$(SOXAWREV)
- X XAWLIB = -lXaw
- X
- X DEPXILIB =
- X XILIB = -lXi
- X
- X DEPPEXLIB =
- X PEXLIB = -lPEX5
- X
- X SOXLIBREV = 4.10
- X SOXTREV = 4.10
- X SOXAWREV = 5.0
- X SOOLDXREV = 4.10
- X SOXMUREV = 4.10
- X SOXEXTREV = 4.10
- X SOXINPUTREV = 4.10
- X SOPEXREV = 1.0
- X
- X DEPXAUTHLIB = $(USRLIBDIR)/libXau.a
- X XAUTHLIB = -lXau
- X DEPXDMCPLIB = $(USRLIBDIR)/libXdmcp.a
- X XDMCPLIB = -lXdmcp
- X
- X DEPPHIGSLIB = $(USRLIBDIR)/libphigs.a
- X PHIGSLIB = -lphigs
- X
- X DEPXBSDLIB = $(USRLIBDIR)/libXbsd.a
- X XBSDLIB = -lXbsd
- X
- X LINTEXTENSIONLIB = $(LINTLIBDIR)/llib-lXext.ln
- X LINTXLIB = $(LINTLIBDIR)/llib-lX11.ln
- X LINTXMU = $(LINTLIBDIR)/llib-lXmu.ln
- X LINTXTOOL = $(LINTLIBDIR)/llib-lXt.ln
- X LINTXAW = $(LINTLIBDIR)/llib-lXaw.ln
- X LINTXI = $(LINTLIBDIR)/llib-lXi.ln
- X LINTPEX = $(LINTLIBDIR)/llib-lPEX5.ln
- X LINTPHIGS = $(LINTLIBDIR)/llib-lphigs.ln
- X
- X DEPLIBS = $(DEPXAWLIB) $(DEPXMULIB) $(DEPXTOOLLIB) $(DEPXLIB)
- X
- X DEPLIBS1 = $(DEPLIBS)
- X DEPLIBS2 = $(DEPLIBS)
- X DEPLIBS3 = $(DEPLIBS)
- X
- X# -------------------------------------------------------------------------
- X# Imake rules for building libraries, programs, scripts, and data files
- X# rules: $XConsortium: Imake.rules,v 1.123 91/09/16 20:12:16 rws Exp $
- X
- X# -------------------------------------------------------------------------
- X# start of Imakefile
- X
- X#*****************************************************************************
- X#
- X# (c) Copyright 1993, Justin C. Kibell, All Rights Reserved
- X# email: jck@citri.edu.au
- X#
- X# Permission to use, copy, modify, and distribute this software and its
- X# documentation without written agreement is hereby granted. You cannot sell
- X# this software without written permission from the author. This entire
- X# copyright notice must appear in all copies of this software.
- X#
- X# IN 0 EVENT SHALL THE AUTHOR BE LIABLE TO ANY PARTY FOR DIRECT, INDIRECT,
- X# SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OF
- X# THIS SOFTWARE AND ITS DOCUMENTATION, EVEN IF THE AUTHOR HAS BEEN ADVISED
- X# OF THE POSSIBILITY OF SUCH DAMAGE.
- X#
- X# THE AUTHOR SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, BUT NOT LIMITED
- X# TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- X# PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS ON AN "AS IS" BASIS, AND THE
- X# AUTHOR HAS 0 OBLIGATION TO PROVIDE MAINTENANCE, SUPPORT, UPDATES,
- X# ENHANCEMENTS, OR MODIFICATIONS.
- X#
- X#*****************************************************************************
- X
- X# Imakefile for xboing version 1.6 - 6th August 1993
- X
- X# This is the directory where the highscore and level data will be placed.
- XXBOING_DIR = .
- X
- XCC = cc
- XCCOPTIONS = -Bstatic
- X
- X#CC = gcc
- X#CCOPTIONS = -static -DFUNCPROTO -Wall
- X
- XXPMLIB = -L/usr/lib -lXpm
- XXPMINCLUDE = -I/usr/include/X11
- XLEVEL_INSTALL_DIR = $(XBOING_DIR)/levels
- XSOUNDS_DIR = $(XBOING_DIR)/sounds
- XHIGH_SCORE_FILE = $(XBOING_DIR)/xboing.scores
- XAUDIO_AVAILABLE = False
- X
- XAUDIO_AVAILABLE = True
- X
- XAUDIO_INCLUDE = -I/usr/demo/SOUND/multimedia
- XAUDIO_LIB = -L/usr/demo/SOUND -laudio
- X
- XEXTRA_INCLS = $(XPMINCLUDE) $(AUDIO_INCLUDE)
- X
- XDEFINES = $(EXTRA_INCLS) \
- X -DHIGH_SCORE_FILE=\"$(HIGH_SCORE_FILE)\" \
- X -DLEVEL_INSTALL_DIR=\"$(LEVEL_INSTALL_DIR)\" \
- X -DAUDIO_AVAILABLE=\"$(AUDIO_AVAILABLE)\" \
- X -DSOUNDS_DIR=\"$(SOUNDS_DIR)\"
- X
- XLOCAL_LIBRARIES = $(AUDIO_LIB) $(XPMLIB) $(XLIB) -lm
- X
- XDEPLIBS = $(DEPXLIB)
- X
- XSRCS1= version.c main.c score.c error.c ball.c blocks.c init.c \
- X stage.c level.c paddle.c mess.c intro.c bonus.c sfx.c \
- X highscore.c misc.c inst.c gun.c keys.c audio.c special.c \
- X presents.c
- X
- XOBJS1= version.o main.o score.o error.o ball.o blocks.o init.o \
- X stage.o level.o paddle.o mess.o intro.o bonus.o sfx.o \
- X highscore.o misc.o inst.o gun.o keys.o audio.o special.o \
- X presents.o
- X
- XPROGRAMS = xboing
- X
- Xall:: $(PROGRAMS)
- X @$(RM) version.c
- X @echo "xboing built successfully."
- X
- Xversion.c:
- X @./version.sh $(PROGRAMS)
- X
- X OBJS = $(OBJS1) $(OBJS2) $(OBJS3)
- X SRCS = $(SRCS1) $(SRCS2) $(SRCS3)
- X
- Xall:: $(PROGRAMS)
- X
- X$(PROGRAMS): $(OBJS1) $(DEPLIBS1)
- X $(RM) $@
- X $(CC) -o $@ $(LDOPTIONS) $(OBJS1) $(LOCAL_LIBRARIES) $(LDLIBS) $(EXTRA_LOAD_FLAGS)
- X
- Xinstall:: $(PROGRAMS)
- X @if [ -d $(DESTDIR)$(BINDIR) ]; then set +x; \
- X else (set -x; $(MKDIRHIER) $(DESTDIR)$(BINDIR)); fi
- X $(INSTALL) -c $(INSTPGMFLAGS) $(PROGRAMS) $(DESTDIR)$(BINDIR)
- X
- Xinstall.man:: $(PROGRAMS).man
- X @if [ -d $(DESTDIR)$(MANDIR) ]; then set +x; \
- X else (set -x; $(MKDIRHIER) $(DESTDIR)$(MANDIR)); fi
- X $(INSTALL) -c $(INSTMANFLAGS) $(PROGRAMS).man $(DESTDIR)$(MANDIR)/$(PROGRAMS).$(MANSUFFIX)
- X
- Xdepend::
- X $(DEPEND) $(DEPENDFLAGS) -s "# DO NOT DELETE" -- $(ALLDEFINES) -- $(SRCS)
- X
- Xlint:
- X $(LINT) $(LINTFLAGS) $(SRCS) $(LINTLIBS)
- Xlint1:
- X $(LINT) $(LINTFLAGS) $(FILE) $(LINTLIBS)
- X
- Xclean::
- X $(RM) $(PROGRAMS)
- X
- Xinstall:: $(PROGRAMS)
- X @echo "XBoing directory is " $(XBOING_DIR)
- X
- X @echo "Creating directory " $(XBOING_DIR)
- X @if [ ! -d $(XBOING_DIR) ]; then mkdir $(XBOING_DIR); fi
- X
- X @echo "Creating directory " $(LEVEL_INSTALL_DIR)
- X @if [ ! -d $(LEVEL_INSTALL_DIR) ]; then mkdir $(LEVEL_INSTALL_DIR); fi
- X
- X @echo "Copying level data into directory " $(LEVEL_INSTALL_DIR)
- X @cd ./levels; set -x; for file in *.data; do \
- X $(INSTALL) -c $(INSTDATFLAGS) $$file $(LEVEL_INSTALL_DIR); \
- X done
- X
- X if [ $(AUDIO_AVAILABLE) ]
- X @echo "Creating directory " $(SOUNDS_DIR)
- X @if [ ! -d $(SOUNDS_DIR) ]; then mkdir $(SOUNDS_DIR); fi
- X
- X @echo "Copying sound files into directory " $(SOUNDS_DIR)
- X @cd ./sounds; set -x; for file in *.au; do \
- X $(INSTALL) -c $(INSTDATFLAGS) $$file $(SOUNDS_DIR); \
- X done
- X fi
- X
- X @echo "Creating a highscore file " $(HIGH_SCORE_FILE)
- X @touch $(HIGH_SCORE_FILE);
- X @chmod a+rw $(HIGH_SCORE_FILE);
- X
- X# End of the XBoing Imakefile :-)
- X
- X# -------------------------------------------------------------------------
- X# common rules for all Makefiles - do not edit
- X
- Xemptyrule::
- X
- Xclean::
- X $(RM_CMD) "#"*
- X
- XMakefile::
- X -@if [ -f Makefile ]; then set -x; \
- X $(RM) Makefile.bak; $(MV) Makefile Makefile.bak; \
- X else exit 0; fi
- X $(IMAKE_CMD) -DTOPDIR=$(TOP) -DCURDIR=$(CURRENT_DIR)
- X
- Xtags::
- X $(TAGS) -w *.[ch]
- X $(TAGS) -xw *.[ch] > TAGS
- X
- X# -------------------------------------------------------------------------
- X# empty rules for directories that do not have SUBDIRS - do not edit
- X
- Xinstall::
- X @echo "install in $(CURRENT_DIR) done"
- X
- Xinstall.man::
- X @echo "install.man in $(CURRENT_DIR) done"
- X
- XMakefiles::
- X
- Xincludes::
- X
- X# -------------------------------------------------------------------------
- X# dependencies generated by makedepend
- X
- END_OF_FILE
- if test 13670 -ne `wc -c <'Makefile.std'`; then
- echo shar: \"'Makefile.std'\" unpacked with wrong size!
- fi
- # end of 'Makefile.std'
- fi
- if test -f 'sounds/shoot.au.uue' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'sounds/shoot.au.uue'\"
- else
- echo shar: Extracting \"'sounds/shoot.au.uue'\" \(13537 characters\)
- sed "s/^X//" >'sounds/shoot.au.uue' <<'END_OF_FILE'
- Xbegin 664 shoot.au
- XM+G-N9 " "8M 0 'T ! "HJZVQ2T1K03@N-V/H
- XMP'4V/U-YO+S5748Q.#,J/L_,MJG&W+]'2-._VSWJT35"LK/"YC9"ML='0<^W
- XMM[C01#I*T<"XO/Y).RDI/%H]*B[HO,*[JJFU64CBS4PY1\_&/SS0N;\_+SE?
- XMV%_(JZ.L7BTI/\C?Y\;(SLU8.2HL/[VMO,JZM+].+S1AKZW3T<#<3>YJ-24@
- XM*T[D7;RPO,]1*RS)OTQ*MZ>Z7KRY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- XM:FMP?.[_>OUT<F5VY./K>FAA;/I]?>/:WN+GWM?:W^SZ>V-;55-<8V9L>_QA
- XM6%UL[]_7U];:['AK965M=FMI?N39V-G<Y/EI8V)E75ID<&-<9V]Q^.OF[N[L
- XH].[X<6MI>?#EZ_?GX>7W:FEG9FMV_?+IZ.?DY/;O]?;N[GEB7U]P=>OF
- X
- Xend
- END_OF_FILE
- if test 13537 -ne `wc -c <'sounds/shoot.au.uue'`; then
- echo shar: \"'sounds/shoot.au.uue'\" unpacked with wrong size!
- fi
- # end of 'sounds/shoot.au.uue'
- fi
- if test -f 'stage.c' -a "${1}" != "-c" ; then
- echo shar: Will not clobber existing file \"'stage.c'\"
- else
- echo shar: Extracting \"'stage.c'\" \(13726 characters\)
- sed "s/^X//" >'stage.c' <<'END_OF_FILE'
- X#include "copyright.h"
- X
- X/*
- X * Include file dependencies:
- X */
- X
- X#include <stdio.h>
- X#include <stdlib.h>
- X#include <stddef.h>
- X#include <X11/Xlib.h>
- X#include <X11/Xutil.h>
- X#include <X11/Xos.h>
- X#include <xpm.h>
- X
- X#include "bitmaps/mainbackground.xpm"
- X#include "bitmaps/background.xpm"
- X#include "bitmaps/background2.xpm"
- X#include "bitmaps/background3.xpm"
- X#include "bitmaps/background4.xpm"
- X#include "bitmaps/background5.xpm"
- X#include "bitmaps/background6.xpm"
- X#include "bitmaps/background7.xpm"
- X#include "bitmaps/background8.xpm"
- X#include "bitmaps/background9.xpm"
- X#include "bitmaps/background10.xpm"
- X#include "bitmaps/background11.xpm"
- X#include "bitmaps/icon.xpm"
- X
- X#include "error.h"
- X#include "blocks.h"
- X#include "sfx.h"
- X#include "ball.h"
- X#include "paddle.h"
- X#include "version.h"
- X#include "init.h"
- X
- X#include "stage.h"
- X
- X/*
- X * Internal macro definitions:
- X */
- X
- X#define LEFT_OFFSET 10
- X#define RIGHT_OFFSET 10
- X#define TOP_OFFSET 10
- X#define MIDDLE_OFFSET 10
- X
- X/*
- X * Internal type declarations:
- X */
- X
- X#if NeedFunctionPrototypes
- Xstatic Window SetWMIcon(Display *display);
- X#else
- Xstatic Window SetWMIcon();
- X#endif
- X
- X/*
- X * Internal variable declarations:
- X */
- X
- XWindow iconWindow;
- XWindow mainWindow;
- XWindow scoreWindow;
- XWindow levelWindow;
- XWindow playWindow;
- XWindow messWindow;
- XWindow specialWindow;
- XWindow timeWindow;
- XPixmap mainBackPixmap, iconPixmap;
- XPixmap back1Pixmap, back2Pixmap, back3Pixmap, back4Pixmap, back5Pixmap;
- XPixmap back6Pixmap, back7Pixmap, back8Pixmap, back9Pixmap, back10Pixmap;
- XPixmap back11Pixmap;
- X
- X#if NeedFunctionPrototypes
- Xvoid InitialiseMainBackPixmap(Display *display, Window window,
- X Colormap colormap)
- X#else
- Xvoid InitialiseMainBackPixmap(display, window, colormap)
- X Display *display;
- X Window window;
- X Colormap colormap;
- X#endif
- X{
- X XpmAttributes attributes;
- X int XpmErrorStatus;
- X
- X attributes.valuemask = XpmColormap;
- X attributes.colormap = colormap;
- X
- X /* Create the playfield background pixmaps */
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window,
- X mainbackground_xpm, &mainBackPixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background_xpm,
- X &back1Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background2_xpm,
- X &back2Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background3_xpm,
- X &back3Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background4_xpm,
- X &back4Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background5_xpm,
- X &back5Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background6_xpm,
- X &back6Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background7_xpm,
- X &back7Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background8_xpm,
- X &back8Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background9_xpm,
- X &back9Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background10_xpm,
- X &back10Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X XpmErrorStatus = XpmCreatePixmapFromData(display, window, background11_xpm,
- X &back11Pixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseMainBackPixmap()");
- X
- X /* Free the xpm pixmap attributes */
- X XpmFreeAttributes(&attributes);
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid ClearMainWindow(Display *display, Window window)
- X#else
- Xvoid ClearMainWindow(display, window)
- X Display *display;
- X Window window;
- X#endif
- X{
- X /* Make sure that it is drawn */
- X XClearWindow(display, mainWindow);
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid CreateAllWindows(Display *display, Colormap colormap,
- X char **argv, int argc)
- X#else
- Xvoid CreateAllWindows(display, colormap, argv, argc)
- X Display *display;
- X Colormap colormap;
- X char **argv;
- X int argc;
- X#endif
- X{
- X char title[80];
- X int offsetX, offsetY, scoreWidth;
- X XWMHints wmhints;
- X XClassHint classhints;
- X XSizeHints sizehints;
- X XTextProperty windowName, iconName;
- X XSetWindowAttributes winattr;
- X unsigned long valuemask;
- X
- X char *window_Name = "- XBoing -";
- X char *icon_Name = "XBoing";
- X
- X offsetX = MAIN_WIDTH / 2;
- X offsetY = MAIN_HEIGHT / 2;
- X scoreWidth = 224;
- X
- X /* Create the main window */
- X mainWindow = XCreateSimpleWindow(display,
- X RootWindow(display, DefaultScreen(display)), 0, 0,
- X PLAY_WIDTH + MAIN_WIDTH + 10, PLAY_HEIGHT + MAIN_HEIGHT + 10, 2,
- X red, black);
- X
- X /* Create the score window */
- X scoreWindow = XCreateSimpleWindow(display, mainWindow,
- X offsetX, 10, scoreWidth, 42, 0, white, black);
- X
- X /* Create the level window */
- X levelWindow = XCreateSimpleWindow(display, mainWindow,
- X scoreWidth + offsetX + 25, 5,
- X PLAY_WIDTH + offsetX - 20 - scoreWidth, 52, 0, white, black);
- X
- X /* Create the playing area window */
- X playWindow = XCreateSimpleWindow(display, mainWindow,
- X offsetX, 60, PLAY_WIDTH, PLAY_HEIGHT, 5, red, black);
- X
- X /* Create the message area window */
- X messWindow = XCreateSimpleWindow(display, mainWindow,
- X offsetX, 65 + PLAY_HEIGHT + 10, PLAY_WIDTH / 2, MESS_HEIGHT, 4,
- X white, black);
- X
- X /* Create the special bonus area window */
- X specialWindow = XCreateSimpleWindow(display, mainWindow,
- X offsetX + PLAY_WIDTH / 2 + 10, 65 + PLAY_HEIGHT + 10,
- X 180, MESS_HEIGHT + 5, 0, white, black);
- X
- X /* Create the timer area window */
- X timeWindow = XCreateSimpleWindow(display, mainWindow,
- X offsetX + PLAY_WIDTH / 2 + 10 + 180 + 5,
- X 65 + PLAY_HEIGHT + 10, PLAY_WIDTH / 8, MESS_HEIGHT + 5,
- X 0, white, black);
- X
- X /* Set window manager properties */
- X sprintf(title, "XBoing V%d.%d", VERSION, REVNUM + buildNum);
- X
- X if (XStringListToTextProperty(&window_Name, 1, &windowName) == 0)
- X ShutDown(display, 1, "Cannot create window name resource.");
- X
- X if (XStringListToTextProperty(&icon_Name, 1, &iconName) == 0)
- X ShutDown(display, 1, "Cannot create icon name resource.");
- X
- X iconWindow = SetWMIcon(display);
- X
- X /* Various window manager settings */
- X wmhints.initial_state = NormalState;
- X wmhints.input = True;
- X wmhints.icon_pixmap = iconPixmap;
- X wmhints.icon_window = iconWindow;
- X wmhints.flags = StateHint | InputHint | IconPixmapHint | IconWindowHint;
- X
- X /* Set the class for XBoing */
- X classhints.res_name = "XBoing";
- X classhints.res_class = "XBoing";
- X
- X /* Setup the max and minimum size that the window will be */
- X sizehints.flags = PPosition | PSize | PMinSize | PMaxSize;
- X sizehints.min_width = PLAY_WIDTH + MAIN_WIDTH + 10;
- X sizehints.min_height = PLAY_HEIGHT + MAIN_HEIGHT + 10;
- X sizehints.max_width = PLAY_WIDTH + MAIN_WIDTH + 10;
- X sizehints.max_height = PLAY_HEIGHT + MAIN_HEIGHT + 10;
- X
- X /* Now set the window manager properties */
- X XSetWMProperties(display, mainWindow, &windowName, &iconName,
- X argv, argc, &sizehints, &wmhints, &classhints);
- X
- X /* Set the current icon as the window's background pixmap */
- X XSetWindowBackgroundPixmap(display, iconWindow, iconPixmap);
- X XClearWindow(display, iconWindow);
- X
- X valuemask = CWColormap;
- X winattr.colormap = colormap;
- X
- X /* Check if the server allows backing store */
- X if (DoesBackingStore(XDefaultScreenOfDisplay(display)) == Always)
- X {
- X /* Ok we want backing store as it is very useful */
- X valuemask |= CWBackingStore;
- X winattr.backing_store = Always;
- X }
- X
- X XChangeWindowAttributes(display, mainWindow, valuemask, &winattr);
- X XChangeWindowAttributes(display, playWindow, valuemask, &winattr);
- X XChangeWindowAttributes(display, levelWindow, valuemask, &winattr);
- X XChangeWindowAttributes(display, scoreWindow, valuemask, &winattr);
- X XChangeWindowAttributes(display, messWindow, valuemask, &winattr);
- X XChangeWindowAttributes(display, specialWindow, valuemask, &winattr);
- X XChangeWindowAttributes(display, timeWindow, valuemask, &winattr);
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid SetBackgrounds(Display *display, Colormap colormap)
- X#else
- Xvoid SetBackgrounds(display, colormap)
- X Display *display;
- X Colormap colormap;
- X#endif
- X{
- X InitialiseMainBackPixmap(display, mainWindow, colormap);
- X
- X ClearMainWindow(display, mainWindow);
- X XSetWindowBackgroundPixmap(display, levelWindow, ParentRelative);
- X XClearWindow(display, levelWindow);
- X XSetWindowBackgroundPixmap(display, scoreWindow, ParentRelative);
- X XClearWindow(display, scoreWindow);
- X XSetWindowBackgroundPixmap(display, specialWindow, ParentRelative);
- X XClearWindow(display, specialWindow);
- X XSetWindowBackgroundPixmap(display, timeWindow, ParentRelative);
- X XClearWindow(display, timeWindow);
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid MapAllWindows(Display *display)
- X#else
- Xvoid MapAllWindows(display)
- X Display *display;
- X#endif
- X{
- X /* Actually make everything visible */
- X XMapWindow(display, specialWindow);
- X XMapWindow(display, timeWindow);
- X XMapWindow(display, messWindow);
- X XMapWindow(display, playWindow);
- X XMapWindow(display, levelWindow);
- X XMapWindow(display, scoreWindow);
- X XMapWindow(display, mainWindow);
- X XFlush(display);
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid RedrawPlayWindow(Display *display, Window window)
- X#else
- Xvoid RedrawPlayWindow(display, window)
- X Display *display;
- X Window window;
- X#endif
- X{
- X /* Redraw the main playfield */
- X XClearWindow(display, playWindow);
- X RedrawAllBlocks(display, window);
- X RedrawPaddle(display, window);
- X RedrawBall(display, window);
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid FreeBackgroundPixmaps(Display *display)
- X#else
- Xvoid FreeBackgroundPixmaps(display)
- X Display *display;
- X#endif
- X{
- X /* Free all the backgound pixmaps */
- X if (back1Pixmap) XFreePixmap(display, back1Pixmap);
- X if (back2Pixmap) XFreePixmap(display, back2Pixmap);
- X if (back3Pixmap) XFreePixmap(display, back3Pixmap);
- X if (back4Pixmap) XFreePixmap(display, back4Pixmap);
- X if (back5Pixmap) XFreePixmap(display, back5Pixmap);
- X if (back6Pixmap) XFreePixmap(display, back6Pixmap);
- X if (back7Pixmap) XFreePixmap(display, back7Pixmap);
- X if (back8Pixmap) XFreePixmap(display, back8Pixmap);
- X if (back9Pixmap) XFreePixmap(display, back9Pixmap);
- X if (back10Pixmap) XFreePixmap(display, back10Pixmap);
- X if (back11Pixmap) XFreePixmap(display, back11Pixmap);
- X
- X /* Free the icon and main background pixmaps */
- X if (iconPixmap) XFreePixmap(display, iconPixmap);
- X if (mainBackPixmap) XFreePixmap(display, mainBackPixmap);
- X}
- X
- X#if NeedFunctionPrototypes
- Xstatic Window SetWMIcon(Display *display)
- X#else
- Xstatic Window SetWMIcon(display)
- X Display *display;
- X#endif
- X{
- X XpmAttributes attributes;
- X Window win, root;
- X Colormap iconcolormap;
- X int XpmErrorStatus;
- X
- X /* Suss out the root window */
- X root = RootWindow(display, DefaultScreen(display));
- X
- X if (!(win = XCreateSimpleWindow(display, root,
- X 0, 0, 50, 50, 0, CopyFromParent, CopyFromParent)))
- X {
- X /* Well, what a bummer. Just use default icon then. */
- X ErrorMessage("Cannot create icon pixmap.");
- X return ((Window) NULL);
- X }
- X
- X /* Create a new colourmap for the icon window */
- X iconcolormap = XDefaultColormap(display, XDefaultScreen(display));
- X
- X /* Create all xpm pixmap blocks from the files */
- X attributes.colormap = iconcolormap;
- X attributes.valuemask = XpmColormap;
- X XpmErrorStatus = XpmCreatePixmapFromData(display, win,
- X icon_xpm, &iconPixmap, NULL, &attributes);
- X HandleXPMError(display, XpmErrorStatus, "InitialiseWMIcon()");
- X
- X /* Make the new window have the new colourmap */
- X XSetWindowColormap(display, win, iconcolormap);
- X
- X /* Free the background pixmap attributes */
- X XpmFreeAttributes(&attributes);
- X
- X return win;
- X}
- X
- X#if NeedFunctionPrototypes
- Xvoid DrawStageBackground(Display *display, Window window, int stageType)
- X#else
- Xvoid DrawStageBackground(display, window, stageType)
- X Display *display;
- X Window window;
- X int stageType;
- X#endif
- X{
- X switch (stageType)
- X {
- X case BACKGROUND_0:
- X XSetWindowBackgroundPixmap(display, window, mainBackPixmap);
- X break;
- X
- X case BACKGROUND_1:
- X XSetWindowBackgroundPixmap(display, window, back1Pixmap);
- X break;
- X
- X case BACKGROUND_2:
- X XSetWindowBackgroundPixmap(display, window, back2Pixmap);
- X break;
- X
- X case BACKGROUND_3:
- X XSetWindowBackgroundPixmap(display, window, back3Pixmap);
- X break;
- X case BACKGROUND_4:
- X XSetWindowBackgroundPixmap(display, window, back4Pixmap);
- X break;
- X
- X case BACKGROUND_5:
- X XSetWindowBackgroundPixmap(display, window, back5Pixmap);
- X break;
- X
- X case BACKGROUND_6:
- X XSetWindowBackgroundPixmap(display, window, back6Pixmap);
- X break;
- X
- X case BACKGROUND_7:
- X XSetWindowBackgroundPixmap(display, window, back7Pixmap);
- X break;
- X
- X case BACKGROUND_8:
- X XSetWindowBackgroundPixmap(display, window, back8Pixmap);
- X break;
- X
- X case BACKGROUND_9:
- X XSetWindowBackgroundPixmap(display, window, back9Pixmap);
- X break;
- X
- X case BACKGROUND_10:
- X XSetWindowBackgroundPixmap(display, window, back10Pixmap);
- X break;
- X
- X case BACKGROUND_11:
- X XSetWindowBackgroundPixmap(display, window, back11Pixmap);
- X break;
- X
- X default:
- X XSetWindowBackgroundPixmap(display, window, back1Pixmap);
- X }
- X
- X /* Flush the new background */
- X XClearWindow(display, window);
- X}
- END_OF_FILE
- if test 13726 -ne `wc -c <'stage.c'`; then
- echo shar: \"'stage.c'\" unpacked with wrong size!
- fi
- # end of 'stage.c'
- fi
- echo shar: End of archive 16 \(of 26\).
- cp /dev/null ark16isdone
- MISSING=""
- for I in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 ; do
- if test ! -f ark${I}isdone ; then
- MISSING="${MISSING} ${I}"
- fi
- done
- if test "${MISSING}" = "" ; then
- echo You have unpacked all 26 archives.
- rm -f ark[1-9]isdone ark[1-9][0-9]isdone
- echo "merging split files..."
- cat blocks.c[12] > blocks.c
- rm blocks.c[12]
- echo "blocks.c done"
- cat bitmaps/earth.xpm.Z.u.[ab] > bitmaps/earth.xpm.Z.uue
- rm bitmaps/earth.xpm.Z.u.[ab]
- echo "bitmaps/earth.xpm.Z.uue done"
- else
- echo You still must unpack the following archives:
- echo " " ${MISSING}
- fi
- exit 0
- exit 0 # Just in case...
- --
- // chris@Sterling.COM | Send comp.sources.x submissions to:
- \X/ Amiga - The only way to fly! | sources-x@sterling.com
- "It's intuitively obvious to the |
- most casual observer..." | GCS d+/-- p+ c++ l+ m+ s++/+ g+ w+ t+ r+ x+
-