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 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148
|
/*
* hextris Copyright 1990 David Markley, dm3e@+andrew.cmu.edu, dam@cs.cmu.edu
*
* Permission to use, copy, modify, and distribute, this software and its
* documentation for any purpose is hereby granted without fee, provided that
* the above copyright notice appear in all copies and that both that
* copyright notice and this permission notice appear in supporting
* documentation, and that the name of the copyright holders be used in
* advertising or publicity pertaining to distribution of the software with
* specific, written prior permission, and that no fee is charged for further
* distribution of this software, or any modifications thereof. The copyright
* holder make no representations about the suitability of this software for
* any purpose. It is provided "as is" without express or implied warranty.
*
* THE COPYRIGHT HOLDER DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
* EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
* DATA, PROFITS, QPA OR GPA, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
* OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
* PERFORMANCE OF THIS SOFTWARE.
*/
Welcome to the world of hextris...
If you are planning on using hextris, please send me mail so I can get
you the latest updates. I'd just like to know who all the people are
that are enjoying this game. Also, where this game is being enjoyed.
Thanks a lot for looking at it, anyway...
David (dm3e+hextris@andrew.cmu.edu)
If that address fails, please just send to:
dm3e@andrew.cmu.edu, or
dam@cs.cmu.edu
1) Installation
Before you install xhextris, you should modify these files,
you should modify these variable in the Imakefile, or Makefile:
BIN - So your binaries are where you want them.
HEXFONTDIR - So the hextris font is placed where you want it.
HIGHSCOREDIR - So the high score file is where you want it.
HIGHSCOREEXT - The name of the high score file.
You may also want to change:
CFLAGS - Whatever flags you want.
INCLDS - The directories needed for all the #include statements.
LIBS - The library directories for any -l flags (-lX11)
Once you have changed the setting of these variables, take a
look at header.h. If you see any #define(s) that you wish to change,
do so. Everything depends upon header.h, so it is very troublesome to
change something there later. The things you may wish to change are:
MAXROW - The number of rows in your game.
MAXCOLUMN - The number of columns in your game.
MAXHIGHSCORES - The maximum number of high scores kept.
MAXNAMELENGTH - The maximum size of a users hextris nick name.
- Set by the user setting the environment variable: XHEXNAME
MAXUSERIDLENGTH - The maximum size of a user id.
MAXHIGHS - The maximum number of high scores a user can have.
FONTDIR - The directory that your text font is in.
FONTNAME - The name of your text font.
Please also note that you will need to have the programs
bdftosnf and mkfontdir in your path, for the hextris font to be
installed correctly. If you do not have these available, use whatever
tools you have to convert fonts from bdf format to snf format, and
then set up the directory as a font directory. Modify the Makefile,
or Imakefile accordingly.
At this point, you should have made all the modifications you
needed. Please look around the code later. It's somewhat documented,
and you should be able to change things with out too much mystery of
what will actually happen. For now, if you changed the makefile,
simply do the following:
make <cr>
BE WARNED!!! MODIFYING JUST THE MAKEFILE IS BAD!!! IF SOMEONE
FOLLOWS THE REST OF THE INSTRUCTIONS HERE ABOUT IMAKE, ALL YOUR
CHANGES WILL BE LOST!!!
If you modified the Imakefile, there are two ways to go about
making xhextris:
1) The way not involving makefile.
imake -v <cr>
2) The way involving makefile.
imake -s Makefile -v <cr>
make <cr>
If you have the build application available, of course you'll
want to use the second option, and replace the make with build.
I apologize to the more experienced user for the detailed, and
simplistic nature of this setup documentation. I wanted it to be as
clear as possible to anyone, especially those just starting.
This is the first piece of software I've placed out on Internet, and
it's not too far down on the list of C programs I've written. A game
is a great way to learn C, as well as X.
2) Playing the game
To play the game, simply run it out of the area you placed it
in, and use the keys described on the right side when it comes up.
3) Future of hextris
Hextris has been ported to X, and the Andrew Window Manager.
The ports to mac and pc are under way. Hextris has been compiled for
these system types: IBM RT, VAXstation 3100, DECstation 3100,
SPARCstation 1, Sun 3/35, and macintosh running mach unix.
I would like to see if some big company would like to market
this game on their little home/portable video game units. If you do,
let me know.
This is the first release of Hextris (1.0), future releases
will increase user friendly interfaces, and a more finished look.
Proposed user friendly interfaces are:
The abilities to:
Define the keys used to play.
Define x window parameters (like -fg, -bg, -geom...etc).
Define the users own set of pieces (including more/less hexes per
piece).
In general, any suggestions would be greatly appreciated.
Hextris is about one month old now (4/26/90). I'm sure it will change
a lot in the near future. If you wish to be on the list of people that
get the latest diffs, please send email to me.
David (dm3e+hextris@andrew.cmu.edu)
P.S. If that address fails, please just send to:
dm3e@andrew.cmu.edu, or
dam@cs.cmu.edu
|