File pacman-1.001.dif of Package pacman
--- Makefile.am
+++ Makefile.am
@@ -6,7 +6,7 @@
if ISVMS
vms=1
else
-pacman_LDADD = -lX11
+pacman_LDADD = @X_LIBRARIES@ -lX11
pacman_LDFLAGS = -s
endif
--- Makefile.in
+++ Makefile.in
@@ -74,7 +74,7 @@
bin_PROGRAMS = pacman
@ISVMS_TRUE@vms=1
-@ISVMS_FALSE@pacman_LDADD = -lX11
+@ISVMS_FALSE@pacman_LDADD = @X_LIBRARIES@ -lX11
@ISVMS_FALSE@pacman_LDFLAGS = -s
pacman_SOURCES = arg.cc blank.cc board.cc bonus.cc bonuslif.cc bonuspnt.cc \
--- configure.in
+++ configure.in
@@ -9,7 +9,7 @@
case "$target" in
*-*-vms*) vms=1;;
-*-*-*) CXXFLAGS=-O2;;
+*-*-*);;
esac
AC_ARG_ENABLE(doublesize,
@@ -35,6 +35,7 @@
dnl Checks for header files.
AC_PATH_X
+X_LIBRARIES="-L${x_libraries}"
AC_HEADER_STDC
AC_CHECK_HEADERS(sys/time.h unistd.h)
@@ -44,5 +45,5 @@
dnl Checks for library functions.
AC_CHECK_FUNCS(gettimeofday)
-
+AC_SUBST(X_LIBRARIES)
AC_OUTPUT(Makefile)
--- ghost.cc
+++ ghost.cc
@@ -165,7 +165,7 @@
}
}
-Ghost::go(Pacman *pac) { //go for pacman: do ghost code
+int Ghost::go(Pacman *pac) { //go for pacman: do ghost code
typ w; //what type is at next coordinates
int i=1; //moved or not?
int xx,yy; //coordinates
--- ghost.h
+++ ghost.h
@@ -31,7 +31,7 @@
Ghost(COLOURTYPE,int,int); //constructor with coordinates
~Ghost(); //destructor
void draw(void); //draw the ghost
-go(Pacman*); //go for pacman: do ghost code
+int go(Pacman*); //go for pacman: do ghost code
typ is_a(void) {return classGhost;}
void eat(void); //when pacman eats ghost
void getxy(int*,int*);
--- point.cc
+++ point.cc
@@ -1,7 +1,7 @@
#include"point.h"
Point::Point(int xx=0,int yy=0) { x=xx; y=yy; };
-Point::val_x() { return x; };
-Point::val_y() { return y; };
+int Point::val_x() { return x; };
+int Point::val_y() { return y; };
void Point::set_x(int xx) { x=xx; };
void Point::set_y(int yy) { y=yy; };
void Point::set_xy(int xx,int yy) { x=xx; y=yy; };
--- usrinter.cc
+++ usrinter.cc
@@ -204,6 +204,7 @@
if (dx<dy && dx>-dy) return down;
if (dx<dy && dx<=-dy) return left;
pacwarning("errorstick\n"); //give warning if not all directons covered
+return none;
} else { //if input comes from keyboard
char key_vector[32]; //denotes 256 possible keys
XQueryKeymap(mydisplay,key_vector); //queries and gets data for all keys