diff options
author | ijliao <ijliao@FreeBSD.org> | 2002-07-17 00:00:15 +0800 |
---|---|---|
committer | ijliao <ijliao@FreeBSD.org> | 2002-07-17 00:00:15 +0800 |
commit | 2fb9ed92399f04216061486c94937cc4404b57e8 (patch) | |
tree | a98024fada67e283b9cbd800e110a7b9b892fa38 | |
parent | f13c8616fc711c85f06477d3e793e18ea4ae752b (diff) | |
download | freebsd-ports-graphics-2fb9ed92399f04216061486c94937cc4404b57e8.tar.gz freebsd-ports-graphics-2fb9ed92399f04216061486c94937cc4404b57e8.tar.zst freebsd-ports-graphics-2fb9ed92399f04216061486c94937cc4404b57e8.zip |
add race 0.5
OpenGL Racing Game
-rw-r--r-- | games/Makefile | 1 | ||||
-rw-r--r-- | games/race/Makefile | 39 | ||||
-rw-r--r-- | games/race/distinfo | 1 | ||||
-rw-r--r-- | games/race/files/patch-Makefile | 11 | ||||
-rw-r--r-- | games/race/files/patch-game.c | 11 | ||||
-rw-r--r-- | games/race/files/patch-main.c | 11 | ||||
-rw-r--r-- | games/race/files/patch-menu.c | 59 | ||||
-rw-r--r-- | games/race/files/patch-terrian.c | 11 | ||||
-rw-r--r-- | games/race/files/patch-textures.c | 11 | ||||
-rw-r--r-- | games/race/pkg-comment | 1 | ||||
-rw-r--r-- | games/race/pkg-descr | 6 | ||||
-rw-r--r-- | games/race/pkg-plist | 59 |
12 files changed, 221 insertions, 0 deletions
diff --git a/games/Makefile b/games/Makefile index 8d426644e37..ee07c2501a5 100644 --- a/games/Makefile +++ b/games/Makefile @@ -236,6 +236,7 @@ SUBDIR += qstat SUBDIR += quakeforge SUBDIR += quakeserver + SUBDIR += race SUBDIR += robocode SUBDIR += rocksndiamonds SUBDIR += rollemup diff --git a/games/race/Makefile b/games/race/Makefile new file mode 100644 index 00000000000..f1fca185ad1 --- /dev/null +++ b/games/race/Makefile @@ -0,0 +1,39 @@ +# ex:ts=8 +# Ports collection makefile for: race +# Date created: Jul 16, 2002 +# Whom: ijliao +# +# $FreeBSD$ +# + +PORTNAME= race +PORTVERSION= 0.5 +CATEGORIES= games +MASTER_SITES= ftp://users.freebsd.org.uk/pub/foobar2k/ + +MAINTAINER= ports@FreeBSD.org + +LIB_DEPENDS= SDL_mixer:${PORTSDIR}/audio/sdl_mixer \ + SDL_image:${PORTSDIR}/graphics/sdl_image + +USE_BZIP2= yes +USE_REINPLACE= yes +USE_MESA= yes +SDL_CONFIG?= ${LOCALBASE}/bin/sdl11-config +CFLAGS+= "-I${X11BASE}/include" +MAKE_ENV= CC="${CC} ${CFLAGS}" LDFLAGS="-L${X11BASE}/lib ${PTHREAD_LIBS}" + +post-patch: + @${REINPLACE_CMD} -e "s|^CC|#CC|g" \ + -e "s|sdl-config|${SDL_CONFIG}|g" ${WRKSRC}/Makefile +.for file in game.c main.c menu.c terrain.c textures.c + @${REINPLACE_CMD} -e "s|%%DATADIR%%|${DATADIR}|g" ${WRKSRC}/src/${file} +.endfor + +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/race ${PREFIX}/bin + @${MKDIR} ${DATADIR}/data + ${INSTALL_DATA} ${WRKSRC}/config ${DATADIR} + ${CP} -R ${WRKSRC}/data/* ${DATADIR}/data + +.include <bsd.port.mk> diff --git a/games/race/distinfo b/games/race/distinfo new file mode 100644 index 00000000000..b1e91c5843a --- /dev/null +++ b/games/race/distinfo @@ -0,0 +1 @@ +MD5 (race-0.5.tar.bz2) = 9f6efbe1b1a7969a9e8d718d691b4095 diff --git a/games/race/files/patch-Makefile b/games/race/files/patch-Makefile new file mode 100644 index 00000000000..a4469f22042 --- /dev/null +++ b/games/race/files/patch-Makefile @@ -0,0 +1,11 @@ +--- Makefile.orig Tue Jul 16 23:35:15 2002 ++++ Makefile Tue Jul 16 23:38:31 2002 +@@ -27,7 +27,7 @@ + $(CC) main.o timing.o vector.o fifo.o ortho.o audio.o font.o \ + init.o textures.o terrain.o menu.o game.o hud.o messages.o \ + camera.o \ +- -o $(BIN) -lGL -lGLU -lSDL_image -lSDL_mixer -lm `sdl-config --libs` ++ -o $(BIN) ${LDFLAGS} -lGL -lGLU -lSDL_image -lSDL_mixer -lm `sdl-config --libs` + + @rm -f *.o + diff --git a/games/race/files/patch-game.c b/games/race/files/patch-game.c new file mode 100644 index 00000000000..f90ac925058 --- /dev/null +++ b/games/race/files/patch-game.c @@ -0,0 +1,11 @@ +--- src/game.c.orig Tue Jul 16 23:47:16 2002 ++++ src/game.c Tue Jul 16 23:48:22 2002 +@@ -39,7 +39,7 @@ + player.z = -1000; + + debugf("Reset Player Variables"); +- playmusic("data/music/fuck.xm"); ++ playmusic("%%DATADIR%%/data/music/fuck.xm"); + newgame = 0; + timestart = SDL_GetTicks(); + printf("\nLoaded Map:\n %s (data/%s)\n %s\n\n", diff --git a/games/race/files/patch-main.c b/games/race/files/patch-main.c new file mode 100644 index 00000000000..d2fda43471f --- /dev/null +++ b/games/race/files/patch-main.c @@ -0,0 +1,11 @@ +--- src/main.c.orig Tue Jul 16 23:45:12 2002 ++++ src/main.c Tue Jul 16 23:45:28 2002 +@@ -75,7 +75,7 @@ + + printf("%s version %s\nCopyleft foobar and judeo (See COPYING for info)\n",TITLE,VERSION); + +- loadconfig("config"); ++ loadconfig("%%DATADIR%%/config"); + + if(!initsdl()) error("SDL Loading Failed"); + else printf(" Loaded: SDL\n"); diff --git a/games/race/files/patch-menu.c b/games/race/files/patch-menu.c new file mode 100644 index 00000000000..1e120203072 --- /dev/null +++ b/games/race/files/patch-menu.c @@ -0,0 +1,59 @@ +--- src/menu.c.orig Tue Jul 16 23:49:04 2002 ++++ src/menu.c Tue Jul 16 23:49:31 2002 +@@ -28,7 +28,7 @@ + + int initmenu(void){ + +- playmusic("data/music/lktheme.mod"); ++ playmusic("%%DATADIR%%/data/music/lktheme.mod"); + + return 1; + } +@@ -114,13 +114,13 @@ + loadc = COURSES-1; + else + loadc--; +- playsound("data/sounds/menu.wav",0); ++ playsound("%%DATADIR%%/data/sounds/menu.wav",0); + break; + + case 2: + SDL_WM_ToggleFullScreen(surface); + fullscreen = 0; +- playsound("data/sounds/menu.wav",0); ++ playsound("%%DATADIR%%/data/sounds/menu.wav",0); + break; + default: + break; +@@ -133,12 +133,12 @@ + loadc = 0; + else + loadc++; +- playsound("data/sounds/menu.wav",0); ++ playsound("%%DATADIR%%/data/sounds/menu.wav",0); + break; + case 2: + fullscreen = 0; + SDL_WM_ToggleFullScreen(surface); +- playsound("data/sounds/menu.wav",0); ++ playsound("%%DATADIR%%/data/sounds/menu.wav",0); + break; + default: + break; +@@ -149,14 +149,14 @@ + menuitem = MENU_ITEMS-1; + else + menuitem--; +- playsound("data/sounds/menu.wav",0); ++ playsound("%%DATADIR%%/data/sounds/menu.wav",0); + break; + case SDLK_DOWN: + if(menuitem == MENU_ITEMS-1) + menuitem = 0; + else + menuitem++; +- playsound("data/sounds/menu.wav",0); ++ playsound("%%DATADIR%%/data/sounds/menu.wav",0); + break; + case SDLK_q: + killgame(1); diff --git a/games/race/files/patch-terrian.c b/games/race/files/patch-terrian.c new file mode 100644 index 00000000000..240cd644793 --- /dev/null +++ b/games/race/files/patch-terrian.c @@ -0,0 +1,11 @@ +--- src/terrain.c.orig Tue Jul 16 23:49:58 2002 ++++ src/terrain.c Tue Jul 16 23:50:11 2002 +@@ -36,7 +36,7 @@ + + debugf("Started Loading Map (%s)",course->dir); + +- sprintf(temp,"data/%s/%s",course->dir,"map.bmp"); ++ sprintf(temp,"%%DATADIR%%/data/%s/%s",course->dir,"map.bmp"); + + if(!(mapimg = IMG_Load(temp))) + error("Missing Level Data"); diff --git a/games/race/files/patch-textures.c b/games/race/files/patch-textures.c new file mode 100644 index 00000000000..ca0c1480556 --- /dev/null +++ b/games/race/files/patch-textures.c @@ -0,0 +1,11 @@ +--- src/textures.c.orig Tue Jul 16 23:50:37 2002 ++++ src/textures.c Tue Jul 16 23:50:46 2002 +@@ -35,7 +35,7 @@ + SDL_Surface *image; + char location[6+strlen(dir)+strlen(file)]; + +- sprintf(location,"data/%s/%s",dir,file); ++ sprintf(location,"%%DATADIR%%/data/%s/%s",dir,file); + + if((image = IMG_Load(location))){ + glGenTextures(1, &texture[id]); diff --git a/games/race/pkg-comment b/games/race/pkg-comment new file mode 100644 index 00000000000..ecf8353a6d8 --- /dev/null +++ b/games/race/pkg-comment @@ -0,0 +1 @@ +OpenGL Racing Game diff --git a/games/race/pkg-descr b/games/race/pkg-descr new file mode 100644 index 00000000000..9e784471fb6 --- /dev/null +++ b/games/race/pkg-descr @@ -0,0 +1,6 @@ +OpenGL Racing Game is a Star Wars: Racer style game coded in pure C using +OpenGL. You can race round and round to your heart's desire. Features +include Heightfield map loading, texture mapping, a speedometer, a +translucent radar map, a timer, music, sound. + +WWW: http://projectz.ath.cx/?id=70 diff --git a/games/race/pkg-plist b/games/race/pkg-plist new file mode 100644 index 00000000000..89069718e64 --- /dev/null +++ b/games/race/pkg-plist @@ -0,0 +1,59 @@ +bin/race +share/race/config +share/race/data/all/.xvpics/font.jpg +share/race/data/all/.xvpics/font.png +share/race/data/all/.xvpics/fontoutline.png +share/race/data/all/.xvpics/loading.jpg +share/race/data/all/font.png +share/race/data/all/fontoutline.png +share/race/data/all/loading.jpg +share/race/data/all/menu.jpg +share/race/data/all/pz.jpg +share/race/data/all/speed.jpg +share/race/data/all/speed.png +share/race/data/desert/.xvpics/bk.jpg +share/race/data/desert/.xvpics/dn.jpg +share/race/data/desert/.xvpics/ft.jpg +share/race/data/desert/.xvpics/lf.jpg +share/race/data/desert/.xvpics/rt.jpg +share/race/data/desert/.xvpics/terrain.jpg +share/race/data/desert/.xvpics/up.jpg +share/race/data/desert/bk.jpg +share/race/data/desert/dn.jpg +share/race/data/desert/ft.jpg +share/race/data/desert/lf.jpg +share/race/data/desert/map.bmp +share/race/data/desert/rt.jpg +share/race/data/desert/terrain.jpg +share/race/data/desert/up.jpg +share/race/data/models/ship.mdl +share/race/data/music/fuck.xm +share/race/data/music/lktheme.mod +share/race/data/sea/.xvpics/bk.jpg +share/race/data/sea/.xvpics/dn.jpg +share/race/data/sea/.xvpics/ft.jpg +share/race/data/sea/.xvpics/lf.jpg +share/race/data/sea/.xvpics/map.bmp +share/race/data/sea/.xvpics/rt.jpg +share/race/data/sea/.xvpics/terrain.jpg +share/race/data/sea/.xvpics/up.jpg +share/race/data/sea/bk.jpg +share/race/data/sea/dn.jpg +share/race/data/sea/ft.jpg +share/race/data/sea/lf.jpg +share/race/data/sea/map.bmp +share/race/data/sea/rt.jpg +share/race/data/sea/terrain.jpg +share/race/data/sea/up.jpg +share/race/data/sounds/menu.wav +@dirrm share/race/data/all/.xvpics +@dirrm share/race/data/all +@dirrm share/race/data/desert/.xvpics +@dirrm share/race/data/desert +@dirrm share/race/data/models +@dirrm share/race/data/music +@dirrm share/race/data/sea/.xvpics +@dirrm share/race/data/sea +@dirrm share/race/data/sounds +@dirrm share/race/data +@dirrm share/race |