summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRomain Perier <mrpouet@gentoo.org>2009-08-21 11:30:57 +0200
committerRomain Perier <mrpouet@gentoo.org>2009-08-21 11:30:57 +0200
commit69aff8438c234152ffe354ef2b308adbc12d58a0 (patch)
tree68791a55491a9f92ab7d6e4bf14315aaba9a78e0 /games-action
parent(devel/games-arcade/edgar) initial edgar-0.25.ebuild (diff)
downloadgamerlay-69aff8438c234152ffe354ef2b308adbc12d58a0.tar.gz
gamerlay-69aff8438c234152ffe354ef2b308adbc12d58a0.tar.bz2
gamerlay-69aff8438c234152ffe354ef2b308adbc12d58a0.zip
Moved devel/* to ./
Diffstat (limited to 'games-action')
-rw-r--r--games-action/a7xpg/Manifest6
-rw-r--r--games-action/a7xpg/a7xpg-0.11.ebuild66
-rw-r--r--games-action/a7xpg/files/a7xpg-0.11.diff2907
-rw-r--r--games-action/a7xpg/files/a7xpg.pngbin0 -> 2930 bytes
-rw-r--r--games-action/a7xpg/files/a7xpg.prfbin0 -> 8 bytes
-rw-r--r--games-action/a7xpg/files/digest-a7xpg-0.113
-rw-r--r--games-action/a7xpg/metadata.xml9
-rw-r--r--games-action/ardentryst/Manifest3
-rw-r--r--games-action/ardentryst/ardentryst-1.71.ebuild31
-rw-r--r--games-action/ardentryst/metadata.xml9
-rw-r--r--games-action/area2048/Manifest6
-rw-r--r--games-action/area2048/area2048-1.03.ebuild74
-rw-r--r--games-action/area2048/files/area2048-1.03.diff2469
-rw-r--r--games-action/area2048/files/area2048.pngbin0 -> 2508 bytes
-rw-r--r--games-action/area2048/metadata.xml9
-rw-r--r--games-action/deadlysoccerball/Manifest5
-rw-r--r--games-action/deadlysoccerball/deadlysoccerball-0.1.ebuild53
-rw-r--r--games-action/deadlysoccerball/files/deadlysoccerball-0.1.diff12
-rw-r--r--games-action/deadlysoccerball/files/deadlysoccerball.pngbin0 -> 2642 bytes
-rw-r--r--games-action/deadlysoccerball/files/digest-deadlysoccerball-0.13
-rw-r--r--games-action/deadlysoccerball/metadata.xml9
-rw-r--r--games-action/exception_conflict/Manifest11
-rw-r--r--games-action/exception_conflict/exception_conflict-1.03.ebuild67
-rw-r--r--games-action/exception_conflict/exception_conflict-1.09.ebuild70
-rw-r--r--games-action/exception_conflict/files/disable-netplay-1.09.patch36
-rw-r--r--games-action/exception_conflict/files/exception_conflict.pngbin0 -> 460 bytes
-rw-r--r--games-action/exception_conflict/files/gcc-4.3-fixes-1.09.patch11
-rw-r--r--games-action/exception_conflict/files/gcc-4.3-fixes.patch11
-rw-r--r--games-action/exception_conflict/files/linuxfixes-1.09.patch112
-rw-r--r--games-action/exception_conflict/files/linuxfixes.patch88
-rw-r--r--games-action/exception_conflict/metadata.xml9
-rw-r--r--games-action/gradleunison/Manifest6
-rw-r--r--games-action/gradleunison/files/gradleunison-0.10.diff350
-rw-r--r--games-action/gradleunison/files/gradleunison.pngbin0 -> 4207 bytes
-rw-r--r--games-action/gradleunison/files/gu-score.datbin0 -> 320 bytes
-rw-r--r--games-action/gradleunison/gradleunison-0.10.ebuild72
-rw-r--r--games-action/gradleunison/metadata.xml9
-rw-r--r--games-action/gunroar/Manifest5
-rw-r--r--games-action/gunroar/files/digest-gunroar-0.153
-rw-r--r--games-action/gunroar/files/gunroar-0.15.diff589
-rw-r--r--games-action/gunroar/files/gunroar.pngbin0 -> 3146 bytes
-rw-r--r--games-action/gunroar/gunroar-0.15.ebuild61
-rw-r--r--games-action/gunroar/metadata.xml9
-rw-r--r--games-action/gunroarhi/Manifest5
-rw-r--r--games-action/gunroarhi/files/digest-gunroarhi-0.303
-rw-r--r--games-action/gunroarhi/files/gunroarhi-0.30.diff153
-rw-r--r--games-action/gunroarhi/files/gunroarhi.pngbin0 -> 3544 bytes
-rw-r--r--games-action/gunroarhi/gunroarhi-0.30.ebuild59
-rw-r--r--games-action/gunroarhi/metadata.xml9
-rw-r--r--games-action/mucade/Manifest5
-rw-r--r--games-action/mucade/files/digest-mucade-0.113
-rw-r--r--games-action/mucade/files/mucade-0.11.diff454
-rw-r--r--games-action/mucade/files/mucade.pngbin0 -> 3122 bytes
-rw-r--r--games-action/mucade/metadata.xml9
-rw-r--r--games-action/mucade/mucade-0.11.ebuild61
-rw-r--r--games-action/openlierox/ChangeLog28
-rw-r--r--games-action/openlierox/Manifest3
-rw-r--r--games-action/openlierox/openlierox-0.57_beta8.ebuild65
-rw-r--r--games-action/parsec47/Manifest6
-rw-r--r--games-action/parsec47/files/digest-parsec47-0.23
-rw-r--r--games-action/parsec47/files/p47.prfbin0 -> 368 bytes
-rw-r--r--games-action/parsec47/files/parsec47-0.2.diff2806
-rw-r--r--games-action/parsec47/files/parsec47.pngbin0 -> 2792 bytes
-rw-r--r--games-action/parsec47/metadata.xml9
-rw-r--r--games-action/parsec47/parsec47-0.2.ebuild76
-rw-r--r--games-action/projectl/Manifest5
-rw-r--r--games-action/projectl/files/digest-projectl-1.0013
-rw-r--r--games-action/projectl/files/projectl-1.001.diff307
-rw-r--r--games-action/projectl/files/projectl.pngbin0 -> 3787 bytes
-rw-r--r--games-action/projectl/metadata.xml9
-rw-r--r--games-action/projectl/projectl-1.001.ebuild62
-rw-r--r--games-action/reflectball/Manifest5
-rw-r--r--games-action/reflectball/files/digest-reflectball-0.113
-rw-r--r--games-action/reflectball/files/reflectball-0.11.diff405
-rw-r--r--games-action/reflectball/files/reflectball.pngbin0 -> 1034 bytes
-rw-r--r--games-action/reflectball/metadata.xml9
-rw-r--r--games-action/reflectball/reflectball-0.11.ebuild58
-rw-r--r--games-action/supertirititran/Manifest5
-rw-r--r--games-action/supertirititran/files/0.9-gentoopath.diff24
-rw-r--r--games-action/supertirititran/files/supertirititran.pngbin0 -> 5767 bytes
-rw-r--r--games-action/supertirititran/metadata.xml9
-rw-r--r--games-action/supertirititran/supertirititran-0.9.ebuild40
-rw-r--r--games-action/tatan/Manifest5
-rw-r--r--games-action/tatan/files/digest-tatan-1.03
-rw-r--r--games-action/tatan/files/tatan-1.0.diff123
-rw-r--r--games-action/tatan/files/tatan.pngbin0 -> 2241 bytes
-rw-r--r--games-action/tatan/metadata.xml9
-rw-r--r--games-action/tatan/tatan-1.0.ebuild57
-rw-r--r--games-action/titanion/Manifest5
-rw-r--r--games-action/titanion/files/digest-titanion-0.33
-rw-r--r--games-action/titanion/files/titanion-0.3.diff616
-rw-r--r--games-action/titanion/files/titanion.pngbin0 -> 2741 bytes
-rw-r--r--games-action/titanion/metadata.xml9
-rw-r--r--games-action/titanion/titanion-0.3.ebuild64
-rw-r--r--games-action/torustrooper/Manifest5
-rw-r--r--games-action/torustrooper/files/digest-torustrooper-0.223
-rw-r--r--games-action/torustrooper/files/torustrooper-0.22.diff881
-rw-r--r--games-action/torustrooper/files/torustrooper.pngbin0 -> 3106 bytes
-rw-r--r--games-action/torustrooper/metadata.xml9
-rw-r--r--games-action/torustrooper/torustrooper-0.22.ebuild63
-rw-r--r--games-action/torustrooperpure/Manifest5
-rw-r--r--games-action/torustrooperpure/files/digest-torustrooperpure-0.23
-rw-r--r--games-action/torustrooperpure/files/torustrooperpure-0.2.diff781
-rw-r--r--games-action/torustrooperpure/files/torustrooperpure.pngbin0 -> 7754 bytes
-rw-r--r--games-action/torustrooperpure/metadata.xml9
-rw-r--r--games-action/torustrooperpure/torustrooperpure-0.2.ebuild62
-rw-r--r--games-action/tumikifighters/Manifest5
-rw-r--r--games-action/tumikifighters/files/digest-tumikifighters-0.23
-rw-r--r--games-action/tumikifighters/files/tumikifighters-0.2.diff1285
-rw-r--r--games-action/tumikifighters/files/tumikifighters.pngbin0 -> 2198 bytes
-rw-r--r--games-action/tumikifighters/metadata.xml9
-rw-r--r--games-action/tumikifighters/tumikifighters-0.2.ebuild63
-rw-r--r--games-action/valandrick/Manifest5
-rw-r--r--games-action/valandrick/files/digest-valandrick-0.1a3
-rw-r--r--games-action/valandrick/files/valandrick-0.1a.diff785
-rw-r--r--games-action/valandrick/files/valandrick.pngbin0 -> 1633 bytes
-rw-r--r--games-action/valandrick/metadata.xml9
-rw-r--r--games-action/valandrick/valandrick-0.1a.ebuild61
-rw-r--r--games-action/zlock/Manifest7
-rw-r--r--games-action/zlock/files/digest-zlock-0.203
-rw-r--r--games-action/zlock/files/zlock-0.20.diff1182
-rw-r--r--games-action/zlock/files/zlock-config.datbin0 -> 36 bytes
-rw-r--r--games-action/zlock/files/zlock-score.datbin0 -> 120 bytes
-rw-r--r--games-action/zlock/files/zlock.pngbin0 -> 1203 bytes
-rw-r--r--games-action/zlock/metadata.xml9
-rw-r--r--games-action/zlock/zlock-0.20.ebuild68
126 files changed, 18106 insertions, 0 deletions
diff --git a/games-action/a7xpg/Manifest b/games-action/a7xpg/Manifest
new file mode 100644
index 0000000..c01956d
--- /dev/null
+++ b/games-action/a7xpg/Manifest
@@ -0,0 +1,6 @@
+AUX a7xpg-0.11.diff 115868 RMD160 e81940e372c22ef0227cdf3babe671999c984932 SHA1 41fbe1a2afcc28aeafc47702945975b5c8b48b07 SHA256 0925c69756bf3d7f7d2f8e426cf5174bd219ea066a5d41e1de1279c4149c5dc1
+AUX a7xpg.png 2930 RMD160 1fc5a9004a1d5008f3bb16c6ba3fc010f7e3f91e SHA1 295fe8ba15d43aaadac6755d9262c8a9acff92d0 SHA256 0bd3106821d6798d40880f545e3299476272e6d0651a5074012f5fceccc76f90
+AUX a7xpg.prf 8 RMD160 64d6d8392fb10150e4ae3cd10855865f5541964b SHA1 0df9019fab513592066cc292d412b9054575d844 SHA256 71c670db8b9d9dd3fa17d83bd98e4a9814f926121972774bd419fa402fe01dc7
+DIST a7xpg0_11.zip 3960261 RMD160 e2318b08743eeec62b9615e8e1f14c0a6b633ab6 SHA1 36fa681320076c9aae0f144360af7be36f7c4b00 SHA256 128c0485794732262e1685e2afaf7521f2dd9468ac8587f0afb166b4e5cf4b12
+EBUILD a7xpg-0.11.ebuild 1483 RMD160 c81aff7a7388c09d53188950b48204942ab3fe07 SHA1 3e611192e9493cb65da78006b4a6b91ca61c189e SHA256 6ed44ec8f3396f4e50babe83c2998aec00b8ac644566fe43ef6f1cc456c90741
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/a7xpg/a7xpg-0.11.ebuild b/games-action/a7xpg/a7xpg-0.11.ebuild
new file mode 100644
index 0000000..871478e
--- /dev/null
+++ b/games-action/a7xpg/a7xpg-0.11.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=a7xpg
+MY_PV=${PV//./_}
+
+DESCRIPTION="The retro modern high speed shooting game"
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/a7xpg_e.html"
+SRC_URI="mirror://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${PN}
+
+src_unpack(){
+ unpack ${A}
+}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/Texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/Sound.d \
+ -e 's:"\(a7xpg.prf[^"]*\)":"'${GAMES_STATEDIR}'/\1":g' -i src/abagames/a7xpg/A7xPrefManager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/"${PN}"
+ doins -r images sounds || die
+
+ if [ ! -e "${GAMES_STATEDIR}"/${PN}.prf ]
+ then
+ dodir "${GAMES_STATEDIR}"
+ insinto "${GAMES_STATEDIR}"
+ doins "${FILESDIR}"/a7xpg.prf || die
+ fperms 660 "${FILESDIR}"/a7xpg.prf
+ fi
+
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ chmod ug+rw "${GAMES_STATEDIR}"/${PN}.prf
+}
diff --git a/games-action/a7xpg/files/a7xpg-0.11.diff b/games-action/a7xpg/files/a7xpg-0.11.diff
new file mode 100644
index 0000000..ca57402
--- /dev/null
+++ b/games-action/a7xpg/files/a7xpg-0.11.diff
@@ -0,0 +1,2907 @@
+diff -Naur a7xpg/import/opengl.d a7xpg-gentoo/import/opengl.d
+--- a7xpg/import/opengl.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/opengl.d 2007-09-19 22:13:30.000000000 +0200
+@@ -1,6 +1,6 @@
+-import windows;
+
+-extern(Windows):
++ extern(C):
++
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1111,345 +1111,343 @@
+
+ /*************************************************************/
+
+-extern(Windows) void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-extern(Windows) void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
+-extern(Windows) GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+-extern(Windows) void /*APIENTRY*/glArrayElement (GLint i);
+-extern(Windows) void /*APIENTRY*/glBegin (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glBindTexture (GLenum target, GLuint texture);
+-extern(Windows) void /*APIENTRY*/glBitmap (GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, GLubyte *bitmap);
+-extern(Windows) void /*APIENTRY*/glBlendFunc (GLenum sfactor, GLenum dfactor);
+-extern(Windows) void /*APIENTRY*/glCallList (GLuint list);
+-extern(Windows) void /*APIENTRY*/glCallLists (GLsizei n, GLenum type, GLvoid *lists);
+-extern(Windows) void /*APIENTRY*/glClear (GLbitfield mask);
+-extern(Windows) void /*APIENTRY*/glClearAccum (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+-extern(Windows) void /*APIENTRY*/glClearColor (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
+-extern(Windows) void /*APIENTRY*/glClearDepth (GLclampd depth);
+-extern(Windows) void /*APIENTRY*/glClearIndex (GLfloat c);
+-extern(Windows) void /*APIENTRY*/glClearStencil (GLint s);
+-extern(Windows) void /*APIENTRY*/glClipPlane (GLenum plane, GLdouble *equation);
+-extern(Windows) void /*APIENTRY*/glColor3b (GLbyte red, GLbyte green, GLbyte blue);
+-extern(Windows) void /*APIENTRY*/glColor3bv (GLbyte *v);
+-extern(Windows) void /*APIENTRY*/glColor3d (GLdouble red, GLdouble green, GLdouble blue);
+-extern(Windows) void /*APIENTRY*/glColor3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glColor3f (GLfloat red, GLfloat green, GLfloat blue);
+-extern(Windows) void /*APIENTRY*/glColor3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glColor3i (GLint red, GLint green, GLint blue);
+-extern(Windows) void /*APIENTRY*/glColor3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glColor3s (GLshort red, GLshort green, GLshort blue);
+-extern(Windows) void /*APIENTRY*/glColor3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glColor3ub (GLubyte red, GLubyte green, GLubyte blue);
+-extern(Windows) void /*APIENTRY*/glColor3ubv (GLubyte *v);
+-extern(Windows) void /*APIENTRY*/glColor3ui (GLuint red, GLuint green, GLuint blue);
+-extern(Windows) void /*APIENTRY*/glColor3uiv (GLuint *v);
+-extern(Windows) void /*APIENTRY*/glColor3us (GLushort red, GLushort green, GLushort blue);
+-extern(Windows) void /*APIENTRY*/glColor3usv (GLushort *v);
+-extern(Windows) void /*APIENTRY*/glColor4b (GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+-extern(Windows) void /*APIENTRY*/glColor4bv (GLbyte *v);
+-extern(Windows) void /*APIENTRY*/glColor4d (GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+-extern(Windows) void /*APIENTRY*/glColor4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glColor4f (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+-extern(Windows) void /*APIENTRY*/glColor4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glColor4i (GLint red, GLint green, GLint blue, GLint alpha);
+-extern(Windows) void /*APIENTRY*/glColor4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glColor4s (GLshort red, GLshort green, GLshort blue, GLshort alpha);
+-extern(Windows) void /*APIENTRY*/glColor4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glColor4ub (GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+-extern(Windows) void /*APIENTRY*/glColor4ubv (GLubyte *v);
+-extern(Windows) void /*APIENTRY*/glColor4ui (GLuint red, GLuint green, GLuint blue, GLuint alpha);
+-extern(Windows) void /*APIENTRY*/glColor4uiv (GLuint *v);
+-extern(Windows) void /*APIENTRY*/glColor4us (GLushort red, GLushort green, GLushort blue, GLushort alpha);
+-extern(Windows) void /*APIENTRY*/glColor4usv (GLushort *v);
+-extern(Windows) void /*APIENTRY*/glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+-extern(Windows) void /*APIENTRY*/glColorMaterial (GLenum face, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glColorPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glCopyPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+-extern(Windows) void /*APIENTRY*/glCopyTexImage1D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+-extern(Windows) void /*APIENTRY*/glCopyTexImage2D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+-extern(Windows) void /*APIENTRY*/glCopyTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+-extern(Windows) void /*APIENTRY*/glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+-extern(Windows) void /*APIENTRY*/glCullFace (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glDeleteLists (GLuint list, GLsizei range);
+-extern(Windows) void /*APIENTRY*/glDeleteTextures (GLsizei n, GLuint *textures);
+-extern(Windows) void /*APIENTRY*/glDepthFunc (GLenum func);
+-extern(Windows) void /*APIENTRY*/glDepthMask (GLboolean flag);
+-extern(Windows) void /*APIENTRY*/glDepthRange (GLclampd zNear, GLclampd zFar);
+-extern(Windows) void /*APIENTRY*/glDisable (GLenum cap);
+-extern(Windows) void /*APIENTRY*/glDisableClientState (GLenum array);
+-extern(Windows) void /*APIENTRY*/glDrawArrays (GLenum mode, GLint first, GLsizei count);
+-extern(Windows) void /*APIENTRY*/glDrawBuffer (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glDrawElements (GLenum mode, GLsizei count, GLenum type, GLvoid *indices);
+-extern(Windows) void /*APIENTRY*/glDrawPixels (GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glEdgeFlag (GLboolean flag);
+-extern(Windows) void /*APIENTRY*/glEdgeFlagPointer (GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glEdgeFlagv (GLboolean *flag);
+-extern(Windows) void /*APIENTRY*/glEnable (GLenum cap);
+-extern(Windows) void /*APIENTRY*/glEnableClientState (GLenum array);
+-extern(Windows) void /*APIENTRY*/glEnd ();
+-extern(Windows) void /*APIENTRY*/glEndList ();
+-extern(Windows) void /*APIENTRY*/glEvalCoord1d (GLdouble u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord1dv (GLdouble *u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord1f (GLfloat u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord1fv (GLfloat *u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2d (GLdouble u, GLdouble v);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2dv (GLdouble *u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2f (GLfloat u, GLfloat v);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2fv (GLfloat *u);
+-extern(Windows) void /*APIENTRY*/glEvalMesh1 (GLenum mode, GLint i1, GLint i2);
+-extern(Windows) void /*APIENTRY*/glEvalMesh2 (GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+-extern(Windows) void /*APIENTRY*/glEvalPoint1 (GLint i);
+-extern(Windows) void /*APIENTRY*/glEvalPoint2 (GLint i, GLint j);
+-extern(Windows) void /*APIENTRY*/glFeedbackBuffer (GLsizei size, GLenum type, GLfloat *buffer);
+-extern(Windows) void /*APIENTRY*/glFinish ();
+-extern(Windows) void /*APIENTRY*/glFlush ();
+-extern(Windows) void /*APIENTRY*/glFogf (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glFogfv (GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glFogi (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glFogiv (GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glFrontFace (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glFrustum (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+-extern(Windows) GLuint /*APIENTRY*/glGenLists (GLsizei range);
+-extern(Windows) void /*APIENTRY*/glGenTextures (GLsizei n, GLuint *textures);
+-extern(Windows) void /*APIENTRY*/glGetBooleanv (GLenum pname, GLboolean *params);
+-extern(Windows) void /*APIENTRY*/glGetClipPlane (GLenum plane, GLdouble *equation);
+-extern(Windows) void /*APIENTRY*/glGetDoublev (GLenum pname, GLdouble *params);
+-extern(Windows) GLenum /*APIENTRY*/glGetError ();
+-extern(Windows) void /*APIENTRY*/glGetFloatv (GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetIntegerv (GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetLightfv (GLenum light, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetLightiv (GLenum light, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetMapdv (GLenum target, GLenum query, GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glGetMapfv (GLenum target, GLenum query, GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glGetMapiv (GLenum target, GLenum query, GLint *v);
+-extern(Windows) void /*APIENTRY*/glGetMaterialfv (GLenum face, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetMaterialiv (GLenum face, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetPixelMapfv (GLenum map, GLfloat *values);
+-extern(Windows) void /*APIENTRY*/glGetPixelMapuiv (GLenum map, GLuint *values);
+-extern(Windows) void /*APIENTRY*/glGetPixelMapusv (GLenum map, GLushort *values);
+-extern(Windows) void /*APIENTRY*/glGetPointerv (GLenum pname, GLvoid* *params);
+-extern(Windows) void /*APIENTRY*/glGetPolygonStipple (GLubyte *mask);
+-extern(Windows) GLubyte * /*APIENTRY*/glGetString (GLenum name);
+-extern(Windows) void /*APIENTRY*/glGetTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexEnviv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetTexGendv (GLenum coord, GLenum pname, GLdouble *params);
+-extern(Windows) void /*APIENTRY*/glGetTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexGeniv (GLenum coord, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetTexImage (GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glGetTexLevelParameterfv (GLenum target, GLint level, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexLevelParameteriv (GLenum target, GLint level, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexParameteriv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glHint (GLenum target, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glIndexMask (GLuint mask);
+-extern(Windows) void /*APIENTRY*/glIndexPointer (GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glIndexd (GLdouble c);
+-extern(Windows) void /*APIENTRY*/glIndexdv (GLdouble *c);
+-extern(Windows) void /*APIENTRY*/glIndexf (GLfloat c);
+-extern(Windows) void /*APIENTRY*/glIndexfv (GLfloat *c);
+-extern(Windows) void /*APIENTRY*/glIndexi (GLint c);
+-extern(Windows) void /*APIENTRY*/glIndexiv (GLint *c);
+-extern(Windows) void /*APIENTRY*/glIndexs (GLshort c);
+-extern(Windows) void /*APIENTRY*/glIndexsv (GLshort *c);
+-extern(Windows) void /*APIENTRY*/glIndexub (GLubyte c);
+-extern(Windows) void /*APIENTRY*/glIndexubv (GLubyte *c);
+-extern(Windows) void /*APIENTRY*/glInitNames ();
+-extern(Windows) void /*APIENTRY*/glInterleavedArrays (GLenum format, GLsizei stride, GLvoid *pointer);
+-extern(Windows) GLboolean /*APIENTRY*/glIsEnabled (GLenum cap);
+-extern(Windows) GLboolean /*APIENTRY*/glIsList (GLuint list);
+-extern(Windows) GLboolean /*APIENTRY*/glIsTexture (GLuint texture);
+-extern(Windows) void /*APIENTRY*/glLightModelf (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glLightModelfv (GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glLightModeli (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glLightModeliv (GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glLightf (GLenum light, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glLightfv (GLenum light, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glLighti (GLenum light, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glLightiv (GLenum light, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glLineStipple (GLint factor, GLushort pattern);
+-extern(Windows) void /*APIENTRY*/glLineWidth (GLfloat width);
+-extern(Windows) void /*APIENTRY*/glListBase (GLuint base);
+-extern(Windows) void /*APIENTRY*/glLoadIdentity ();
+-extern(Windows) void /*APIENTRY*/glLoadMatrixd (GLdouble *m);
+-extern(Windows) void /*APIENTRY*/glLoadMatrixf (GLfloat *m);
+-extern(Windows) void /*APIENTRY*/glLoadName (GLuint name);
+-extern(Windows) void /*APIENTRY*/glLogicOp (GLenum opcode);
+-extern(Windows) void /*APIENTRY*/glMap1d (GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, GLdouble *points);
+-extern(Windows) void /*APIENTRY*/glMap1f (GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, GLfloat *points);
+-extern(Windows) void /*APIENTRY*/glMap2d (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble *points);
+-extern(Windows) void /*APIENTRY*/glMap2f (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat *points);
+-extern(Windows) void /*APIENTRY*/glMapGrid1d (GLint un, GLdouble u1, GLdouble u2);
+-extern(Windows) void /*APIENTRY*/glMapGrid1f (GLint un, GLfloat u1, GLfloat u2);
+-extern(Windows) void /*APIENTRY*/glMapGrid2d (GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+-extern(Windows) void /*APIENTRY*/glMapGrid2f (GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+-extern(Windows) void /*APIENTRY*/glMaterialf (GLenum face, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glMaterialfv (GLenum face, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glMateriali (GLenum face, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glMaterialiv (GLenum face, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glMatrixMode (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glMultMatrixd (GLdouble *m);
+-extern(Windows) void /*APIENTRY*/glMultMatrixf (GLfloat *m);
+-extern(Windows) void /*APIENTRY*/glNewList (GLuint list, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glNormal3b (GLbyte nx, GLbyte ny, GLbyte nz);
+-extern(Windows) void /*APIENTRY*/glNormal3bv (GLbyte *v);
+-extern(Windows) void /*APIENTRY*/glNormal3d (GLdouble nx, GLdouble ny, GLdouble nz);
+-extern(Windows) void /*APIENTRY*/glNormal3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glNormal3f (GLfloat nx, GLfloat ny, GLfloat nz);
+-extern(Windows) void /*APIENTRY*/glNormal3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glNormal3i (GLint nx, GLint ny, GLint nz);
+-extern(Windows) void /*APIENTRY*/glNormal3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glNormal3s (GLshort nx, GLshort ny, GLshort nz);
+-extern(Windows) void /*APIENTRY*/glNormal3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glNormalPointer (GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glOrtho (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+-extern(Windows) void /*APIENTRY*/glPassThrough (GLfloat token);
+-extern(Windows) void /*APIENTRY*/glPixelMapfv (GLenum map, GLsizei mapsize, GLfloat *values);
+-extern(Windows) void /*APIENTRY*/glPixelMapuiv (GLenum map, GLsizei mapsize, GLuint *values);
+-extern(Windows) void /*APIENTRY*/glPixelMapusv (GLenum map, GLsizei mapsize, GLushort *values);
+-extern(Windows) void /*APIENTRY*/glPixelStoref (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glPixelStorei (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glPixelTransferf (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glPixelTransferi (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glPixelZoom (GLfloat xfactor, GLfloat yfactor);
+-extern(Windows) void /*APIENTRY*/glPointSize (GLfloat size);
+-extern(Windows) void /*APIENTRY*/glPolygonMode (GLenum face, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glPolygonOffset (GLfloat factor, GLfloat units);
+-extern(Windows) void /*APIENTRY*/glPolygonStipple (GLubyte *mask);
+-extern(Windows) void /*APIENTRY*/glPopAttrib ();
+-extern(Windows) void /*APIENTRY*/glPopClientAttrib ();
+-extern(Windows) void /*APIENTRY*/glPopMatrix ();
+-extern(Windows) void /*APIENTRY*/glPopName ();
+-extern(Windows) void /*APIENTRY*/glPrioritizeTextures (GLsizei n, GLuint *textures, GLclampf *priorities);
+-extern(Windows) void /*APIENTRY*/glPushAttrib (GLbitfield mask);
+-extern(Windows) void /*APIENTRY*/glPushClientAttrib (GLbitfield mask);
+-extern(Windows) void /*APIENTRY*/glPushMatrix ();
+-extern(Windows) void /*APIENTRY*/glPushName (GLuint name);
+-extern(Windows) void /*APIENTRY*/glRasterPos2d (GLdouble x, GLdouble y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos2f (GLfloat x, GLfloat y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos2i (GLint x, GLint y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos2s (GLshort x, GLshort y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3d (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3f (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3i (GLint x, GLint y, GLint z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3s (GLshort x, GLshort y, GLshort z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4i (GLint x, GLint y, GLint z, GLint w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4s (GLshort x, GLshort y, GLshort z, GLshort w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glReadBuffer (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glRectd (GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+-extern(Windows) void /*APIENTRY*/glRectdv (GLdouble *v1, GLdouble *v2);
+-extern(Windows) void /*APIENTRY*/glRectf (GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+-extern(Windows) void /*APIENTRY*/glRectfv (GLfloat *v1, GLfloat *v2);
+-extern(Windows) void /*APIENTRY*/glRecti (GLint x1, GLint y1, GLint x2, GLint y2);
+-extern(Windows) void /*APIENTRY*/glRectiv (GLint *v1, GLint *v2);
+-extern(Windows) void /*APIENTRY*/glRects (GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+-extern(Windows) void /*APIENTRY*/glRectsv (GLshort *v1, GLshort *v2);
+-extern(Windows) GLint /*APIENTRY*/glRenderMode (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glRotated (GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glRotatef (GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glScaled (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glScalef (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+-extern(Windows) void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+-extern(Windows) void /*APIENTRY*/glShadeModel (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
+-extern(Windows) void /*APIENTRY*/glStencilMask (GLuint mask);
+-extern(Windows) void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+-extern(Windows) void /*APIENTRY*/glTexCoord1d (GLdouble s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord1f (GLfloat s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord1i (GLint s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord1s (GLshort s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2d (GLdouble s, GLdouble t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2f (GLfloat s, GLfloat t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2i (GLint s, GLint t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2s (GLshort s, GLshort t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3d (GLdouble s, GLdouble t, GLdouble r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3f (GLfloat s, GLfloat t, GLfloat r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3i (GLint s, GLint t, GLint r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3s (GLshort s, GLshort t, GLshort r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4d (GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4f (GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4i (GLint s, GLint t, GLint r, GLint q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4s (GLshort s, GLshort t, GLshort r, GLshort q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoordPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glTexEnvf (GLenum target, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glTexEnvi (GLenum target, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glTexEnviv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glTexGend (GLenum coord, GLenum pname, GLdouble param);
+-extern(Windows) void /*APIENTRY*/glTexGendv (GLenum coord, GLenum pname, GLdouble *params);
+-extern(Windows) void /*APIENTRY*/glTexGenf (GLenum coord, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glTexGeni (GLenum coord, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glTexGeniv (GLenum coord, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glTexImage1D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTexParameterf (GLenum target, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glTexParameteri (GLenum target, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glTexParameteriv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTranslated (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glTranslatef (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glVertex2d (GLdouble x, GLdouble y);
+-extern(Windows) void /*APIENTRY*/glVertex2dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glVertex2f (GLfloat x, GLfloat y);
+-extern(Windows) void /*APIENTRY*/glVertex2fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glVertex2i (GLint x, GLint y);
+-extern(Windows) void /*APIENTRY*/glVertex2iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glVertex2s (GLshort x, GLshort y);
+-extern(Windows) void /*APIENTRY*/glVertex2sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glVertex3d (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glVertex3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glVertex3f (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glVertex3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glVertex3i (GLint x, GLint y, GLint z);
+-extern(Windows) void /*APIENTRY*/glVertex3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glVertex3s (GLshort x, GLshort y, GLshort z);
+-extern(Windows) void /*APIENTRY*/glVertex3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glVertex4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+-extern(Windows) void /*APIENTRY*/glVertex4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glVertex4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+-extern(Windows) void /*APIENTRY*/glVertex4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glVertex4i (GLint x, GLint y, GLint z, GLint w);
+-extern(Windows) void /*APIENTRY*/glVertex4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glVertex4s (GLshort x, GLshort y, GLshort z, GLshort w);
+-extern(Windows) void /*APIENTRY*/glVertex4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glVertexPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glViewport (GLint x, GLint y, GLsizei width, GLsizei height);
+-
++void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
++GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
++void /*APIENTRY*/glArrayElement (GLint i);
++void /*APIENTRY*/glBegin (GLenum mode);
++void /*APIENTRY*/glBindTexture (GLenum target, GLuint texture);
++void /*APIENTRY*/glBitmap (GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, GLubyte *bitmap);
++void /*APIENTRY*/glBlendFunc (GLenum sfactor, GLenum dfactor);
++void /*APIENTRY*/glCallList (GLuint list);
++void /*APIENTRY*/glCallLists (GLsizei n, GLenum type, GLvoid *lists);
++void /*APIENTRY*/glClear (GLbitfield mask);
++void /*APIENTRY*/glClearAccum (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
++void /*APIENTRY*/glClearColor (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
++void /*APIENTRY*/glClearDepth (GLclampd depth);
++void /*APIENTRY*/glClearIndex (GLfloat c);
++void /*APIENTRY*/glClearStencil (GLint s);
++void /*APIENTRY*/glClipPlane (GLenum plane, GLdouble *equation);
++void /*APIENTRY*/glColor3b (GLbyte red, GLbyte green, GLbyte blue);
++void /*APIENTRY*/glColor3bv (GLbyte *v);
++void /*APIENTRY*/glColor3d (GLdouble red, GLdouble green, GLdouble blue);
++void /*APIENTRY*/glColor3dv (GLdouble *v);
++void /*APIENTRY*/glColor3f (GLfloat red, GLfloat green, GLfloat blue);
++void /*APIENTRY*/glColor3fv (GLfloat *v);
++void /*APIENTRY*/glColor3i (GLint red, GLint green, GLint blue);
++void /*APIENTRY*/glColor3iv (GLint *v);
++void /*APIENTRY*/glColor3s (GLshort red, GLshort green, GLshort blue);
++void /*APIENTRY*/glColor3sv (GLshort *v);
++void /*APIENTRY*/glColor3ub (GLubyte red, GLubyte green, GLubyte blue);
++void /*APIENTRY*/glColor3ubv (GLubyte *v);
++void /*APIENTRY*/glColor3ui (GLuint red, GLuint green, GLuint blue);
++void /*APIENTRY*/glColor3uiv (GLuint *v);
++void /*APIENTRY*/glColor3us (GLushort red, GLushort green, GLushort blue);
++void /*APIENTRY*/glColor3usv (GLushort *v);
++void /*APIENTRY*/glColor4b (GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
++void /*APIENTRY*/glColor4bv (GLbyte *v);
++void /*APIENTRY*/glColor4d (GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
++void /*APIENTRY*/glColor4dv (GLdouble *v);
++void /*APIENTRY*/glColor4f (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
++void /*APIENTRY*/glColor4fv (GLfloat *v);
++void /*APIENTRY*/glColor4i (GLint red, GLint green, GLint blue, GLint alpha);
++void /*APIENTRY*/glColor4iv (GLint *v);
++void /*APIENTRY*/glColor4s (GLshort red, GLshort green, GLshort blue, GLshort alpha);
++void /*APIENTRY*/glColor4sv (GLshort *v);
++void /*APIENTRY*/glColor4ub (GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
++void /*APIENTRY*/glColor4ubv (GLubyte *v);
++void /*APIENTRY*/glColor4ui (GLuint red, GLuint green, GLuint blue, GLuint alpha);
++void /*APIENTRY*/glColor4uiv (GLuint *v);
++void /*APIENTRY*/glColor4us (GLushort red, GLushort green, GLushort blue, GLushort alpha);
++void /*APIENTRY*/glColor4usv (GLushort *v);
++void /*APIENTRY*/glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
++void /*APIENTRY*/glColorMaterial (GLenum face, GLenum mode);
++void /*APIENTRY*/glColorPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glCopyPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
++void /*APIENTRY*/glCopyTexImage1D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
++void /*APIENTRY*/glCopyTexImage2D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
++void /*APIENTRY*/glCopyTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
++void /*APIENTRY*/glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
++void /*APIENTRY*/glCullFace (GLenum mode);
++void /*APIENTRY*/glDeleteLists (GLuint list, GLsizei range);
++void /*APIENTRY*/glDeleteTextures (GLsizei n, GLuint *textures);
++void /*APIENTRY*/glDepthFunc (GLenum func);
++void /*APIENTRY*/glDepthMask (GLboolean flag);
++void /*APIENTRY*/glDepthRange (GLclampd zNear, GLclampd zFar);
++void /*APIENTRY*/glDisable (GLenum cap);
++void /*APIENTRY*/glDisableClientState (GLenum array);
++void /*APIENTRY*/glDrawArrays (GLenum mode, GLint first, GLsizei count);
++void /*APIENTRY*/glDrawBuffer (GLenum mode);
++void /*APIENTRY*/glDrawElements (GLenum mode, GLsizei count, GLenum type, GLvoid *indices);
++void /*APIENTRY*/glDrawPixels (GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glEdgeFlag (GLboolean flag);
++void /*APIENTRY*/glEdgeFlagPointer (GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glEdgeFlagv (GLboolean *flag);
++void /*APIENTRY*/glEnable (GLenum cap);
++void /*APIENTRY*/glEnableClientState (GLenum array);
++void /*APIENTRY*/glEnd ();
++void /*APIENTRY*/glEndList ();
++void /*APIENTRY*/glEvalCoord1d (GLdouble u);
++void /*APIENTRY*/glEvalCoord1dv (GLdouble *u);
++void /*APIENTRY*/glEvalCoord1f (GLfloat u);
++void /*APIENTRY*/glEvalCoord1fv (GLfloat *u);
++void /*APIENTRY*/glEvalCoord2d (GLdouble u, GLdouble v);
++void /*APIENTRY*/glEvalCoord2dv (GLdouble *u);
++void /*APIENTRY*/glEvalCoord2f (GLfloat u, GLfloat v);
++void /*APIENTRY*/glEvalCoord2fv (GLfloat *u);
++void /*APIENTRY*/glEvalMesh1 (GLenum mode, GLint i1, GLint i2);
++void /*APIENTRY*/glEvalMesh2 (GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
++void /*APIENTRY*/glEvalPoint1 (GLint i);
++void /*APIENTRY*/glEvalPoint2 (GLint i, GLint j);
++void /*APIENTRY*/glFeedbackBuffer (GLsizei size, GLenum type, GLfloat *buffer);
++void /*APIENTRY*/glFinish ();
++void /*APIENTRY*/glFlush ();
++void /*APIENTRY*/glFogf (GLenum pname, GLfloat param);
++void /*APIENTRY*/glFogfv (GLenum pname, GLfloat *params);
++void /*APIENTRY*/glFogi (GLenum pname, GLint param);
++void /*APIENTRY*/glFogiv (GLenum pname, GLint *params);
++void /*APIENTRY*/glFrontFace (GLenum mode);
++void /*APIENTRY*/glFrustum (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
++GLuint /*APIENTRY*/glGenLists (GLsizei range);
++void /*APIENTRY*/glGenTextures (GLsizei n, GLuint *textures);
++void /*APIENTRY*/glGetBooleanv (GLenum pname, GLboolean *params);
++void /*APIENTRY*/glGetClipPlane (GLenum plane, GLdouble *equation);
++void /*APIENTRY*/glGetDoublev (GLenum pname, GLdouble *params);
++GLenum /*APIENTRY*/glGetError ();
++void /*APIENTRY*/glGetFloatv (GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetIntegerv (GLenum pname, GLint *params);
++void /*APIENTRY*/glGetLightfv (GLenum light, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetLightiv (GLenum light, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetMapdv (GLenum target, GLenum query, GLdouble *v);
++void /*APIENTRY*/glGetMapfv (GLenum target, GLenum query, GLfloat *v);
++void /*APIENTRY*/glGetMapiv (GLenum target, GLenum query, GLint *v);
++void /*APIENTRY*/glGetMaterialfv (GLenum face, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetMaterialiv (GLenum face, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetPixelMapfv (GLenum map, GLfloat *values);
++void /*APIENTRY*/glGetPixelMapuiv (GLenum map, GLuint *values);
++void /*APIENTRY*/glGetPixelMapusv (GLenum map, GLushort *values);
++void /*APIENTRY*/glGetPointerv (GLenum pname, GLvoid* *params);
++void /*APIENTRY*/glGetPolygonStipple (GLubyte *mask);
++GLubyte * /*APIENTRY*/glGetString (GLenum name);
++void /*APIENTRY*/glGetTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexEnviv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetTexGendv (GLenum coord, GLenum pname, GLdouble *params);
++void /*APIENTRY*/glGetTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexGeniv (GLenum coord, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetTexImage (GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glGetTexLevelParameterfv (GLenum target, GLint level, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexLevelParameteriv (GLenum target, GLint level, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexParameteriv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glHint (GLenum target, GLenum mode);
++void /*APIENTRY*/glIndexMask (GLuint mask);
++void /*APIENTRY*/glIndexPointer (GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glIndexd (GLdouble c);
++void /*APIENTRY*/glIndexdv (GLdouble *c);
++void /*APIENTRY*/glIndexf (GLfloat c);
++void /*APIENTRY*/glIndexfv (GLfloat *c);
++void /*APIENTRY*/glIndexi (GLint c);
++void /*APIENTRY*/glIndexiv (GLint *c);
++void /*APIENTRY*/glIndexs (GLshort c);
++void /*APIENTRY*/glIndexsv (GLshort *c);
++void /*APIENTRY*/glIndexub (GLubyte c);
++void /*APIENTRY*/glIndexubv (GLubyte *c);
++void /*APIENTRY*/glInitNames ();
++void /*APIENTRY*/glInterleavedArrays (GLenum format, GLsizei stride, GLvoid *pointer);
++GLboolean /*APIENTRY*/glIsEnabled (GLenum cap);
++GLboolean /*APIENTRY*/glIsList (GLuint list);
++GLboolean /*APIENTRY*/glIsTexture (GLuint texture);
++void /*APIENTRY*/glLightModelf (GLenum pname, GLfloat param);
++void /*APIENTRY*/glLightModelfv (GLenum pname, GLfloat *params);
++void /*APIENTRY*/glLightModeli (GLenum pname, GLint param);
++void /*APIENTRY*/glLightModeliv (GLenum pname, GLint *params);
++void /*APIENTRY*/glLightf (GLenum light, GLenum pname, GLfloat param);
++void /*APIENTRY*/glLightfv (GLenum light, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glLighti (GLenum light, GLenum pname, GLint param);
++void /*APIENTRY*/glLightiv (GLenum light, GLenum pname, GLint *params);
++void /*APIENTRY*/glLineStipple (GLint factor, GLushort pattern);
++void /*APIENTRY*/glLineWidth (GLfloat width);
++void /*APIENTRY*/glListBase (GLuint base);
++void /*APIENTRY*/glLoadIdentity ();
++void /*APIENTRY*/glLoadMatrixd (GLdouble *m);
++void /*APIENTRY*/glLoadMatrixf (GLfloat *m);
++void /*APIENTRY*/glLoadName (GLuint name);
++void /*APIENTRY*/glLogicOp (GLenum opcode);
++void /*APIENTRY*/glMap1d (GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, GLdouble *points);
++void /*APIENTRY*/glMap1f (GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, GLfloat *points);
++void /*APIENTRY*/glMap2d (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble *points);
++void /*APIENTRY*/glMap2f (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat *points);
++void /*APIENTRY*/glMapGrid1d (GLint un, GLdouble u1, GLdouble u2);
++void /*APIENTRY*/glMapGrid1f (GLint un, GLfloat u1, GLfloat u2);
++void /*APIENTRY*/glMapGrid2d (GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
++void /*APIENTRY*/glMapGrid2f (GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
++void /*APIENTRY*/glMaterialf (GLenum face, GLenum pname, GLfloat param);
++void /*APIENTRY*/glMaterialfv (GLenum face, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glMateriali (GLenum face, GLenum pname, GLint param);
++void /*APIENTRY*/glMaterialiv (GLenum face, GLenum pname, GLint *params);
++void /*APIENTRY*/glMatrixMode (GLenum mode);
++void /*APIENTRY*/glMultMatrixd (GLdouble *m);
++void /*APIENTRY*/glMultMatrixf (GLfloat *m);
++void /*APIENTRY*/glNewList (GLuint list, GLenum mode);
++void /*APIENTRY*/glNormal3b (GLbyte nx, GLbyte ny, GLbyte nz);
++void /*APIENTRY*/glNormal3bv (GLbyte *v);
++void /*APIENTRY*/glNormal3d (GLdouble nx, GLdouble ny, GLdouble nz);
++void /*APIENTRY*/glNormal3dv (GLdouble *v);
++void /*APIENTRY*/glNormal3f (GLfloat nx, GLfloat ny, GLfloat nz);
++void /*APIENTRY*/glNormal3fv (GLfloat *v);
++void /*APIENTRY*/glNormal3i (GLint nx, GLint ny, GLint nz);
++void /*APIENTRY*/glNormal3iv (GLint *v);
++void /*APIENTRY*/glNormal3s (GLshort nx, GLshort ny, GLshort nz);
++void /*APIENTRY*/glNormal3sv (GLshort *v);
++void /*APIENTRY*/glNormalPointer (GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glOrtho (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
++void /*APIENTRY*/glPassThrough (GLfloat token);
++void /*APIENTRY*/glPixelMapfv (GLenum map, GLsizei mapsize, GLfloat *values);
++void /*APIENTRY*/glPixelMapuiv (GLenum map, GLsizei mapsize, GLuint *values);
++void /*APIENTRY*/glPixelMapusv (GLenum map, GLsizei mapsize, GLushort *values);
++void /*APIENTRY*/glPixelStoref (GLenum pname, GLfloat param);
++void /*APIENTRY*/glPixelStorei (GLenum pname, GLint param);
++void /*APIENTRY*/glPixelTransferf (GLenum pname, GLfloat param);
++void /*APIENTRY*/glPixelTransferi (GLenum pname, GLint param);
++void /*APIENTRY*/glPixelZoom (GLfloat xfactor, GLfloat yfactor);
++void /*APIENTRY*/glPointSize (GLfloat size);
++void /*APIENTRY*/glPolygonMode (GLenum face, GLenum mode);
++void /*APIENTRY*/glPolygonOffset (GLfloat factor, GLfloat units);
++void /*APIENTRY*/glPolygonStipple (GLubyte *mask);
++void /*APIENTRY*/glPopAttrib ();
++void /*APIENTRY*/glPopClientAttrib ();
++void /*APIENTRY*/glPopMatrix ();
++void /*APIENTRY*/glPopName ();
++void /*APIENTRY*/glPrioritizeTextures (GLsizei n, GLuint *textures, GLclampf *priorities);
++void /*APIENTRY*/glPushAttrib (GLbitfield mask);
++void /*APIENTRY*/glPushClientAttrib (GLbitfield mask);
++void /*APIENTRY*/glPushMatrix ();
++void /*APIENTRY*/glPushName (GLuint name);
++void /*APIENTRY*/glRasterPos2d (GLdouble x, GLdouble y);
++void /*APIENTRY*/glRasterPos2dv (GLdouble *v);
++void /*APIENTRY*/glRasterPos2f (GLfloat x, GLfloat y);
++void /*APIENTRY*/glRasterPos2fv (GLfloat *v);
++void /*APIENTRY*/glRasterPos2i (GLint x, GLint y);
++void /*APIENTRY*/glRasterPos2iv (GLint *v);
++void /*APIENTRY*/glRasterPos2s (GLshort x, GLshort y);
++void /*APIENTRY*/glRasterPos2sv (GLshort *v);
++void /*APIENTRY*/glRasterPos3d (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glRasterPos3dv (GLdouble *v);
++void /*APIENTRY*/glRasterPos3f (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glRasterPos3fv (GLfloat *v);
++void /*APIENTRY*/glRasterPos3i (GLint x, GLint y, GLint z);
++void /*APIENTRY*/glRasterPos3iv (GLint *v);
++void /*APIENTRY*/glRasterPos3s (GLshort x, GLshort y, GLshort z);
++void /*APIENTRY*/glRasterPos3sv (GLshort *v);
++void /*APIENTRY*/glRasterPos4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
++void /*APIENTRY*/glRasterPos4dv (GLdouble *v);
++void /*APIENTRY*/glRasterPos4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
++void /*APIENTRY*/glRasterPos4fv (GLfloat *v);
++void /*APIENTRY*/glRasterPos4i (GLint x, GLint y, GLint z, GLint w);
++void /*APIENTRY*/glRasterPos4iv (GLint *v);
++void /*APIENTRY*/glRasterPos4s (GLshort x, GLshort y, GLshort z, GLshort w);
++void /*APIENTRY*/glRasterPos4sv (GLshort *v);
++void /*APIENTRY*/glReadBuffer (GLenum mode);
++void /*APIENTRY*/glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glRectd (GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
++void /*APIENTRY*/glRectdv (GLdouble *v1, GLdouble *v2);
++void /*APIENTRY*/glRectf (GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
++void /*APIENTRY*/glRectfv (GLfloat *v1, GLfloat *v2);
++void /*APIENTRY*/glRecti (GLint x1, GLint y1, GLint x2, GLint y2);
++void /*APIENTRY*/glRectiv (GLint *v1, GLint *v2);
++void /*APIENTRY*/glRects (GLshort x1, GLshort y1, GLshort x2, GLshort y2);
++void /*APIENTRY*/glRectsv (GLshort *v1, GLshort *v2);
++GLint /*APIENTRY*/glRenderMode (GLenum mode);
++void /*APIENTRY*/glRotated (GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glRotatef (GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glScaled (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glScalef (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
++void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
++void /*APIENTRY*/glShadeModel (GLenum mode);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
++void /*APIENTRY*/glStencilMask (GLuint mask);
++void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
++void /*APIENTRY*/glTexCoord1d (GLdouble s);
++void /*APIENTRY*/glTexCoord1dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord1f (GLfloat s);
++void /*APIENTRY*/glTexCoord1fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord1i (GLint s);
++void /*APIENTRY*/glTexCoord1iv (GLint *v);
++void /*APIENTRY*/glTexCoord1s (GLshort s);
++void /*APIENTRY*/glTexCoord1sv (GLshort *v);
++void /*APIENTRY*/glTexCoord2d (GLdouble s, GLdouble t);
++void /*APIENTRY*/glTexCoord2dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord2f (GLfloat s, GLfloat t);
++void /*APIENTRY*/glTexCoord2fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord2i (GLint s, GLint t);
++void /*APIENTRY*/glTexCoord2iv (GLint *v);
++void /*APIENTRY*/glTexCoord2s (GLshort s, GLshort t);
++void /*APIENTRY*/glTexCoord2sv (GLshort *v);
++void /*APIENTRY*/glTexCoord3d (GLdouble s, GLdouble t, GLdouble r);
++void /*APIENTRY*/glTexCoord3dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord3f (GLfloat s, GLfloat t, GLfloat r);
++void /*APIENTRY*/glTexCoord3fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord3i (GLint s, GLint t, GLint r);
++void /*APIENTRY*/glTexCoord3iv (GLint *v);
++void /*APIENTRY*/glTexCoord3s (GLshort s, GLshort t, GLshort r);
++void /*APIENTRY*/glTexCoord3sv (GLshort *v);
++void /*APIENTRY*/glTexCoord4d (GLdouble s, GLdouble t, GLdouble r, GLdouble q);
++void /*APIENTRY*/glTexCoord4dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord4f (GLfloat s, GLfloat t, GLfloat r, GLfloat q);
++void /*APIENTRY*/glTexCoord4fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord4i (GLint s, GLint t, GLint r, GLint q);
++void /*APIENTRY*/glTexCoord4iv (GLint *v);
++void /*APIENTRY*/glTexCoord4s (GLshort s, GLshort t, GLshort r, GLshort q);
++void /*APIENTRY*/glTexCoord4sv (GLshort *v);
++void /*APIENTRY*/glTexCoordPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glTexEnvf (GLenum target, GLenum pname, GLfloat param);
++void /*APIENTRY*/glTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glTexEnvi (GLenum target, GLenum pname, GLint param);
++void /*APIENTRY*/glTexEnviv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glTexGend (GLenum coord, GLenum pname, GLdouble param);
++void /*APIENTRY*/glTexGendv (GLenum coord, GLenum pname, GLdouble *params);
++void /*APIENTRY*/glTexGenf (GLenum coord, GLenum pname, GLfloat param);
++void /*APIENTRY*/glTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glTexGeni (GLenum coord, GLenum pname, GLint param);
++void /*APIENTRY*/glTexGeniv (GLenum coord, GLenum pname, GLint *params);
++void /*APIENTRY*/glTexImage1D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTexParameterf (GLenum target, GLenum pname, GLfloat param);
++void /*APIENTRY*/glTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glTexParameteri (GLenum target, GLenum pname, GLint param);
++void /*APIENTRY*/glTexParameteriv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTranslated (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glTranslatef (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glVertex2d (GLdouble x, GLdouble y);
++void /*APIENTRY*/glVertex2dv (GLdouble *v);
++void /*APIENTRY*/glVertex2f (GLfloat x, GLfloat y);
++void /*APIENTRY*/glVertex2fv (GLfloat *v);
++void /*APIENTRY*/glVertex2i (GLint x, GLint y);
++void /*APIENTRY*/glVertex2iv (GLint *v);
++void /*APIENTRY*/glVertex2s (GLshort x, GLshort y);
++void /*APIENTRY*/glVertex2sv (GLshort *v);
++void /*APIENTRY*/glVertex3d (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glVertex3dv (GLdouble *v);
++void /*APIENTRY*/glVertex3f (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glVertex3fv (GLfloat *v);
++void /*APIENTRY*/glVertex3i (GLint x, GLint y, GLint z);
++void /*APIENTRY*/glVertex3iv (GLint *v);
++void /*APIENTRY*/glVertex3s (GLshort x, GLshort y, GLshort z);
++void /*APIENTRY*/glVertex3sv (GLshort *v);
++void /*APIENTRY*/glVertex4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
++void /*APIENTRY*/glVertex4dv (GLdouble *v);
++void /*APIENTRY*/glVertex4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
++void /*APIENTRY*/glVertex4fv (GLfloat *v);
++void /*APIENTRY*/glVertex4i (GLint x, GLint y, GLint z, GLint w);
++void /*APIENTRY*/glVertex4iv (GLint *v);
++void /*APIENTRY*/glVertex4s (GLshort x, GLshort y, GLshort z, GLshort w);
++void /*APIENTRY*/glVertex4sv (GLshort *v);
++void /*APIENTRY*/glVertexPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glViewport (GLint x, GLint y, GLsizei width, GLsizei height);
+
+-extern(Windows):
+
+ /* EXT_vertex_array */
+ typedef void (* PFNGLARRAYELEMENTEXTPROC) (GLint i);
+@@ -1483,4 +1481,4 @@
+ typedef void (* PFNGLGETCOLORTABLEPARAMETERFVEXTPROC)
+ (GLenum target, GLenum pname, GLfloat *params);
+
+-import openglu;
+\ Kein Zeilenumbruch am Dateiende.
++//import openglu;
+diff -Naur a7xpg/import/openglu.d a7xpg-gentoo/import/openglu.d
+--- a7xpg/import/openglu.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/openglu.d 2007-09-19 22:11:52.000000000 +0200
+@@ -1,6 +1,6 @@
+-import opengl;
+
+-extern(Windows):
++ extern(C):
++
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+@@ -357,7 +357,6 @@
+
+ /**** Tesselation constants ****/
+
+-//const extended GLU_TESS_MAX_COORD = 1.0e150;
+ const real GLU_TESS_MAX_COORD = 1.0e150;
+
+ /* TessProperty */
+diff -Naur a7xpg/import/SDL.d a7xpg-gentoo/import/SDL.d
+--- a7xpg/import/SDL.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL.d 2007-09-19 22:11:32.000000000 +0200
+@@ -31,7 +31,7 @@
+ import SDL_events;
+ import SDL_video;
+ import SDL_byteorder;
+-import SDL_version;
++import SDL_Version;
+
+ extern(C):
+
+@@ -73,6 +73,7 @@
+ */
+ void SDL_Quit();
+
++/+
+ void SDL_SetModuleHandle(void *hInst);
+ extern(Windows) void* GetModuleHandle(char*);
+
+@@ -87,4 +88,5 @@
+ static ~this()
+ {
+ SDL_Quit();
+-}
+\ Kein Zeilenumbruch am Dateiende.
++}
+++/
+diff -Naur a7xpg/import/SDL_endian.d a7xpg-gentoo/import/SDL_endian.d
+--- a7xpg/import/SDL_endian.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_endian.d 2007-09-19 22:11:32.000000000 +0200
+@@ -57,9 +57,9 @@
+ Uint64 SDL_Swap64(Uint64 val) {
+ Uint32 hi, lo;
+ /* Separate into high and low 32-bit values and swap them */
+- lo = (Uint32)(val&0xFFFFFFFF);
++ lo = cast(Uint32)(val&0xFFFFFFFF);
+ val >>= 32;
+- hi = (Uint32)(val&0xFFFFFFFF);
++ hi = cast(Uint32)(val&0xFFFFFFFF);
+ val = SDL_Swap32(lo);
+ val <<= 32;
+ val |= SDL_Swap32(hi);
+diff -Naur a7xpg/import/SDL_events.d a7xpg-gentoo/import/SDL_events.d
+--- a7xpg/import/SDL_events.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_events.d 2007-09-19 22:11:32.000000000 +0200
+@@ -304,7 +304,7 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() will return the
+ current processing state of the specified event.
+ */
+-const uint SDL_QUERY = -1;
++const uint SDL_QUERY = cast(uint) -1;
+ const uint SDL_IGNORE = 0;
+ const uint SDL_DISABLE = 0;
+ const uint SDL_ENABLE = 1;
+diff -Naur a7xpg/import/SDL_getenv.d a7xpg-gentoo/import/SDL_getenv.d
+--- a7xpg/import/SDL_getenv.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_getenv.d 2007-09-19 22:11:32.000000000 +0200
+@@ -2,6 +2,7 @@
+
+ extern(C):
+
++/+
+ /* Put a variable of the form "name=value" into the environment */
+ int SDL_putenv(char *variable);
+ int putenv(char* X) { return SDL_putenv(X); }
+@@ -9,3 +10,4 @@
+ /* Retrieve a variable named "name" from the environment */
+ char *SDL_getenv(char *name);
+ char *getenv(char* X) { return SDL_getenv(X); }
+++/
+diff -Naur a7xpg/import/SDL_Keysym.d a7xpg-gentoo/import/SDL_Keysym.d
+--- a7xpg/import/SDL_Keysym.d 1970-01-01 01:00:00.000000000 +0100
++++ a7xpg-gentoo/import/SDL_Keysym.d 2007-09-19 22:11:32.000000000 +0200
+@@ -0,0 +1,308 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* What we really want is a mapping of every raw key on the keyboard.
++ To support international keyboards, we use the range 0xA1 - 0xFF
++ as international virtual keycodes. We'll follow in the footsteps of X11...
++ The names of the keys
++ */
++
++alias int SDLKey;
++enum {
++ /* The keyboard syms have been cleverly chosen to map to ASCII */
++ SDLK_UNKNOWN = 0,
++ SDLK_FIRST = 0,
++ SDLK_BACKSPACE = 8,
++ SDLK_TAB = 9,
++ SDLK_CLEAR = 12,
++ SDLK_RETURN = 13,
++ SDLK_PAUSE = 19,
++ SDLK_ESCAPE = 27,
++ SDLK_SPACE = 32,
++ SDLK_EXCLAIM = 33,
++ SDLK_QUOTEDBL = 34,
++ SDLK_HASH = 35,
++ SDLK_DOLLAR = 36,
++ SDLK_AMPERSAND = 38,
++ SDLK_QUOTE = 39,
++ SDLK_LEFTPAREN = 40,
++ SDLK_RIGHTPAREN = 41,
++ SDLK_ASTERISK = 42,
++ SDLK_PLUS = 43,
++ SDLK_COMMA = 44,
++ SDLK_MINUS = 45,
++ SDLK_PERIOD = 46,
++ SDLK_SLASH = 47,
++ SDLK_0 = 48,
++ SDLK_1 = 49,
++ SDLK_2 = 50,
++ SDLK_3 = 51,
++ SDLK_4 = 52,
++ SDLK_5 = 53,
++ SDLK_6 = 54,
++ SDLK_7 = 55,
++ SDLK_8 = 56,
++ SDLK_9 = 57,
++ SDLK_COLON = 58,
++ SDLK_SEMICOLON = 59,
++ SDLK_LESS = 60,
++ SDLK_EQUALS = 61,
++ SDLK_GREATER = 62,
++ SDLK_QUESTION = 63,
++ SDLK_AT = 64,
++ /*
++ Skip uppercase letters
++ */
++ SDLK_LEFTBRACKET = 91,
++ SDLK_BACKSLASH = 92,
++ SDLK_RIGHTBRACKET = 93,
++ SDLK_CARET = 94,
++ SDLK_UNDERSCORE = 95,
++ SDLK_BACKQUOTE = 96,
++ SDLK_a = 97,
++ SDLK_b = 98,
++ SDLK_c = 99,
++ SDLK_d = 100,
++ SDLK_e = 101,
++ SDLK_f = 102,
++ SDLK_g = 103,
++ SDLK_h = 104,
++ SDLK_i = 105,
++ SDLK_j = 106,
++ SDLK_k = 107,
++ SDLK_l = 108,
++ SDLK_m = 109,
++ SDLK_n = 110,
++ SDLK_o = 111,
++ SDLK_p = 112,
++ SDLK_q = 113,
++ SDLK_r = 114,
++ SDLK_s = 115,
++ SDLK_t = 116,
++ SDLK_u = 117,
++ SDLK_v = 118,
++ SDLK_w = 119,
++ SDLK_x = 120,
++ SDLK_y = 121,
++ SDLK_z = 122,
++ SDLK_DELETE = 127,
++ /* End of ASCII mapped keysyms */
++
++ /* International keyboard syms */
++ SDLK_WORLD_0 = 160, /* 0xA0 */
++ SDLK_WORLD_1 = 161,
++ SDLK_WORLD_2 = 162,
++ SDLK_WORLD_3 = 163,
++ SDLK_WORLD_4 = 164,
++ SDLK_WORLD_5 = 165,
++ SDLK_WORLD_6 = 166,
++ SDLK_WORLD_7 = 167,
++ SDLK_WORLD_8 = 168,
++ SDLK_WORLD_9 = 169,
++ SDLK_WORLD_10 = 170,
++ SDLK_WORLD_11 = 171,
++ SDLK_WORLD_12 = 172,
++ SDLK_WORLD_13 = 173,
++ SDLK_WORLD_14 = 174,
++ SDLK_WORLD_15 = 175,
++ SDLK_WORLD_16 = 176,
++ SDLK_WORLD_17 = 177,
++ SDLK_WORLD_18 = 178,
++ SDLK_WORLD_19 = 179,
++ SDLK_WORLD_20 = 180,
++ SDLK_WORLD_21 = 181,
++ SDLK_WORLD_22 = 182,
++ SDLK_WORLD_23 = 183,
++ SDLK_WORLD_24 = 184,
++ SDLK_WORLD_25 = 185,
++ SDLK_WORLD_26 = 186,
++ SDLK_WORLD_27 = 187,
++ SDLK_WORLD_28 = 188,
++ SDLK_WORLD_29 = 189,
++ SDLK_WORLD_30 = 190,
++ SDLK_WORLD_31 = 191,
++ SDLK_WORLD_32 = 192,
++ SDLK_WORLD_33 = 193,
++ SDLK_WORLD_34 = 194,
++ SDLK_WORLD_35 = 195,
++ SDLK_WORLD_36 = 196,
++ SDLK_WORLD_37 = 197,
++ SDLK_WORLD_38 = 198,
++ SDLK_WORLD_39 = 199,
++ SDLK_WORLD_40 = 200,
++ SDLK_WORLD_41 = 201,
++ SDLK_WORLD_42 = 202,
++ SDLK_WORLD_43 = 203,
++ SDLK_WORLD_44 = 204,
++ SDLK_WORLD_45 = 205,
++ SDLK_WORLD_46 = 206,
++ SDLK_WORLD_47 = 207,
++ SDLK_WORLD_48 = 208,
++ SDLK_WORLD_49 = 209,
++ SDLK_WORLD_50 = 210,
++ SDLK_WORLD_51 = 211,
++ SDLK_WORLD_52 = 212,
++ SDLK_WORLD_53 = 213,
++ SDLK_WORLD_54 = 214,
++ SDLK_WORLD_55 = 215,
++ SDLK_WORLD_56 = 216,
++ SDLK_WORLD_57 = 217,
++ SDLK_WORLD_58 = 218,
++ SDLK_WORLD_59 = 219,
++ SDLK_WORLD_60 = 220,
++ SDLK_WORLD_61 = 221,
++ SDLK_WORLD_62 = 222,
++ SDLK_WORLD_63 = 223,
++ SDLK_WORLD_64 = 224,
++ SDLK_WORLD_65 = 225,
++ SDLK_WORLD_66 = 226,
++ SDLK_WORLD_67 = 227,
++ SDLK_WORLD_68 = 228,
++ SDLK_WORLD_69 = 229,
++ SDLK_WORLD_70 = 230,
++ SDLK_WORLD_71 = 231,
++ SDLK_WORLD_72 = 232,
++ SDLK_WORLD_73 = 233,
++ SDLK_WORLD_74 = 234,
++ SDLK_WORLD_75 = 235,
++ SDLK_WORLD_76 = 236,
++ SDLK_WORLD_77 = 237,
++ SDLK_WORLD_78 = 238,
++ SDLK_WORLD_79 = 239,
++ SDLK_WORLD_80 = 240,
++ SDLK_WORLD_81 = 241,
++ SDLK_WORLD_82 = 242,
++ SDLK_WORLD_83 = 243,
++ SDLK_WORLD_84 = 244,
++ SDLK_WORLD_85 = 245,
++ SDLK_WORLD_86 = 246,
++ SDLK_WORLD_87 = 247,
++ SDLK_WORLD_88 = 248,
++ SDLK_WORLD_89 = 249,
++ SDLK_WORLD_90 = 250,
++ SDLK_WORLD_91 = 251,
++ SDLK_WORLD_92 = 252,
++ SDLK_WORLD_93 = 253,
++ SDLK_WORLD_94 = 254,
++ SDLK_WORLD_95 = 255, /* 0xFF */
++
++ /* Numeric keypad */
++ SDLK_KP0 = 256,
++ SDLK_KP1 = 257,
++ SDLK_KP2 = 258,
++ SDLK_KP3 = 259,
++ SDLK_KP4 = 260,
++ SDLK_KP5 = 261,
++ SDLK_KP6 = 262,
++ SDLK_KP7 = 263,
++ SDLK_KP8 = 264,
++ SDLK_KP9 = 265,
++ SDLK_KP_PERIOD = 266,
++ SDLK_KP_DIVIDE = 267,
++ SDLK_KP_MULTIPLY = 268,
++ SDLK_KP_MINUS = 269,
++ SDLK_KP_PLUS = 270,
++ SDLK_KP_ENTER = 271,
++ SDLK_KP_EQUALS = 272,
++
++ /* Arrows + Home/End pad */
++ SDLK_UP = 273,
++ SDLK_DOWN = 274,
++ SDLK_RIGHT = 275,
++ SDLK_LEFT = 276,
++ SDLK_INSERT = 277,
++ SDLK_HOME = 278,
++ SDLK_END = 279,
++ SDLK_PAGEUP = 280,
++ SDLK_PAGEDOWN = 281,
++
++ /* Function keys */
++ SDLK_F1 = 282,
++ SDLK_F2 = 283,
++ SDLK_F3 = 284,
++ SDLK_F4 = 285,
++ SDLK_F5 = 286,
++ SDLK_F6 = 287,
++ SDLK_F7 = 288,
++ SDLK_F8 = 289,
++ SDLK_F9 = 290,
++ SDLK_F10 = 291,
++ SDLK_F11 = 292,
++ SDLK_F12 = 293,
++ SDLK_F13 = 294,
++ SDLK_F14 = 295,
++ SDLK_F15 = 296,
++
++ /* Key state modifier keys */
++ SDLK_NUMLOCK = 300,
++ SDLK_CAPSLOCK = 301,
++ SDLK_SCROLLOCK = 302,
++ SDLK_RSHIFT = 303,
++ SDLK_LSHIFT = 304,
++ SDLK_RCTRL = 305,
++ SDLK_LCTRL = 306,
++ SDLK_RALT = 307,
++ SDLK_LALT = 308,
++ SDLK_RMETA = 309,
++ SDLK_LMETA = 310,
++ SDLK_LSUPER = 311, /* Left "Windows" key */
++ SDLK_RSUPER = 312, /* Right "Windows" key */
++ SDLK_MODE = 313, /* "Alt Gr" key */
++ SDLK_COMPOSE = 314, /* Multi-key compose key */
++
++ /* Miscellaneous function keys */
++ SDLK_HELP = 315,
++ SDLK_PRINT = 316,
++ SDLK_SYSREQ = 317,
++ SDLK_BREAK = 318,
++ SDLK_MENU = 319,
++ SDLK_POWER = 320, /* Power Macintosh power key */
++ SDLK_EURO = 321, /* Some european keyboards */
++ SDLK_UNDO = 322, /* Atari keyboard has Undo */
++
++ /* Add any other keys here */
++
++ SDLK_LAST
++}
++
++/* Enumeration of valid key mods (possibly OR'd together) */
++alias int SDLMod;
++enum {
++ KMOD_NONE = 0x0000,
++ KMOD_LSHIFT= 0x0001,
++ KMOD_RSHIFT= 0x0002,
++ KMOD_LCTRL = 0x0040,
++ KMOD_RCTRL = 0x0080,
++ KMOD_LALT = 0x0100,
++ KMOD_RALT = 0x0200,
++ KMOD_LMETA = 0x0400,
++ KMOD_RMETA = 0x0800,
++ KMOD_NUM = 0x1000,
++ KMOD_CAPS = 0x2000,
++ KMOD_MODE = 0x4000,
++ KMOD_RESERVED = 0x8000
++}
++
++const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
++const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
++const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
++const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur a7xpg/import/SDL_mixer.d a7xpg-gentoo/import/SDL_mixer.d
+--- a7xpg/import/SDL_mixer.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_mixer.d 2007-09-19 22:11:32.000000000 +0200
+@@ -22,9 +22,32 @@
+
+ // convert to D by shinichiro.h
+
+-/* $Id: SDL_mixer.d,v 1.1.1.1 2003/09/19 14:55:49 kenta Exp $ */
++/* $Id: SDL_mixer.d,v 1.1.1.1 2005/06/18 00:46:00 kenta Exp $ */
+
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+
+ extern (C) {
+
+diff -Naur a7xpg/import/SDL_mouse.d a7xpg-gentoo/import/SDL_mouse.d
+--- a7xpg/import/SDL_mouse.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_mouse.d 2007-09-19 22:11:32.000000000 +0200
+@@ -109,6 +109,8 @@
+ const uint SDL_BUTTON_LEFT = 1;
+ const uint SDL_BUTTON_MIDDLE = 2;
+ const uint SDL_BUTTON_RIGHT = 3;
++const uint SDL_BUTTON_WHEELUP = 4;
++const uint SDL_BUTTON_WHEELDOWN = 5;
+ const uint SDL_BUTTON_LMASK = SDL_PRESSED << (SDL_BUTTON_LEFT - 1);
+ const uint SDL_BUTTON_MMASK = SDL_PRESSED << (SDL_BUTTON_MIDDLE - 1);
+ const uint SDL_BUTTON_RMASK = SDL_PRESSED << (SDL_BUTTON_RIGHT - 1);
+diff -Naur a7xpg/import/SDL_quit.d a7xpg-gentoo/import/SDL_quit.d
+--- a7xpg/import/SDL_quit.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_quit.d 2007-09-19 22:11:32.000000000 +0200
+@@ -43,5 +43,5 @@
+ bit SDL_QuitRequested()
+ {
+ SDL_PumpEvents();
+- return SDL_PeepEvents(null, 0, SDL_PEEKEVENT, SDL_QUITMASK);
++ return cast(bit)SDL_PeepEvents(null, 0, SDL_PEEKEVENT, SDL_QUITMASK);
+ }
+diff -Naur a7xpg/import/SDL_rwops.d a7xpg-gentoo/import/SDL_rwops.d
+--- a7xpg/import/SDL_rwops.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_rwops.d 2007-09-19 22:11:32.000000000 +0200
+@@ -28,6 +28,11 @@
+
+ extern(C):
+
++typedef int (*_seek_func_t)(SDL_RWops *context, int offset, int whence);
++typedef int (*_read_func_t)(SDL_RWops *context, void *ptr, int size, int maxnum);
++typedef int (*_write_func_t)(SDL_RWops *context, void *ptr, int size, int num);
++typedef int (*_close_func_t)(SDL_RWops *context);
++
+ /* This is the read/write operation structure -- very basic */
+
+ struct SDL_RWops {
+@@ -35,22 +40,26 @@
+ SEEK_SET, SEEK_CUR, SEEK_END
+ Returns the final offset in the data source.
+ */
+- int (*seek)(SDL_RWops *context, int offset, int whence);
++ _seek_func_t seek;
++// int (*seek)(SDL_RWops *context, int offset, int whence);
+
+ /* Read up to 'num' objects each of size 'objsize' from the data
+ source to the area pointed at by 'ptr'.
+ Returns the number of objects read, or -1 if the read failed.
+ */
+- int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
++ _read_func_t read;
++// int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
+
+ /* Write exactly 'num' objects each of size 'objsize' from the area
+ pointed at by 'ptr' to data source.
+ Returns 'num', or -1 if the write failed.
+ */
+- int (*write)(SDL_RWops *context, void *ptr, int size, int num);
++ _write_func_t write;
++// int (*write)(SDL_RWops *context, void *ptr, int size, int num);
+
+ /* Close and free an allocated SDL_FSops structure */
+- int (*close)(SDL_RWops *context);
++ _close_func_t close;
++// int (*close)(SDL_RWops *context);
+
+ Uint32 type;
+ union {
+@@ -84,35 +93,40 @@
+ /* Macros to easily read and write from an SDL_RWops structure */
+ int SDL_RWseek(SDL_RWops *ctx, int offset, int whence)
+ {
+- int (*seek)(SDL_RWops *context, int offset, int whence);
++ _seek_func_t seek;
++// int (*seek)(SDL_RWops *context, int offset, int whence);
+ seek = ctx.seek;
+ return (*seek)(ctx, offset, whence);
+ }
+
+ int SDL_RWtell(SDL_RWops *ctx)
+ {
+- int (*seek)(SDL_RWops *context, int offset, int whence);
++ _seek_func_t seek;
++// int (*seek)(SDL_RWops *context, int offset, int whence);
+ seek = ctx.seek;
+ return (*seek)(ctx, 0, 1);
+ }
+
+ int SDL_RWread(SDL_RWops *ctx, void* ptr, int size, int n)
+ {
+- int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
++ _read_func_t read;
++// int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
+ read = ctx.read;
+ return (*read)(ctx, ptr, size, n);
+ }
+
+ int SDL_RWwrite(SDL_RWops *ctx, void* ptr, int size, int n)
+ {
+- int (*write)(SDL_RWops *context, void *ptr, int size, int num);
++ _write_func_t write;
++// int (*write)(SDL_RWops *context, void *ptr, int size, int num);
+ write = ctx.write;
+ return (*write)(ctx, ptr, size, n);
+ }
+
+ int SDL_RWclose(SDL_RWops *ctx)
+ {
+- int (*close)(SDL_RWops *context);
++ _close_func_t close;
++// int (*close)(SDL_RWops *context);
+ close = ctx.close;
+ return (*close)(ctx);
+ }
+diff -Naur a7xpg/import/SDL_syswm.d a7xpg-gentoo/import/SDL_syswm.d
+--- a7xpg/import/SDL_syswm.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/import/SDL_syswm.d 2007-09-19 22:11:32.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-import SDL_version;
++import SDL_Version;
+
+ extern(C):
+
+diff -Naur a7xpg/import/SDL_Version.d a7xpg-gentoo/import/SDL_Version.d
+--- a7xpg/import/SDL_Version.d 1970-01-01 01:00:00.000000000 +0100
++++ a7xpg-gentoo/import/SDL_Version.d 2007-09-19 22:11:32.000000000 +0200
+@@ -0,0 +1,75 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* This header defines the current SDL version */
++
++import SDL_types;
++
++extern(C):
++
++/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
++*/
++const uint SDL_MAJOR_VERSION = 1;
++const uint SDL_MINOR_VERSION = 2;
++const uint SDL_PATCHLEVEL = 6;
++
++struct SDL_version {
++ Uint8 major;
++ Uint8 minor;
++ Uint8 patch;
++}
++
++/* This macro can be used to fill a version structure with the compile-time
++ * version of the SDL library.
++ */
++void SDL_VERSION(SDL_version* X)
++{
++ X.major = SDL_MAJOR_VERSION;
++ X.minor = SDL_MINOR_VERSION;
++ X.patch = SDL_PATCHLEVEL;
++}
++
++/* This macro turns the version numbers into a numeric value:
++ (1,2,3) -> (1203)
++ This assumes that there will never be more than 100 patchlevels
++*/
++uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return X * 1000 + Y * 100 + Z;
++}
++
++/* This is the version number macro for the current SDL version */
++const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
++ SDL_MINOR_VERSION * 100 +
++ SDL_PATCHLEVEL;
++
++/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
++bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
++}
++
++/* This function gets the version of the dynamically linked SDL library.
++ it should NOT be used to fill a version structure, instead you should
++ use the SDL_Version() macro.
++ */
++SDL_version * SDL_Linked_Version();
+diff -Naur a7xpg/Makefile a7xpg-gentoo/Makefile
+--- a7xpg/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ a7xpg-gentoo/Makefile 2007-09-19 22:11:32.000000000 +0200
+@@ -0,0 +1,27 @@
++DSRC=$(shell find src -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++CFLAGS=
++DFLAGS=-O -release -Iimport -Isrc -I/usr/X11R6/include/
++EXE=a7xpg
++COBJS=src/dirent_d.o
++
++all: $(EXE)
++
++$(EXE): import/SDL_Keysym.d $(OBJS) $(COBJS)
++ gcc $(CFLAGS) -o $@ $(OBJS) $(COBJS) -L/usr/local/lib -L/usr/lib -lgphobos -lpthread -lGLU -lGL -lglut -lm -lstdc++ -lSDL -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ gdmd -d -c -of$@ $(DFLAGS) $<
++
++src/dirent_d.o: src/dirent_d.c
++ gcc -c $< -o $@
++
++import/SDL_Keysym.d:
++ mv import/SDL_keysym.d import/SDL_Keysym.d
++
++clean: rm src/*.o
++ rm src/abagames/a7xpg/*.o
++ rm src/abagames/util/*.o
++ rm src/abagames/util/sdl/*.o
++ rm -r import/*.o
+diff -Naur a7xpg/src/abagames/a7xpg/A7xBoot.d a7xpg-gentoo/src/abagames/a7xpg/A7xBoot.d
+--- a7xpg/src/abagames/a7xpg/A7xBoot.d 2003-09-21 13:01:26.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/A7xBoot.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,13 +5,15 @@
+ */
+ module abagames.a7xpg.A7xBoot;
+
+-import string;
++//import std.string;
++import std.c.stdlib;
+ import abagames.a7xpg.A7xScreen;
+ import abagames.a7xpg.A7xGameManager;
+ import abagames.a7xpg.A7xPrefManager;
+ import abagames.util.Logger;
+-import abagames.util.sdl.Input;
+-import abagames.util.sdl.MainLoop;
++import abagames.util.sdl.Input;
++import abagames.util.sdl.Sound;
++import abagames.util.sdl.MainLoop;
+
+ /**
+ * Boot A7Xpg.
+@@ -28,9 +30,9 @@
+ ("Usage: a7xpg [-brightness [0-100]] [-luminous [0-100]] [-nosound] [-window] [-lowres]");
+ }
+
+-private void parseArgs(char[][] args) {
+- //for (int i = 1; i < argv.length; i++) {
+- for (int i = 0; i < args.length; i++) {
++public void parseArgs(char[][] args) {
++ for (int i = 1; i < args.length; i++) {
++ //for (int i = 0; i < args.length; i++) {
+ switch (args[i]) {
+ case "-brightness":
+ if (i >= args.length - 1) {
+@@ -38,7 +40,7 @@
+ exit(EXIT_FAILURE);
+ }
+ i++;
+- float b = (float) atoi(args[i]) / 100;
++ float b = cast(float) atoi(args[i]) / 100;
+ if (b < 0 || b > 1) {
+ usage();
+ exit(EXIT_FAILURE);
+@@ -51,7 +53,7 @@
+ exit(EXIT_FAILURE);
+ }
+ i++;
+- float l = (float) atoi(args[i]) / 100;
++ float l = cast(float) atoi(args[i]) / 100;
+ if (l < 0 || l > 1) {
+ usage();
+ exit(EXIT_FAILURE);
+@@ -77,9 +79,10 @@
+ }
+ }
+
+-//public int main(char[][] argc) {
+-private int boot(char[] argl) {
+- char[][] args = split(argl);
++public int main(char[][] argl) {
++//private int boot(char[] argl) {
++
++ char[][] args = argl;
+ screen = new A7xScreen;
+ input = new Input;
+ try {
+@@ -90,24 +93,24 @@
+ mainLoop = new MainLoop(screen, input, gameManager, prefManager);
+ parseArgs(args);
+ mainLoop.loop();
+- return EXIT_SUCCESS;
++ return EXIT_SUCCESS;
+ }
+
+ // Boot as the windows executable.
+-import windows;
++//import windows;
+
+-extern (C) void gc_init();
+-extern (C) void gc_term();
+-extern (C) void _minit();
+-extern (C) void _moduleCtor();
++//extern (C) void gc_init();
++//extern (C) void gc_term();
++//extern (C) void _minit();
++//extern (C) void _moduleCtor();
+
+-extern (Windows)
++/* extern (Windows)
+ int WinMain(HINSTANCE hInstance,
+ HINSTANCE hPrevInstance,
+ LPSTR lpCmdLine,
+ int nCmdShow) {
+ int result;
+-
++
+ gc_init();
+ _minit();
+ try {
+@@ -121,3 +124,4 @@
+ gc_term();
+ return result;
+ }
++*/
+diff -Naur a7xpg/src/abagames/a7xpg/A7xGameManager.d a7xpg-gentoo/src/abagames/a7xpg/A7xGameManager.d
+--- a7xpg/src/abagames/a7xpg/A7xGameManager.d 2003-09-20 00:56:12.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/A7xGameManager.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,10 +5,34 @@
+ */
+ module abagames.a7xpg.A7xGameManager;
+
+-import math;
++import std.math;
+ import opengl;
+-import SDL;
+-import abagames.util.Rand;
++import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
++import abagames.util.Rand;
++import abagames.util.Vector;
+ import abagames.util.GameManager;
+ import abagames.util.ActorPool;
+ import abagames.util.sdl.Screen3D;
+@@ -68,7 +92,7 @@
+ Texture titleTexture;
+
+ const int STAGE_NUM = 30;
+- float[][STAGE_NUM] stgData =
++ float[][STAGE_NUM] stgData =
+ [
+ // width, height, time, #gold, #gold on field, interval enemy appearing, [enemy data]
+ // [enemy data] = #, type, size, speed
+@@ -104,19 +128,19 @@
+
+ [24, 18, 50, 20, 2, 75, 1, 0, 1, 0.4, 1, 0, 1.25, 0.35, 1, 0, 1.5, 0.3, 1, 0, 1.75, 0.25,
+ 1, 0, 2, 0.2, 1, 0, 2.25, 0.15, 1, 0, 2.5, 0.1],
+- [29, 25, 60, 25, 3, 100, 1, 4, 15, 0.25, 1, 4, 10, 0.3,
++ [29, 25, 60, 25, 3, 100, 1, 4, 15, 0.25, 1, 4, 10, 0.3,
+ 1, 3, 2, 0.35, 1, 5, 1.5, 0.35, 1, 1, 2, 0.35, 4, 0, 1, 0.3],
+ [20, 24, 40, 15, 1, 120, 7, 4, 2, 0.6],
+ [22, 22, 60, 30, 5, 100, 4, 4, 8, 0.3, 4, 3, 2, 0.4],
+- [24, 18, 40, 10, 1, 20, 4, 0, 1, 0.2, 3, 1, 1, 0.25, 2, 2, 1, 0.3, 1, 3, 1, 0.3,
++ [24, 18, 40, 10, 1, 20, 4, 0, 1, 0.2, 3, 1, 1, 0.25, 2, 2, 1, 0.3, 1, 3, 1, 0.3,
+ 1, 4, 3, 0.3, 1, 5, 1, 0.2],
+ ];
+ float[3][ENEMY_MAX] enemyTable;
+ int enemyTableIdx, enemyNum;
+
+ public override void init() {
+- prefManager = (A7xPrefManager) abstPrefManager;
+- screen = (A7xScreen) abstScreen;
++ prefManager = cast(A7xPrefManager) abstPrefManager;
++ screen = cast(A7xScreen) abstScreen;
+ screen.makeLuminousTexture();
+ rand = new Rand;
+ field = new Field;
+@@ -189,7 +213,7 @@
+ }
+
+ public void addGold() {
+- Gold gold = (Gold) golds.getInstance();
++ Gold gold = cast(Gold) golds.getInstance();
+ assert(gold);
+ gold.set();
+ }
+@@ -210,14 +234,14 @@
+
+ public void addBonus(int sc, Vector pos, float size) {
+ addScore(sc);
+- Bonus bonus = (Bonus) bonuses.getInstanceForced();
++ Bonus bonus = cast(Bonus) bonuses.getInstanceForced();
+ assert(bonus);
+ bonus.set(sc, pos, size);
+ }
+
+ public void getGold() {
+ playSe(0);
+- addBonus(((int)(ship.speed / (ship.DEFAULT_SPEED / 2))) * 10, ship.pos, 0.7);
++ addBonus((cast(int)(ship.speed / (ship.DEFAULT_SPEED / 2))) * 10, ship.pos, 0.7);
+ leftGold--;
+ if (leftGold - appGold >= 0)
+ addGold();
+@@ -235,14 +259,14 @@
+
+ public void addEnemy(int type, float size, float speed) {
+ playSe(5);
+- Enemy enemy = (Enemy) enemies.getInstance();
++ Enemy enemy = cast(Enemy) enemies.getInstance();
+ if (!enemy) return;
+ enemy.set(type, size, speed);
+ }
+
+ public void addParticle(Vector pos, float deg, float ofs, float speed,
+ float r, float g, float b) {
+- Particle pt = (Particle) particles.getInstanceForced();
++ Particle pt = cast(Particle) particles.getInstanceForced();
+ assert(pt);
+ pt.set(pos, deg, ofs, speed, r, g, b);
+ }
+@@ -254,16 +278,16 @@
+ field.size.y = stgData[st][1];
+ field.eyeZ = 300;
+ field.alpha = 1;
+- stageTimer = stgData[st][2] * 60;
+- leftGold = stgData[st][3];
+- appGold = stgData[st][4];
+- enemyAppInterval = stgData[st][5];
++ stageTimer = cast(int)(stgData[st][2] * 60);
++ leftGold = cast(int)(stgData[st][3]);
++ appGold = cast(int)(stgData[st][4]);
++ enemyAppInterval = cast(int)(stgData[st][5]);
+ int ei = 0;
+ for (int i = 6; i < stgData[st].length;) {
+- int n = stgData[st][i]; i++;
+- int tp = stgData[st][i]; i++;
+- float sz = stgData[st][i]; i++;
+- float sp = stgData[st][i]; i++;
++ int n = cast(int)(stgData[st][i]); i++;
++ int tp = cast(int)(stgData[st][i]); i++;
++ float sz = stgData[st][i]; i++;
++ float sp = stgData[st][i]; i++;
+ for (int j = 0; j < n; j++) {
+ enemyTable[ei][0] = tp;
+ enemyTable[ei][1] = sz;
+@@ -374,7 +398,7 @@
+ if (enemyTableIdx == 0 && lap >= 1) {
+ int ei = enemyNum - 1;
+ for (int i = 0; i < lap * 2; i++) {
+- addEnemy(enemyTable[ei][0],
++ addEnemy(cast(int)enemyTable[ei][0],
+ enemyTable[ei][1] * (1 + lap * 0.1),
+ enemyTable[ei][2] * (1 + lap * 0.1));
+ ei--;
+@@ -383,7 +407,7 @@
+ }
+ }
+ enemyTimer = enemyAppInterval;
+- addEnemy(enemyTable[enemyTableIdx][0],
++ addEnemy(cast(int)enemyTable[enemyTableIdx][0],
+ enemyTable[enemyTableIdx][1],
+ enemyTable[enemyTableIdx][2]);
+ enemyTableIdx++;
+@@ -500,7 +524,7 @@
+ startTitle();
+ } else if (cnt > 500) {
+ startTitle();
+- }
++ }
+ field.addSpeed(ship.DEFAULT_SPEED / 2);
+ field.move();
+ enemies.move();
+diff -Naur a7xpg/src/abagames/a7xpg/A7xPrefManager.d a7xpg-gentoo/src/abagames/a7xpg/A7xPrefManager.d
+--- a7xpg/src/abagames/a7xpg/A7xPrefManager.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/A7xPrefManager.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.a7xpg.A7xPrefManager;
+
+-import stream;
++import std.stream;
+ import abagames.util.PrefManager;
+
+ /**
+@@ -25,6 +25,10 @@
+ auto File fd = new File;
+ try {
+ int ver;
++// if (exists(PREF_FILE) == 0){
++ // init();
++ // save();
++ //}
+ fd.open(PREF_FILE);
+ fd.read(ver);
+ if (ver != VERSION_NUM)
+diff -Naur a7xpg/src/abagames/a7xpg/A7xScreen.d a7xpg-gentoo/src/abagames/a7xpg/A7xScreen.d
+--- a7xpg/src/abagames/a7xpg/A7xScreen.d 2003-09-21 13:01:28.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/A7xScreen.d 2007-09-19 22:11:32.000000000 +0200
+@@ -40,13 +40,13 @@
+ GLuint luminousTexture;
+ const int LUMINOUS_TEXTURE_WIDTH_MAX = 128;
+ const int LUMINOUS_TEXTURE_HEIGHT_MAX = 128;
+- GLuint td[LUMINOUS_TEXTURE_WIDTH_MAX * LUMINOUS_TEXTURE_HEIGHT_MAX * 4 * uint.size];
++ GLuint td[LUMINOUS_TEXTURE_WIDTH_MAX * LUMINOUS_TEXTURE_HEIGHT_MAX * 4 * uint.sizeof];
+ int luminousTextureWidth = 128, luminousTextureHeight = 128;
+
+ public void makeLuminousTexture() {
+ uint *data = td;
+ int i;
+- memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.size);
++ // memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
+ glGenTextures(1, &luminousTexture);
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 4, luminousTextureWidth, luminousTextureHeight, 0,
+diff -Naur a7xpg/src/abagames/a7xpg/Bonus.d a7xpg-gentoo/src/abagames/a7xpg/Bonus.d
+--- a7xpg/src/abagames/a7xpg/Bonus.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/Bonus.d 2007-09-19 22:11:32.000000000 +0200
+@@ -24,7 +24,7 @@
+ public override Actor newActor() {
+ return new Bonus;
+ }
+-
++
+ public override void init(ActorInitializer ini) {
+ pos = new Vector;
+ }
+@@ -36,7 +36,7 @@
+ tn /= 10;
+ pos.x = p.x - s / 2 * tn; pos.y = p.y;
+ size = s;
+- cnt = 32 + s * 24;
++ cnt = cast(int)(32 + s * 24);
+ my = 0.03 + s * 0.2;
+ isExist = true;
+ }
+diff -Naur a7xpg/src/abagames/a7xpg/Enemy.d a7xpg-gentoo/src/abagames/a7xpg/Enemy.d
+--- a7xpg/src/abagames/a7xpg/Enemy.d 2003-09-21 13:01:28.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/Enemy.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,13 +5,15 @@
+ */
+ module abagames.a7xpg.Enemy;
+
+-import math;
++import std.math;
+ import opengl;
+ import abagames.util.Vector;
+ import abagames.util.Rand;
+-import abagames.util.ActorInitializer;
++import abagames.util.ActorInitializer;
++import abagames.util.Actor;
+ import abagames.a7xpg.LuminousActor;
+-import abagames.a7xpg.Ship;
++import abagames.a7xpg.Ship;
++import abagames.a7xpg.Field;
+ import abagames.a7xpg.A7xGameManager;
+ import abagames.a7xpg.A7xScreen;
+
+@@ -48,7 +50,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- EnemyInitializer ei = (EnemyInitializer) ini;
++ EnemyInitializer ei = cast(EnemyInitializer) ini;
+ ship = ei.ship;
+ field = ei.field;
+ rand = ei.rand;
+@@ -89,32 +91,32 @@
+ isExist = true;
+ switch (type) {
+ case 0:
+- deg = math.PI / 2 * rand.nextInt(4);
++ deg = PI / 2 * rand.nextInt(4);
+ break;
+ case 1:
+- deg = math.PI / 4 * rand.nextInt(8);
++ deg = PI / 4 * rand.nextInt(8);
+ break;
+ case 2:
+ chaseType = 0;
+- deg = math.PI / 2 * rand.nextInt(4);
++ deg = PI / 2 * rand.nextInt(4);
+ break;
+ case 3:
+ vel.x = vel.y = 0;
+- deg = rand.nextFloat(math.PI * 2);
++ deg = rand.nextFloat(PI * 2);
+ break;
+ case 4:
+- deg = rand.nextFloat(math.PI * 2);
++ deg = rand.nextFloat(PI * 2);
+ vel.x = sin(deg) * speed;
+ vel.y = cos(deg) * speed;
+- armDeg = rand.nextFloat(math.PI * 2);
+- if (rand.nextInt(2) == 0)
++ armDeg = rand.nextFloat(PI * 2);
++ if (rand.nextInt(2) == 0)
+ armDegMv = rand.nextFloat(0.01) + 0.02;
+ else
+ armDegMv = -rand.nextFloat(0.01) - 0.02;
+ break;
+ case 5:
+ posHstIdx = POSITION_HISTORY_LENGTH;
+- deg = math.PI / 2 * rand.nextInt(4);
++ deg = PI / 2 * rand.nextInt(4);
+ for (int i = 0; i < POSITION_HISTORY_LENGTH; i++) {
+ posHst[i].x = pos.x;
+ posHst[i].y = pos.y;
+@@ -126,7 +128,7 @@
+ }
+ }
+
+- private float[][] enemyColor =
++ private float[][] enemyColor =
+ [
+ [0.9, 0.2, 0.2],
+ [0.7, 0.3, 0.6],
+@@ -140,7 +142,7 @@
+ if (ship.invincible) {
+ manager.playSe(6);
+ for (int i = 0; i < 60; i++) {
+- manager.addParticle(pos, rand.nextFloat(math.PI * 2), size, rand.nextFloat(0.5),
++ manager.addParticle(pos, rand.nextFloat(PI * 2), size, rand.nextFloat(0.5),
+ enemyColor[type][0], enemyColor[type][1], enemyColor[type][2]);
+ }
+ ship.destroyEnemy();
+@@ -148,7 +150,7 @@
+ cnt = -DESTROYED_CNT;
+ } else if (!ship.restart) {
+ for (int i = 0; i < 100; i++) {
+- manager.addParticle(pos, rand.nextFloat(math.PI * 2), size, rand.nextFloat(1),
++ manager.addParticle(pos, rand.nextFloat(PI * 2), size, rand.nextFloat(1),
+ 0.3, 1, 0.2);
+ }
+ ship.miss();
+@@ -160,16 +162,16 @@
+ turnDist -= speed;
+ if (hitWall) {
+ turnDist = (rand.nextInt(60) + 60) * 0.2;
+- if (deg < math.PI / 4 * 1 || (deg > math.PI / 4 * 3 && deg < math.PI / 4 * 5)) {
++ if (deg < PI / 4 * 1 || (deg > PI / 4 * 3 && deg < PI / 4 * 5)) {
+ if (ship.pos.x < pos.x)
+- deg = math.PI / 4 * 6;
+- else
+- deg = math.PI / 4 * 2;
++ deg = PI / 4 * 6;
++ else
++ deg = PI / 4 * 2;
+ } else {
+ if (ship.pos.y < pos.y)
+- deg = math.PI / 4 * 4;
+- else
+- deg = math.PI / 4 * 0;
++ deg = PI / 4 * 4;
++ else
++ deg = PI / 4 * 0;
+ }
+ }
+ if (cnt < APPEAR_CNT)
+@@ -177,21 +179,21 @@
+ if (turnDist <= 0) {
+ turnDist = (rand.nextInt(90) + 60) * 0.2;
+ float od = atan2(ship.pos.x - pos.x, ship.pos.y - pos.y);
+- if (od < -math.PI / 4 * 3)
+- deg = math.PI / 4 * 4;
+- else if (od < -math.PI / 4 * 1)
+- deg = math.PI / 4 * 6;
+- else if (od < math.PI / 4 * 1)
+- deg = math.PI / 4 * 0;
+- else
+- deg = math.PI / 4 * 2;
++ if (od < -PI / 4 * 3)
++ deg = PI / 4 * 4;
++ else if (od < -PI / 4 * 1)
++ deg = PI / 4 * 6;
++ else if (od < PI / 4 * 1)
++ deg = PI / 4 * 0;
++ else
++ deg = PI / 4 * 2;
+ }
+ if (rand.nextInt(9) == 0) {
+- manager.addParticle(pos, deg + math.PI + math.PI / 7 + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, deg + PI + PI / 7 + rand.nextFloat(0.2) - 0.1,
+ size, speed * 2, 0.9, 0.3, 0.3);
+ }
+ if (rand.nextInt(9) == 0) {
+- manager.addParticle(pos, deg + math.PI - math.PI / 7 + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, deg + PI - PI / 7 + rand.nextFloat(0.2) - 0.1,
+ size, speed * 2, 0.9, 0.3, 0.3);
+ }
+ if (ship.checkHit(pos.x, pos.y - size * 0.8, pos.x, pos.y + size * 0.8) ||
+@@ -203,9 +205,9 @@
+ private void moveType1() {
+ turnDist -= speed;
+ if (hitWall) {
+- deg += math.PI;
+- if (deg >= math.PI * 2)
+- deg -= math.PI * 2;
++ deg += PI;
++ if (deg >= PI * 2)
++ deg -= PI * 2;
+ }
+ if (cnt < APPEAR_CNT)
+ return;
+@@ -213,22 +215,22 @@
+ turnDist = (rand.nextInt(40) + 8) * 0.2;
+ float od = atan2(ship.pos.x - pos.x, ship.pos.y - pos.y);
+ if (od < 0)
+- od += math.PI * 2;
++ od += PI * 2;
+ od -= deg;
+- if (od > -math.PI / 8 && od < math.PI / 8) {
+- } else if (od < -math.PI / 8 * 15 || od > math.PI / 8 * 15) {
+- } else if ((od > -math.PI && od < 0) || od > math.PI) {
+- deg -= math.PI / 4;
++ if (od > -PI / 8 && od < PI / 8) {
++ } else if (od < -PI / 8 * 15 || od > PI / 8 * 15) {
++ } else if ((od > -PI && od < 0) || od > PI) {
++ deg -= PI / 4;
+ if (deg < 0)
+- deg += math.PI * 2;
++ deg += PI * 2;
+ } else {
+- deg += math.PI / 4;
+- if (deg >= math.PI * 2)
+- deg -= math.PI * 2;
++ deg += PI / 4;
++ if (deg >= PI * 2)
++ deg -= PI * 2;
+ }
+ }
+ if (rand.nextInt(4) == 0) {
+- manager.addParticle(pos, deg + math.PI + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, deg + PI + rand.nextFloat(0.2) - 0.1,
+ size, speed * 2.5, 0.8, 0.4, 0.5);
+ }
+ if (ship.checkHit(pos.x, pos.y - size * 0.8, pos.x, pos.y + size * 0.8) ||
+@@ -241,15 +243,15 @@
+ if (hitWall) {
+ if ((hitWallType & 1) == 1) {
+ float od = atan2(ship.pos.x - pos.x, ship.pos.y - pos.y);
+- if (od > -math.PI / 2 && od <= math.PI / 2) {
++ if (od > -PI / 2 && od <= PI / 2) {
+ if (chaseType > 0)
+ deg = 0;
+ else
+- deg = math.PI / 2 * 2;
++ deg = PI / 2 * 2;
+ chaseType++;
+ } else {
+ if (chaseType > 0)
+- deg = math.PI / 2 * 2;
++ deg = PI / 2 * 2;
+ else
+ deg = 0;
+ chaseType++;
+@@ -259,15 +261,15 @@
+ float od = atan2(ship.pos.x - pos.x, ship.pos.y - pos.y);
+ if (od < 0) {
+ if (chaseType > 0)
+- deg = math.PI / 2 * 3;
++ deg = PI / 2 * 3;
+ else
+- deg = math.PI / 2;
++ deg = PI / 2;
+ chaseType++;
+ } else {
+ if (chaseType > 0)
+- deg = math.PI / 2;
++ deg = PI / 2;
+ else
+- deg = math.PI / 2 * 3;
++ deg = PI / 2 * 3;
+ chaseType++;
+ }
+ }
+@@ -275,31 +277,31 @@
+ if (deg < 0.1) {
+ if (ship.pos.y <= pos.y) {
+ if (ship.pos.x < pos.x)
+- deg = math.PI / 2 * 3;
++ deg = PI / 2 * 3;
+ else
+- deg = math.PI / 2;
++ deg = PI / 2;
+ chaseType = 0;
+ }
+- } else if (deg > math.PI / 2 - 0.1 && deg < math.PI / 2 + 0.1) {
++ } else if (deg > PI / 2 - 0.1 && deg < PI / 2 + 0.1) {
+ if (ship.pos.x <= pos.x) {
+ if (ship.pos.y < pos.y)
+- deg = math.PI / 2 * 2;
++ deg = PI / 2 * 2;
+ else
+ deg = 0;
+ chaseType = 0;
+ }
+- } else if (deg > math.PI / 2 * 2 - 0.1 && deg < math.PI / 2 * 2 + 0.1) {
++ } else if (deg > PI / 2 * 2 - 0.1 && deg < PI / 2 * 2 + 0.1) {
+ if (ship.pos.y >= pos.y) {
+ if (ship.pos.x < pos.x)
+- deg = math.PI / 2 * 3;
++ deg = PI / 2 * 3;
+ else
+- deg = math.PI / 2;
++ deg = PI / 2;
+ chaseType = 0;
+ }
+- } else if (deg > math.PI / 2 * 3 - 0.1 && deg < math.PI / 2 * 3 + 0.1) {
++ } else if (deg > PI / 2 * 3 - 0.1 && deg < PI / 2 * 3 + 0.1) {
+ if (ship.pos.x >= pos.x) {
+ if (ship.pos.y < pos.y)
+- deg = math.PI / 2 * 2;
++ deg = PI / 2 * 2;
+ else
+ deg = 0;
+ chaseType = 0;
+@@ -309,11 +311,11 @@
+ if (cnt < APPEAR_CNT)
+ return;
+ if (rand.nextInt(9) == 0) {
+- manager.addParticle(pos, deg + math.PI + math.PI / 12 + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, deg + PI + PI / 12 + rand.nextFloat(0.2) - 0.1,
+ size, speed * 2, 0.3, 0.9, 0.3);
+ }
+ if (rand.nextInt(9) == 0) {
+- manager.addParticle(pos, deg + math.PI - math.PI / 12 + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, deg + PI - PI / 12 + rand.nextFloat(0.2) - 0.1,
+ size, speed * 2, 0.3, 0.9, 0.3);
+ }
+ if (ship.checkHit(pos.x, pos.y - size * 0.8, pos.x, pos.y + size * 0.8) ||
+@@ -347,7 +349,7 @@
+ if (cnt < APPEAR_CNT)
+ return;
+ if (rand.nextInt(4) == 0) {
+- manager.addParticle(pos, rand.nextFloat(math.PI * 2),
++ manager.addParticle(pos, rand.nextFloat(PI * 2),
+ size, speed, 0.9, 0.3, 0.6);
+ }
+ if (ship.checkHit(pos.x, pos.y - size * 0.8, pos.x, pos.y + size * 0.8) ||
+@@ -381,11 +383,11 @@
+ if (cnt < APPEAR_CNT)
+ return;
+ if (rand.nextInt(7) == 0) {
+- manager.addParticle(pos, armDeg + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, armDeg + rand.nextFloat(0.2) - 0.1,
+ 1, speed * 2, 0.5, 0.9, 0.3);
+ }
+ if (rand.nextInt(7) == 0) {
+- manager.addParticle(pos, armDeg + math.PI + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, armDeg + PI + rand.nextFloat(0.2) - 0.1,
+ 1, speed * 2, 0.5, 0.9, 0.3);
+ }
+ float ax = size * sin(armDeg) * 0.9;
+@@ -398,32 +400,32 @@
+ private void moveType5() {
+ turnDist -= speed;
+ if (hitWall) {
+- deg += math.PI;
+- if (deg >= math.PI * 2)
+- deg -= math.PI * 2;
+- }
++ deg += PI;
++ if (deg >= PI * 2)
++ deg -= PI * 2;
++ }
+ if (cnt < APPEAR_CNT)
+ return;
+ if (!hitWall && turnDist <= 0) {
+ turnDist = (rand.nextInt(24) + 16) * 0.2;
+ float od = atan2(ship.pos.x - pos.x, ship.pos.y - pos.y);
+ if (od < 0)
+- od += math.PI * 2;
++ od += PI * 2;
+ od -= deg;
+- if (od > -math.PI / 8 && od < math.PI / 8) {
+- } else if (od < -math.PI / 8 * 15 || od > math.PI / 8 * 15) {
+- } else if ((od > -math.PI && od < 0) || od > math.PI) {
+- deg -= math.PI / 2;
++ if (od > -PI / 8 && od < PI / 8) {
++ } else if (od < -PI / 8 * 15 || od > PI / 8 * 15) {
++ } else if ((od > -PI && od < 0) || od > PI) {
++ deg -= PI / 2;
+ if (deg < 0)
+- deg += math.PI * 2;
++ deg += PI * 2;
+ } else {
+- deg += math.PI / 2;
+- if (deg >= math.PI * 2)
+- deg -= math.PI * 2;
++ deg += PI / 2;
++ if (deg >= PI * 2)
++ deg -= PI * 2;
+ }
+ }
+ if (rand.nextInt(4) == 0) {
+- manager.addParticle(pos, deg + math.PI + rand.nextFloat(0.2) - 0.1,
++ manager.addParticle(pos, deg + PI + rand.nextFloat(0.2) - 0.1,
+ 0, speed * 5, 0.5, 0.3, 0.9);
+ }
+ int hi = posHstIdx;
+@@ -485,7 +487,7 @@
+ if (type < 4) {
+ blowedVel.mul(-0.7);
+ }
+- if (type != 4) {
++ if (type != 4) {
+ pos.x = ppos.x; pos.y = ppos.y;
+ }
+ }
+@@ -524,7 +526,7 @@
+ sz = size;
+ glPushMatrix();
+ glTranslatef(pos.x, pos.y, 0.5);
+- glRotatef(-deg * 180 / math.PI, 0, 0, 1);
++ glRotatef(-deg * 180 / PI, 0, 0, 1);
+ glScalef(sz, sz, sz);
+ glCallList(displayListIdx + type * 3);
+ glCallList(displayListIdx + type * 3 + 1);
+@@ -557,7 +559,7 @@
+ sz = size;
+ glPushMatrix();
+ glTranslatef(pos.x, pos.y, 0.5);
+- glRotatef(-armDeg * 180 / math.PI, 0, 0, 1);
++ glRotatef(-armDeg * 180 / PI, 0, 0, 1);
+ glBegin(GL_TRIANGLE_FAN);
+ A7xScreen.setColor(0.7, 0.9, 0.3, 0.3);
+ glVertex3f(0, 0, 0.5);
+@@ -593,7 +595,7 @@
+ for (int i = 0; i < 5; i++) {
+ glPushMatrix();
+ glTranslatef(posHst[hi].x, posHst[hi].y, 0.5);
+- glRotatef(-degHst[hi] * 180 / math.PI, 0, 0, 1);
++ glRotatef(-degHst[hi] * 180 / PI, 0, 0, 1);
+ glScalef(sz, sz, sz);
+ glCallList(displayListIdx + 5 * 3);
+ glCallList(displayListIdx + 5 * 3 + 1);
+@@ -625,7 +627,7 @@
+ private void drawType0Luminous() {
+ glPushMatrix();
+ glTranslatef(pos.x, pos.y, 0.5);
+- glRotatef(-deg * 180 / math.PI, 0, 0, 1);
++ glRotatef(-deg * 180 / PI, 0, 0, 1);
+ glScalef(size, size, size);
+ glCallList(displayListIdx + type * 3 + 1);
+ glPopMatrix();
+@@ -641,7 +643,7 @@
+ private void drawArmLuminous() {
+ glPushMatrix();
+ glTranslatef(pos.x, pos.y, 0.5);
+- glRotatef(-armDeg * 180 / math.PI, 0, 0, 1);
++ glRotatef(-armDeg * 180 / PI, 0, 0, 1);
+ glBegin(GL_LINE_STRIP);
+ A7xScreen.setColor(0.5, 0.9, 0.3, 0.9);
+ glVertex3f(-0.5, 0, 0.5);
+diff -Naur a7xpg/src/abagames/a7xpg/Gold.d a7xpg-gentoo/src/abagames/a7xpg/Gold.d
+--- a7xpg/src/abagames/a7xpg/Gold.d 2003-09-21 13:01:28.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/Gold.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,11 +5,12 @@
+ */
+ module abagames.a7xpg.Gold;
+
+-import math;
++import std.math;
+ import opengl;
+ import abagames.util.Vector;
+ import abagames.util.Rand;
+ import abagames.util.ActorInitializer;
++import abagames.util.Actor;
+ import abagames.a7xpg.LuminousActor;
+ import abagames.a7xpg.Ship;
+ import abagames.a7xpg.Field;
+@@ -37,14 +38,14 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- GoldInitializer gi = (GoldInitializer) ini;
++ GoldInitializer gi = cast(GoldInitializer) ini;
+ ship = gi.ship;
+ field = gi.field;
+ rand = gi.rand;
+ manager = gi.manager;
+ pos = new Vector;
+ }
+-
++
+ public void set() {
+ for (int i = 0; i < 8 ; i++) {
+ pos.x = rand.nextFloat((field.size.x - SIZE) * 2) - field.size.x + SIZE;
+@@ -66,7 +67,7 @@
+ ship.checkHit(pos.x - SIZE, pos.y, pos.x + SIZE, pos.y)) {
+ isExist = false;
+ for (int i = 0; i < 16; i++) {
+- manager.addParticle(pos, rand.nextFloat(math.PI * 2), 0.5, 0,5, 0.8, 0);
++ manager.addParticle(pos, rand.nextFloat(PI * 2), 0.5, 0,5, 0.8, 0);
+ }
+ manager.getGold();
+ }
+diff -Naur a7xpg/src/abagames/a7xpg/LetterRender.d a7xpg-gentoo/src/abagames/a7xpg/LetterRender.d
+--- a7xpg/src/abagames/a7xpg/LetterRender.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/LetterRender.d 2007-09-19 22:11:32.000000000 +0200
+@@ -123,7 +123,7 @@
+ float x, y, length, size, t;
+ int deg;
+ for ( i=0 ; ; i++ ) {
+- deg = (int) spData[idx][i][4];
++ deg = cast(int) spData[idx][i][4];
+ if (deg > 99990) break;
+ x = -spData[idx][i][0];
+ y = -spData[idx][i][1];
+diff -Naur a7xpg/src/abagames/a7xpg/LuminousActorPool.d a7xpg-gentoo/src/abagames/a7xpg/LuminousActorPool.d
+--- a7xpg/src/abagames/a7xpg/LuminousActorPool.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/LuminousActorPool.d 2007-09-19 22:11:32.000000000 +0200
+@@ -21,7 +21,7 @@
+ public void drawLuminous() {
+ for (int i = 0; i < actor.length; i++) {
+ if (actor[i].isExist)
+- ((LuminousActor) actor[i]).drawLuminous();
++ (cast(LuminousActor) actor[i]).drawLuminous();
+ }
+ }
+ }
+diff -Naur a7xpg/src/abagames/a7xpg/Particle.d a7xpg-gentoo/src/abagames/a7xpg/Particle.d
+--- a7xpg/src/abagames/a7xpg/Particle.d 2003-09-21 13:01:28.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/Particle.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,9 +5,10 @@
+ */
+ module abagames.a7xpg.Particle;
+
+-import math;
++import std.math;
+ import opengl;
+-import abagames.util.Vector;
++import abagames.util.Vector;
++import abagames.util.Actor;
+ import abagames.util.Rand;
+ import abagames.util.ActorInitializer;
+ import abagames.a7xpg.LuminousActor;
+@@ -34,7 +35,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- ParticleInitializer pi = (ParticleInitializer) ini;
++ ParticleInitializer pi = cast(ParticleInitializer) ini;
+ field = pi.field;
+ rand = pi.rand;
+ pos = new Vector;
+diff -Naur a7xpg/src/abagames/a7xpg/Ship.d a7xpg-gentoo/src/abagames/a7xpg/Ship.d
+--- a7xpg/src/abagames/a7xpg/Ship.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/a7xpg/Ship.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.a7xpg.Ship;
+
+-import math;
++import std.math;
+ import opengl;
+ import abagames.util.Vector;
+ import abagames.util.Rand;
+@@ -79,7 +79,7 @@
+ cnt = -RESTART_CNT;
+ }
+
+- private const int[] ENEMY_SCORE_TABLE =
++ private const int[] ENEMY_SCORE_TABLE =
+ [100, 200, 400, 800, 1600, 3200, 4850, 5730, 7650, 8560];
+
+ public void destroyEnemy() {
+@@ -119,23 +119,23 @@
+ int pad = input.getPadState();
+ if (pad & Input.PAD_UP) {
+ if (pad & Input.PAD_RIGHT)
+- deg = math.PI / 4;
++ deg = PI / 4;
+ else if (pad & Input.PAD_LEFT)
+- deg = math.PI / 4 * 7;
+- else
++ deg = PI / 4 * 7;
++ else
+ deg = 0;
+ } else if (pad & Input.PAD_DOWN) {
+ if (pad & Input.PAD_RIGHT)
+- deg = math.PI / 4 * 3;
++ deg = PI / 4 * 3;
+ else if (pad & Input.PAD_LEFT)
+- deg = math.PI / 4 * 5;
+- else
+- deg = math.PI / 4 * 4;
++ deg = PI / 4 * 5;
++ else
++ deg = PI / 4 * 4;
+ } else {
+ if (pad & Input.PAD_RIGHT)
+- deg = math.PI / 4 * 2;
++ deg = PI / 4 * 2;
+ else if (pad & Input.PAD_LEFT)
+- deg = math.PI / 4 * 6;
++ deg = PI / 4 * 6;
+ }
+ int btn = input.getButtonState();
+ if (btn & (Input.PAD_BUTTON1 | Input.PAD_BUTTON2)) {
+@@ -180,7 +180,7 @@
+ invincible = true;
+ enemyDstCnt = 0;
+ for (int i = 0; i < 50; i++) {
+- manager.addParticle(pos, rand.nextFloat(math.PI * 2), SIZE, rand.nextFloat(4),
++ manager.addParticle(pos, rand.nextFloat(PI * 2), SIZE, rand.nextFloat(4),
+ 0.9, 0.5, 0.5);
+ }
+ }
+@@ -228,16 +228,16 @@
+ for (int i = 0; i < prtNum; i++) {
+ float pr, pg, pb;
+ if (invincible) {
+- pr = 0.3 + 0.6 * gauge / GAUGE_MAX;
+- pg = 0.4;
+- pb = 0.9 - 0.6 * gauge / GAUGE_MAX;
++ pr = 0.3 + 0.6 * gauge / GAUGE_MAX;
++ pg = 0.4;
++ pb = 0.9 - 0.6 * gauge / GAUGE_MAX;
+ } else {
+ pr = 0.3; pg = 0.3; pb = 0.9;
+ }
+- manager.addParticle(pos, deg + math.PI + rand.nextFloat(0.5) - 0.25, SIZE, ps, pr, pg, pb);
++ manager.addParticle(pos, deg + PI + rand.nextFloat(0.5) - 0.25, SIZE, ps, pr, pg, pb);
+ }
+ if (hitWall && pSpeed > DEFAULT_SPEED * 1.1) {
+- int pn = pSpeed / (DEFAULT_SPEED / 4);
++ int pn = cast(int)(pSpeed / (DEFAULT_SPEED / 4));
+ for (int i = 0; i < pn; i++) {
+ manager.addParticle(pos, deg + rand.nextFloat(1.2) - 0.6, SIZE, pSpeed * 3,
+ 0.8, 0.6, 0.1);
+@@ -259,7 +259,7 @@
+ return;
+ glPushMatrix();
+ glTranslatef(pos.x, pos.y, 0.5);
+- glRotatef(-deg * 180 / math.PI, 0, 0, 1);
++ glRotatef(-deg * 180 / PI, 0, 0, 1);
+ glCallList(displayListIdx);
+ glCallList(displayListIdx + 1);
+ glTranslatef(0, 0, -0.5);
+@@ -273,7 +273,7 @@
+ return;
+ glPushMatrix();
+ glTranslatef(pos.x, pos.y, 0.5);
+- glRotatef(-deg * 180 / math.PI, 0, 0, 1);
++ glRotatef(-deg * 180 / PI, 0, 0, 1);
+ if (invincible)
+ glCallList(displayListIdx + 2);
+ else
+@@ -341,15 +341,15 @@
+ float d = atan2(pos.x - p.x, pos.y - p.y);
+ float wd = d;
+ if (d < 0)
+- d += math.PI * 2;
++ d += PI * 2;
+ d -= deg;
+- if (d < -math.PI)
+- d += math.PI * 2;
+- else if (d > math.PI)
+- d -= math.PI * 2;
++ if (d < -PI)
++ d += PI * 2;
++ else if (d > PI)
++ d -= PI * 2;
+ if (d < 0)
+ d = -d;
+- if (d > math.PI / 4)
++ if (d > PI / 4)
+ return;
+ d *= 2; d++;
+ float ds = pos.dist(p);
+diff -Naur a7xpg/src/abagames/util/ActorPool.d a7xpg-gentoo/src/abagames/util/ActorPool.d
+--- a7xpg/src/abagames/util/ActorPool.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/ActorPool.d 2007-09-19 22:11:32.000000000 +0200
+@@ -6,6 +6,7 @@
+ module abagames.util.ActorPool;
+
+ import abagames.util.Actor;
++import abagames.util.ActorInitializer;
+
+ /**
+ * Object pooling for actors.
+diff -Naur a7xpg/src/abagames/util/Logger.d a7xpg-gentoo/src/abagames/util/Logger.d
+--- a7xpg/src/abagames/util/Logger.d 2003-09-20 13:04:06.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/Logger.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,14 +5,14 @@
+ */
+ module abagames.util.Logger;
+
+-import stream;
++import std.stream;
+
+ /**
+ * Logger(error/info).
+ */
+ public class Logger {
+ public static void info(char[] msg) {
+- stderr.writeLine("Info: " ~ msg);
++// stderr.writeLine("Info: " ~ msg);
+ }
+
+ public static void error(char[] msg) {
+diff -Naur a7xpg/src/abagames/util/Rand.d a7xpg-gentoo/src/abagames/util/Rand.d
+--- a7xpg/src/abagames/util/Rand.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/Rand.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,28 +5,28 @@
+ */
+ module abagames.util.Rand;
+
+-import random;
+-import date;
++import std.random;
++import std.date;
+
+ /**
+ * Random number generator.
+ */
+ public class Rand {
+-
++
+ public this() {
+ d_time timer = getUTCtime();
+- rand_seed(timer, 0);
++ rand_seed(timer, 0);
+ }
+
+ public int nextInt(int n) {
+- return random.rand() % n;
++ return rand() % n;
+ }
+
+ public int nextSignedInt(int n) {
+- return random.rand() % (n * 2) - n;
++ return rand() % (n * 2) - n;
+ }
+
+ public float nextFloat(float n) {
+- return ((float)(random.rand() % (n * 10000))) / 10000;
++ return (cast(float)(rand() % (n * 10000))) / 10000;
+ }
+ }
+diff -Naur a7xpg/src/abagames/util/sdl/Input.d a7xpg-gentoo/src/abagames/util/sdl/Input.d
+--- a7xpg/src/abagames/util/sdl/Input.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/sdl/Input.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,9 +5,35 @@
+ */
+ module abagames.util.sdl.Input;
+
+-import string;
+-import SDL;
++import std.string;
++import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_mixer;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
++
+ import abagames.util.sdl.SDLInitFailedException;
++import abagames.util.Logger;
+
+ /**
+ * Joystick and keyboard input.
+@@ -29,16 +55,19 @@
+
+ public void openJoystick() {
+ if (SDL_InitSubSystem(SDL_INIT_JOYSTICK) < 0) {
+- throw new SDLInitFailedException(
+- "Unable to init SDL joystick: " ~ string.toString(SDL_GetError()));
++ //throw new SDLInitFailedException(
++ Logger.info(
++ "Unable to init SDL joystick: " ~ std.string.toString(SDL_GetError()));
+ }
++ else {
+ stick = SDL_JoystickOpen(0);
++ }
+ }
+
+ public void handleEvent(SDL_Event *event) {
+ keys = SDL_GetKeyState(null);
+ }
+-
++
+ // Joystick and keyboard handler.
+
+ public int getPadState() {
+diff -Naur a7xpg/src/abagames/util/sdl/MainLoop.d a7xpg-gentoo/src/abagames/util/sdl/MainLoop.d
+--- a7xpg/src/abagames/util/sdl/MainLoop.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/sdl/MainLoop.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,9 +5,33 @@
+ */
+ module abagames.util.sdl.MainLoop;
+
+-import string;
+-import c.stdlib;
+-import SDL;
++import std.string;
++import std.c.stdlib;
++import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_mixer;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import abagames.util.Logger;
+ import abagames.util.Rand;
+ import abagames.util.GameManager;
+@@ -71,7 +95,7 @@
+ int i;
+ long nowTick;
+ int frame;
+-
++
+ try {
+ screen.initSDL();
+ } catch (SDLInitFailedException e) {
+@@ -88,7 +112,7 @@
+ done = 1;
+
+ nowTick = SDL_GetTicks();
+- frame = (int) (nowTick-prvTickCount) / interval;
++ frame = cast(int) (nowTick-prvTickCount) / interval;
+ if (frame <= 0) {
+ frame = 1;
+ SDL_Delay(prvTickCount+interval-nowTick);
+diff -Naur a7xpg/src/abagames/util/sdl/Screen3D.d a7xpg-gentoo/src/abagames/util/sdl/Screen3D.d
+--- a7xpg/src/abagames/util/sdl/Screen3D.d 2003-09-21 13:01:28.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/sdl/Screen3D.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,9 +5,33 @@
+ */
+ module abagames.util.sdl.Screen3D;
+
+-import string;
+-import c.stdlib;
+-import SDL;
++import std.string;
++import std.c.stdlib;
++import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_mixer;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import opengl;
+ import abagames.util.Logger;
+ import abagames.util.sdl.Screen;
+@@ -38,7 +62,7 @@
+ // Initialize SDL.
+ if (SDL_Init(SDL_INIT_VIDEO) < 0) {
+ throw new SDLInitFailedException(
+- "Unable to initialize SDL: " ~ string.toString(SDL_GetError()));
++ "Unable to initialize SDL: " ~ std.string.toString(SDL_GetError()));
+ }
+ // Create an OpenGL screen.
+ Uint32 videoFlags;
+@@ -46,10 +70,10 @@
+ videoFlags = SDL_OPENGL | SDL_RESIZABLE;
+ } else {
+ videoFlags = SDL_OPENGL | SDL_FULLSCREEN;
+- }
++ }
+ if (SDL_SetVideoMode(width, height, 0, videoFlags) == null) {
+ throw new SDLInitFailedException
+- ("Unable to create SDL screen: " ~ string.toString(SDL_GetError()));
++ ("Unable to create SDL screen: " ~ std.string.toString(SDL_GetError()));
+ }
+ glViewport(0, 0, width, height);
+ glClearColor(0.0f, 0.0f, 0.0f, 0.0f);
+@@ -67,8 +91,8 @@
+ //gluPerspective(45.0f, (GLfloat)width/(GLfloat)height, nearPlane, farPlane);
+ glFrustum(-nearPlane,
+ nearPlane,
+- -nearPlane * (GLfloat)height / (GLfloat)width,
+- nearPlane * (GLfloat)height / (GLfloat)width,
++ -nearPlane * cast(GLfloat)height / cast(GLfloat)width,
++ nearPlane * cast(GLfloat)height / cast(GLfloat)width,
+ 0.1f, farPlane);
+ glMatrixMode(GL_MODELVIEW);
+ }
+@@ -101,6 +125,6 @@
+ }
+
+ protected void setCaption(char[] name) {
+- SDL_WM_SetCaption(string.toStringz(name), null);
++ SDL_WM_SetCaption(std.string.toStringz(name), null);
+ }
+ }
+diff -Naur a7xpg/src/abagames/util/sdl/Sound.d a7xpg-gentoo/src/abagames/util/sdl/Sound.d
+--- a7xpg/src/abagames/util/sdl/Sound.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/sdl/Sound.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,9 +5,32 @@
+ */
+ module abagames.util.sdl.Sound;
+
+-import string;
+-import SDL;
+-import SDL_mixer;
++import std.string;
++import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_mixer;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import abagames.util.sdl.SDLInitFailedException;
+
+ /**
+@@ -31,7 +54,7 @@
+ if (SDL_InitSubSystem(SDL_INIT_AUDIO) < 0) {
+ noSound = 1;
+ throw new SDLInitFailedException
+- ("Unable to initialize SDL_AUDIO: " ~ string.toString(SDL_GetError()));
++ ("Unable to initialize SDL_AUDIO: " ~ std.string.toString(SDL_GetError()));
+ }
+
+ audio_rate = 44100;
+@@ -41,7 +64,7 @@
+ if (Mix_OpenAudio(audio_rate, audio_format, audio_channels, audio_buffers) < 0) {
+ noSound = 1;
+ throw new SDLInitFailedException
+- ("Couldn't open audio: " ~ string.toString(SDL_GetError()));
++ ("Couldn't open audio: " ~ std.string.toString(SDL_GetError()));
+ }
+ Mix_QuerySpec(&audio_rate, &audio_format, &audio_channels);
+ }
+@@ -66,22 +89,22 @@
+ public void loadSound(char[] name) {
+ if (noSound) return;
+ char[] fileName = soundsDir ~ name;
+- music = Mix_LoadMUS(string.toStringz(fileName));
++ music = Mix_LoadMUS(std.string.toStringz(fileName));
+ if (!music) {
+ noSound = true;
+- throw new SDLInitFailedException("Couldn't load: " ~ fileName ~
+- " (" ~ string.toString(Mix_GetError()) ~ ")");
++ throw new SDLInitFailedException("Couldn't load: " ~ fileName ~
++ " (" ~ std.string.toString(Mix_GetError()) ~ ")");
+ }
+ }
+-
++
+ public void loadChunk(char[] name, int ch) {
+ if (noSound) return;
+ char[] fileName = chunksDir ~ name;
+- chunk = Mix_LoadWAV(string.toStringz(fileName));
++ chunk = Mix_LoadWAV(std.string.toStringz(fileName));
+ if (!chunk) {
+ noSound = true;
+- throw new SDLInitFailedException("Couldn't load: " ~ fileName ~
+- " (" ~ string.toString(Mix_GetError()) ~ ")");
++ throw new SDLInitFailedException("Couldn't load: " ~ fileName ~
++ " (" ~ std.string.toString(Mix_GetError()) ~ ")");
+ }
+ chunkChannel = ch;
+ }
+diff -Naur a7xpg/src/abagames/util/sdl/Texture.d a7xpg-gentoo/src/abagames/util/sdl/Texture.d
+--- a7xpg/src/abagames/util/sdl/Texture.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/sdl/Texture.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,9 +5,33 @@
+ */
+ module abagames.util.sdl.Texture;
+
+-import string;
++import std.string;
+ import opengl;
+-import SDL;
++import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_mixer;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import abagames.util.sdl.SDLInitFailedException;
+
+ /**
+@@ -22,8 +46,8 @@
+
+ public this(char[] name) {
+ char[] fileName = imagesDir ~ name;
+- SDL_Surface *surface;
+- surface = SDL_LoadBMP(string.toStringz(fileName));
++ SDL_Surface *surface;
++ surface = SDL_LoadBMP(std.string.toStringz(fileName));
+ if (!surface) {
+ throw new SDLInitFailedException("Unable to load: " ~ fileName);
+ }
+@@ -33,7 +57,7 @@
+ GL_RGB, GL_UNSIGNED_BYTE, surface.pixels);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+- /*gluBuild2DMipmaps(GL_TEXTURE_2D, 3, surface.w, surface.h,
++ /*gluBuild2DMipmaps(GL_TEXTURE_2D, 3, surface.w, surface.h,
+ GL_RGB, GL_UNSIGNED_BYTE, surface.pixels);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);*/
+diff -Naur a7xpg/src/abagames/util/Vector.d a7xpg-gentoo/src/abagames/util/Vector.d
+--- a7xpg/src/abagames/util/Vector.d 2003-09-19 23:55:50.000000000 +0200
++++ a7xpg-gentoo/src/abagames/util/Vector.d 2007-09-19 22:11:32.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.util.Vector;
+
+-import math;
++import std.math;
+
+ /**
+ * Vector.
+@@ -34,7 +34,7 @@
+ rsl.x = mag * v.x / ll;
+ rsl.y = mag * v.y / ll;
+ } else {
+- rsl.x = rsl.y = 0;
++ rsl.x = rsl.y = 0;
+ }
+ return rsl;
+ }
+@@ -49,30 +49,30 @@
+ y -= v.y;
+ }
+
+- public void mul(float a) {
++ public void mul(float a) {
+ x *= a;
+ y *= a;
+ }
+
+- public void div(float a) {
++ public void div(float a) {
+ x /= a;
+ y /= a;
+ }
+
+ public int checkSide(Vector pos1, Vector pos2) {
+- int xo = pos2.x - pos1.x;
+- int yo = pos2.y - pos1.y;
++ int xo = cast(int)(pos2.x - pos1.x);
++ int yo = cast(int)(pos2.y - pos1.y);
+ if (xo == 0) {
+ if (yo == 0)
+ return 0;
+- return x - pos1.x;
++ return cast(int)(x - pos1.x);
+ } else if (yo == 0) {
+- return pos1.y - y;
++ return cast(int)(pos1.y - y);
+ } else {
+- if (xo * yo > 0) {
+- return (x - pos1.x) / xo - (y - pos1.y) / yo;
++ if (xo * yo > 0) {
++ return cast(int)((x - pos1.x) / xo - (y - pos1.y) / yo);
+ } else {
+- return -(x - pos1.x) / xo + (y - pos1.y) / yo;
++ return -cast(int)((x - pos1.x) / xo + (y - pos1.y) / yo);
+ }
+ }
+ }
+diff -Naur a7xpg/src/dirent.d a7xpg-gentoo/src/dirent.d
+--- a7xpg/src/dirent.d 1970-01-01 01:00:00.000000000 +0100
++++ a7xpg-gentoo/src/dirent.d 2007-09-19 22:11:32.000000000 +0200
+@@ -0,0 +1,10 @@
++import std.string;
++
++extern (C) {
++ alias void DIR;
++ alias void dirent;
++ DIR* opendir(char* name);
++ dirent* readdir(DIR* dir);
++ int closedir(DIR* dir);
++ char* readdir_filename(DIR* ent);
++}
+diff -Naur a7xpg/src/dirent_d.c a7xpg-gentoo/src/dirent_d.c
+--- a7xpg/src/dirent_d.c 1970-01-01 01:00:00.000000000 +0100
++++ a7xpg-gentoo/src/dirent_d.c 2007-09-19 22:11:32.000000000 +0200
+@@ -0,0 +1,59 @@
++#ifdef WINDOWS
++
++#include <windows.h>
++
++#include <stdio.h>
++#include <malloc.h>
++
++typedef struct {
++ HANDLE h;
++ char* prev;
++} DIR;
++
++DIR* opendir(char* dir) {
++ WIN32_FIND_DATA fd;
++ HANDLE h;
++ DIR* d;
++ char buf[MAX_PATH];
++
++ sprintf(buf, "%s/*", dir);
++ h = FindFirstFileA(buf, &fd);
++ d = (DIR*)malloc(sizeof(DIR));
++ d->h = h;
++ d->prev = 0;
++ return d;
++}
++
++char* readdir_filename(DIR* d) {
++ WIN32_FIND_DATA fd;
++ BOOL ret = FindNextFileA(d->h, &fd);
++ if (ret) {
++ if (d->prev != 0) free(d->prev);
++ d->prev = malloc(sizeof(char) * strlen(fd.cFileName));
++ strcpy(d->prev, fd.cFileName);
++ return d->prev;
++ }
++ else {
++ return NULL;
++ }
++}
++
++int closedir(DIR* d) {
++ FindClose(d->h);
++ free(d->prev);
++ free(d);
++}
++
++#else // ! WINDOWS
++
++#include "dirent.h"
++#include "unistd.h"
++
++char* readdir_filename(DIR* dir) {
++ struct dirent* ent = readdir(dir);
++ if (ent == NULL) return NULL;
++ else return ent->d_name;
++}
++
++#endif // WINDOWS
++
diff --git a/games-action/a7xpg/files/a7xpg.png b/games-action/a7xpg/files/a7xpg.png
new file mode 100644
index 0000000..c2f8d21
--- /dev/null
+++ b/games-action/a7xpg/files/a7xpg.png
Binary files differ
diff --git a/games-action/a7xpg/files/a7xpg.prf b/games-action/a7xpg/files/a7xpg.prf
new file mode 100644
index 0000000..8676b7b
--- /dev/null
+++ b/games-action/a7xpg/files/a7xpg.prf
Binary files differ
diff --git a/games-action/a7xpg/files/digest-a7xpg-0.11 b/games-action/a7xpg/files/digest-a7xpg-0.11
new file mode 100644
index 0000000..9b2f41d
--- /dev/null
+++ b/games-action/a7xpg/files/digest-a7xpg-0.11
@@ -0,0 +1,3 @@
+MD5 3280918840913d629b13dc02bcbbfa7d a7xpg0_11.zip 3960261
+RMD160 e2318b08743eeec62b9615e8e1f14c0a6b633ab6 a7xpg0_11.zip 3960261
+SHA256 128c0485794732262e1685e2afaf7521f2dd9468ac8587f0afb166b4e5cf4b12 a7xpg0_11.zip 3960261
diff --git a/games-action/a7xpg/metadata.xml b/games-action/a7xpg/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/a7xpg/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/ardentryst/Manifest b/games-action/ardentryst/Manifest
new file mode 100644
index 0000000..8afd082
--- /dev/null
+++ b/games-action/ardentryst/Manifest
@@ -0,0 +1,3 @@
+DIST ardentryst1.71.tar.gz 26651674 RMD160 ce260620924b24d289e77695751df00fa4ac3b02 SHA1 13fea2736b8289587c1cefa98ee4df2a76681e2e SHA256 2b7385ab9abbc28b86dab2c2f3ed31bf03a37a24ddf5439ebf30819be8f986a9
+EBUILD ardentryst-1.71.ebuild 816 RMD160 18dab7fb9e53f63492e9af4ed5ecffcab8ab321d SHA1 d2ef4063dc826a6ff401adba10164896cd966687 SHA256 10ea5b5d5a5fe026b68465f0c740f8a59dcd809d7b970db89b0e95661825345c
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/ardentryst/ardentryst-1.71.ebuild b/games-action/ardentryst/ardentryst-1.71.ebuild
new file mode 100644
index 0000000..368a2a1
--- /dev/null
+++ b/games-action/ardentryst/ardentryst-1.71.ebuild
@@ -0,0 +1,31 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+inherit games
+
+MY_P=${P/-/}
+
+DESCRIPTION="An action/RPG sidescoller, focused not just on fighting, but on story and character development."
+HOMEPAGE="http://jordan.trudgett.com/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_P}.tar.gz"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+RDEPEND="dev-python/pygame"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_P}
+
+src_install() {
+ insinto "${GAMES_DATADIR}/${PN}"
+ doins -r Base Data Demos Fonts Levels Music Sounds OPR.txt *.py *.dig *.xml || die "doins failed"
+ games_make_wrapper ${PN} "python ./ardentryst.py" "${GAMES_DATADIR}/${PN}"
+ newicon Data/icon.png ${PN}.png
+ make_desktop_entry ${PN} Ardentryst
+ dodoc help.txt || die
+ prepgamesdirs
+}
diff --git a/games-action/ardentryst/metadata.xml b/games-action/ardentryst/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/ardentryst/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/area2048/Manifest b/games-action/area2048/Manifest
new file mode 100644
index 0000000..7fe2a0e
--- /dev/null
+++ b/games-action/area2048/Manifest
@@ -0,0 +1,6 @@
+AUX area2048-1.03.diff 74974 RMD160 3d0455d0e8116093f3e9df459b07bc529f26fcf8 SHA1 9a9e4d7ad1459d011933c28b7faf2fa2a08b2d5e SHA256 29c17c3fa78c7960364e3dae7245557b8089983ae3d8ea9d39be9de348830841
+AUX area2048.png 2508 RMD160 ed2b930a82af71092c62512178c1a039eb8f8a3e SHA1 624afa5b4714f8df8dc463b349c316d8343beae3 SHA256 ea0d0b4be0892bc8a8fe02ae641e8aa1e6806c186eb59006a1d2cec6f1064ca8
+DIST a2k.zip 5909080 RMD160 b41d3df704f0eea124b5e67cac7225d9db117b72 SHA1 e8fd183dd844b584a6c7cb8f87253e90e2547606 SHA256 c183d9b1c170249f9c0d176d527d84d4dc93b556ee59f1e0a3f3216fcb4e0426
+DIST a2k_src.zip 176719 RMD160 1f68dd97b0cff8d7e7e29117fcbe29aaf2518fed SHA1 8cb42a9879f68d8197cc598434b03096561d824e SHA256 ac574736f0e62b684696c4120e363d22f9838c79bfa56a6ff6b87c1e79c9358b
+EBUILD area2048-1.03.ebuild 2135 RMD160 377e62799e89f99e67a7c6be98fc2286e8c1f9ad SHA1 7927c66558b1b9d7ff6fc38368b717e6d51686b2 SHA256 cc166e918c05e00826b7833f47db170083d72372b6eb766cf679b7bc352c9a1c
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/area2048/area2048-1.03.ebuild b/games-action/area2048/area2048-1.03.ebuild
new file mode 100644
index 0000000..4888239
--- /dev/null
+++ b/games-action/area2048/area2048-1.03.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=a2k
+MY_PV=${PV//./_}
+
+DESCRIPTION="jumpei isshiki's HelloWorldProject (2005/01/17) "
+HOMEPAGE="http://homepage2.nifty.com/isshiki/prog_win_d.html"
+SRC_URI="mirror://homepage2.nifty.com/isshiki/${MY_PN}.zip
+ mirror://homepage2.nifty.com/isshiki/${MY_PN}_src.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_unpack(){
+ cd "${WORKDIR}"
+ unpack ${MY_PN}.zip
+ cd "${S}"
+ unpack ${MY_PN}_src.zip
+
+}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(icon.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/util_pad.d \
+ -e 's:"\(title.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(stg0[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(boss0[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(se_[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(voice[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(bullet[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(score.dat[^"]*\)":"'${GAMES_STATEDIR}'/'a2k'\1":g' -i a2k_src/src/init.d \
+ -e 's:"\(config.dat[^"]*\)":"'${GAMES_STATEDIR}'/'a2k'\1":g' -i a2k_src/src/init.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN} || die "dogamesbin failed"
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir "${GAMES_STATEDIR}"
+ touch ${D}/"${GAMES_STATEDIR}"/a2kscore.dat || die "touch failed"
+ fperms 660 "${GAMES_STATEDIR}"/a2kscore.dat
+ touch ${D}/"${GAMES_STATEDIR}"/a2kconfig.dat || die "touch failed"
+ fperms 660 "${GAMES_STATEDIR}"/a2kconfig.dat
+
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins *.xml *.bmp *.ogg *.wav || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/area2048/files/area2048-1.03.diff b/games-action/area2048/files/area2048-1.03.diff
new file mode 100644
index 0000000..4b12836
--- /dev/null
+++ b/games-action/area2048/files/area2048-1.03.diff
@@ -0,0 +1,2469 @@
+diff -Naur a2k-org/a2k_src/import/opengl.d a2k/a2k_src/import/opengl.d
+--- a2k-org/a2k_src/import/opengl.d 2008-02-12 22:20:18.000000000 +0100
++++ a2k/a2k_src/import/opengl.d 2008-10-07 10:47:18.000000000 +0200
+@@ -1,16 +1,6 @@
+-version (Win32) {
+- import std.c.windows.windows;
+-}
+-extern(System):
+-
+-/* Please use this code with old D compiler.
+-version (Win32) {
+- extern(Windows):
+-}
+-else {
++
+ extern(C):
+-}
+-*/
++
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1122,7 +1112,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf cref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1375,7 +1365,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint cref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur a2k-org/a2k_src/import/openglu.d a2k/a2k_src/import/openglu.d
+--- a2k-org/a2k_src/import/openglu.d 2008-02-12 22:20:14.000000000 +0100
++++ a2k/a2k_src/import/openglu.d 2008-10-07 10:47:18.000000000 +0200
+@@ -1,15 +1,6 @@
+-import opengl;
+
+-extern(System):
+-
+-/* Please use this code with old D compiler.
+-version (Win32) {
+- extern(Windows):
+-}
+-else {
+ extern(C):
+-}
+-*/
++
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur a2k-org/a2k_src/import/SDL_active.d a2k/a2k_src/import/SDL_active.d
+--- a2k-org/a2k_src/import/SDL_active.d 2006-07-26 23:24:30.000000000 +0200
++++ a2k/a2k_src/import/SDL_active.d 2002-01-04 15:25:02.000000000 +0100
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL application focus event handling */
+
+-public import SDL_types;
++import SDL_types;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_audio.d a2k/a2k_src/import/SDL_audio.d
+--- a2k-org/a2k_src/import/SDL_audio.d 2006-07-26 23:24:40.000000000 +0200
++++ a2k/a2k_src/import/SDL_audio.d 2002-05-22 07:38:58.000000000 +0200
+@@ -20,10 +20,10 @@
+ slouken@devolution.com
+ */
+
+-public import SDL_types;
+-public import SDL_error;
+-public import SDL_rwops;
+-public import SDL_byteorder;
++import SDL_types;
++import SDL_error;
++import SDL_rwops;
++import SDL_byteorder;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_cdrom.d a2k/a2k_src/import/SDL_cdrom.d
+--- a2k-org/a2k_src/import/SDL_cdrom.d 2006-07-26 23:24:42.000000000 +0200
++++ a2k/a2k_src/import/SDL_cdrom.d 2002-05-22 07:44:28.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* This is the CD-audio control API for Simple DirectMedia Layer */
+
+-public import SDL_types;
++import SDL_types;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL.d a2k/a2k_src/import/SDL.d
+--- a2k-org/a2k_src/import/SDL.d 2006-07-26 23:24:12.000000000 +0200
++++ a2k/a2k_src/import/SDL.d 2008-10-07 10:47:18.000000000 +0200
+@@ -33,60 +33,60 @@
+ public import SDL_byteorder;
+ public import SDL_Version;
+
+-extern(C):
+-
+-/* As of version 0.5, SDL is loaded dynamically into the application */
+-
+-/* These are the flags which may be passed to SDL_Init() -- you should
+- specify the subsystems which you will be using in your application.
+-*/
+-const uint SDL_INIT_TIMER = 0x00000001;
+-const uint SDL_INIT_AUDIO = 0x00000010;
+-const uint SDL_INIT_VIDEO = 0x00000020;
+-const uint SDL_INIT_CDROM = 0x00000100;
+-const uint SDL_INIT_JOYSTICK = 0x00000200;
+-const uint SDL_INIT_NOPARACHUTE = 0x00100000; /* Don't catch fatal signals */
+-const uint SDL_INIT_EVENTTHREAD = 0x01000000; /* Not supported on all OS's */
+-const uint SDL_INIT_EVERYTHING = 0x0000FFFF;
+-
+-/* This function loads the SDL dynamically linked library and initializes
+- * the subsystems specified by 'flags' (and those satisfying dependencies)
+- * Unless the SDL_INIT_NOPARACHUTE flag is set, it will install cleanup
+- * signal handlers for some commonly ignored fatal signals (like SIGSEGV)
+- */
+-int SDL_Init(Uint32 flags);
+-
+-/* This function initializes specific SDL subsystems */
+-int SDL_InitSubSystem(Uint32 flags);
+-
+-/* This function cleans up specific SDL subsystems */
+-void SDL_QuitSubSystem(Uint32 flags);
+-
+-/* This function returns mask of the specified subsystems which have
+- been initialized.
+- If 'flags' is 0, it returns a mask of all initialized subsystems.
+-*/
+-Uint32 SDL_WasInit(Uint32 flags);
+-
+-/* This function cleans up all initialized subsystems and unloads the
+- * dynamically linked library. You should call it upon all exit conditions.
+- */
+-void SDL_Quit();
+-
+-void SDL_SetModuleHandle(void *hInst);
+-//extern(Windows) void* GetModuleHandle(char*);
+-extern(Windows) void* GetModuleHandleA(char*);
+-
+-static this()
+-{
+- /* Load SDL dynamic link library */
+- if (SDL_Init(SDL_INIT_NOPARACHUTE) < 0)
+- throw new Error("Error loading SDL");
+-// SDL_SetModuleHandle(GetModuleHandle(null));
+- SDL_SetModuleHandle(GetModuleHandleA(null));
+-}
+-
+-static ~this()
+-{
+- SDL_Quit();
+-}
++extern(C):
++
++/* As of version 0.5, SDL is loaded dynamically into the application */
++
++/* These are the flags which may be passed to SDL_Init() -- you should
++ specify the subsystems which you will be using in your application.
++*/
++const uint SDL_INIT_TIMER = 0x00000001;
++const uint SDL_INIT_AUDIO = 0x00000010;
++const uint SDL_INIT_VIDEO = 0x00000020;
++const uint SDL_INIT_CDROM = 0x00000100;
++const uint SDL_INIT_JOYSTICK = 0x00000200;
++const uint SDL_INIT_NOPARACHUTE = 0x00100000; /* Don't catch fatal signals */
++const uint SDL_INIT_EVENTTHREAD = 0x01000000; /* Not supported on all OS's */
++const uint SDL_INIT_EVERYTHING = 0x0000FFFF;
++
++/* This function loads the SDL dynamically linked library and initializes
++ * the subsystems specified by 'flags' (and those satisfying dependencies)
++ * Unless the SDL_INIT_NOPARACHUTE flag is set, it will install cleanup
++ * signal handlers for some commonly ignored fatal signals (like SIGSEGV)
++ */
++int SDL_Init(Uint32 flags);
++
++/* This function initializes specific SDL subsystems */
++int SDL_InitSubSystem(Uint32 flags);
++
++/* This function cleans up specific SDL subsystems */
++void SDL_QuitSubSystem(Uint32 flags);
++
++/* This function returns mask of the specified subsystems which have
++ been initialized.
++ If 'flags' is 0, it returns a mask of all initialized subsystems.
++*/
++Uint32 SDL_WasInit(Uint32 flags);
++
++/* This function cleans up all initialized subsystems and unloads the
++ * dynamically linked library. You should call it upon all exit conditions.
++ */
++void SDL_Quit();
++
++/+
++void SDL_SetModuleHandle(void *hInst);
++extern(Windows) void* GetModuleHandle(char*);
++
++static this()
++{
++ /* Load SDL dynamic link library */
++ if (SDL_Init(SDL_INIT_NOPARACHUTE) < 0)
++ throw new Error("Error loading SDL");
++ SDL_SetModuleHandle(GetModuleHandle(null));
++}
++
++static ~this()
++{
++ SDL_Quit();
++}
+++/
+diff -Naur a2k-org/a2k_src/import/SDL_endian.d a2k/a2k_src/import/SDL_endian.d
+--- a2k-org/a2k_src/import/SDL_endian.d 2006-09-14 01:57:50.000000000 +0200
++++ a2k/a2k_src/import/SDL_endian.d 2004-05-08 12:55:52.000000000 +0200
+@@ -34,9 +34,9 @@
+ and other data sources.
+ */
+
+-public import SDL_types;
+-public import SDL_rwops;
+-public import SDL_byteorder;
++import SDL_types;
++import SDL_rwops;
++import SDL_byteorder;
+
+ extern(C):
+
+@@ -47,7 +47,7 @@
+ */
+
+ Uint16 SDL_Swap16(Uint16 D) {
+- return cast(Uint16)((D<<8)|(D>>8));
++ return((D<<8)|(D>>8));
+ }
+
+ Uint32 SDL_Swap32(Uint32 D) {
+diff -Naur a2k-org/a2k_src/import/SDL_events.d a2k/a2k_src/import/SDL_events.d
+--- a2k-org/a2k_src/import/SDL_events.d 2006-07-26 23:25:46.000000000 +0200
++++ a2k/a2k_src/import/SDL_events.d 2008-10-07 10:47:18.000000000 +0200
+@@ -22,12 +22,12 @@
+
+ /* Include file for SDL event handling */
+
+-public import SDL_types;
+-public import SDL_active;
+-public import SDL_keyboard;
+-public import SDL_mouse;
+-public import SDL_joystick;
+-public import SDL_syswm;
++import SDL_types;
++import SDL_active;
++import SDL_keyboard;
++import SDL_mouse;
++import SDL_joystick;
++import SDL_syswm;
+
+ extern(C):
+
+@@ -304,7 +304,7 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() will return the
+ current processing state of the specified event.
+ */
+-const int SDL_QUERY = -1;
++const uint SDL_QUERY = -1;
+ const uint SDL_IGNORE = 0;
+ const uint SDL_DISABLE = 0;
+ const uint SDL_ENABLE = 1;
+diff -Naur a2k-org/a2k_src/import/SDL_image.d a2k/a2k_src/import/SDL_image.d
+--- a2k-org/a2k_src/import/SDL_image.d 2006-07-26 23:24:58.000000000 +0200
++++ a2k/a2k_src/import/SDL_image.d 2004-05-08 14:09:32.000000000 +0200
+@@ -26,7 +26,7 @@
+
+ /* A simple library to load images of various formats as SDL surfaces */
+
+-public import SDL;
++import SDL;
+
+ extern (C) {
+
+diff -Naur a2k-org/a2k_src/import/SDL_joystick.d a2k/a2k_src/import/SDL_joystick.d
+--- a2k-org/a2k_src/import/SDL_joystick.d 2006-07-26 23:25:10.000000000 +0200
++++ a2k/a2k_src/import/SDL_joystick.d 2002-01-04 15:24:10.000000000 +0100
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL joystick event handling */
+
+-public import SDL_types;
++import SDL_types;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_keyboard.d a2k/a2k_src/import/SDL_keyboard.d
+--- a2k-org/a2k_src/import/SDL_keyboard.d 2006-07-26 23:25:14.000000000 +0200
++++ a2k/a2k_src/import/SDL_keyboard.d 2002-01-04 15:28:12.000000000 +0100
+@@ -22,11 +22,11 @@
+
+ /* Include file for SDL keyboard event handling */
+
+-public import SDL_types;
++import SDL_types;
+ // !!! A hack! struct SDL_keysym is defined in this module,
+ // !!! so we need to resolve the nameclash...
+ // !!! Definitely won't work on *NIX but for now will do.
+-public import SDL_Keysym;
++import SDL_Keysym;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_keysym.d a2k/a2k_src/import/SDL_keysym.d
+--- a2k-org/a2k_src/import/SDL_keysym.d 2002-01-04 23:31:22.000000000 +0100
++++ a2k/a2k_src/import/SDL_keysym.d 1970-01-01 01:00:00.000000000 +0100
+@@ -1,308 +0,0 @@
+-/*
+- SDL - Simple DirectMedia Layer
+- Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
+-
+- This library is free software; you can redistribute it and/or
+- modify it under the terms of the GNU Library General Public
+- License as published by the Free Software Foundation; either
+- version 2 of the License, or (at your option) any later version.
+-
+- This library is distributed in the hope that it will be useful,
+- but WITHOUT ANY WARRANTY; without even the implied warranty of
+- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+- Library General Public License for more details.
+-
+- You should have received a copy of the GNU Library General Public
+- License along with this library; if not, write to the Free
+- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+-
+- Sam Lantinga
+- slouken@devolution.com
+-*/
+-
+-/* What we really want is a mapping of every raw key on the keyboard.
+- To support international keyboards, we use the range 0xA1 - 0xFF
+- as international virtual keycodes. We'll follow in the footsteps of X11...
+- The names of the keys
+- */
+-
+-alias int SDLKey;
+-enum {
+- /* The keyboard syms have been cleverly chosen to map to ASCII */
+- SDLK_UNKNOWN = 0,
+- SDLK_FIRST = 0,
+- SDLK_BACKSPACE = 8,
+- SDLK_TAB = 9,
+- SDLK_CLEAR = 12,
+- SDLK_RETURN = 13,
+- SDLK_PAUSE = 19,
+- SDLK_ESCAPE = 27,
+- SDLK_SPACE = 32,
+- SDLK_EXCLAIM = 33,
+- SDLK_QUOTEDBL = 34,
+- SDLK_HASH = 35,
+- SDLK_DOLLAR = 36,
+- SDLK_AMPERSAND = 38,
+- SDLK_QUOTE = 39,
+- SDLK_LEFTPAREN = 40,
+- SDLK_RIGHTPAREN = 41,
+- SDLK_ASTERISK = 42,
+- SDLK_PLUS = 43,
+- SDLK_COMMA = 44,
+- SDLK_MINUS = 45,
+- SDLK_PERIOD = 46,
+- SDLK_SLASH = 47,
+- SDLK_0 = 48,
+- SDLK_1 = 49,
+- SDLK_2 = 50,
+- SDLK_3 = 51,
+- SDLK_4 = 52,
+- SDLK_5 = 53,
+- SDLK_6 = 54,
+- SDLK_7 = 55,
+- SDLK_8 = 56,
+- SDLK_9 = 57,
+- SDLK_COLON = 58,
+- SDLK_SEMICOLON = 59,
+- SDLK_LESS = 60,
+- SDLK_EQUALS = 61,
+- SDLK_GREATER = 62,
+- SDLK_QUESTION = 63,
+- SDLK_AT = 64,
+- /*
+- Skip uppercase letters
+- */
+- SDLK_LEFTBRACKET = 91,
+- SDLK_BACKSLASH = 92,
+- SDLK_RIGHTBRACKET = 93,
+- SDLK_CARET = 94,
+- SDLK_UNDERSCORE = 95,
+- SDLK_BACKQUOTE = 96,
+- SDLK_a = 97,
+- SDLK_b = 98,
+- SDLK_c = 99,
+- SDLK_d = 100,
+- SDLK_e = 101,
+- SDLK_f = 102,
+- SDLK_g = 103,
+- SDLK_h = 104,
+- SDLK_i = 105,
+- SDLK_j = 106,
+- SDLK_k = 107,
+- SDLK_l = 108,
+- SDLK_m = 109,
+- SDLK_n = 110,
+- SDLK_o = 111,
+- SDLK_p = 112,
+- SDLK_q = 113,
+- SDLK_r = 114,
+- SDLK_s = 115,
+- SDLK_t = 116,
+- SDLK_u = 117,
+- SDLK_v = 118,
+- SDLK_w = 119,
+- SDLK_x = 120,
+- SDLK_y = 121,
+- SDLK_z = 122,
+- SDLK_DELETE = 127,
+- /* End of ASCII mapped keysyms */
+-
+- /* International keyboard syms */
+- SDLK_WORLD_0 = 160, /* 0xA0 */
+- SDLK_WORLD_1 = 161,
+- SDLK_WORLD_2 = 162,
+- SDLK_WORLD_3 = 163,
+- SDLK_WORLD_4 = 164,
+- SDLK_WORLD_5 = 165,
+- SDLK_WORLD_6 = 166,
+- SDLK_WORLD_7 = 167,
+- SDLK_WORLD_8 = 168,
+- SDLK_WORLD_9 = 169,
+- SDLK_WORLD_10 = 170,
+- SDLK_WORLD_11 = 171,
+- SDLK_WORLD_12 = 172,
+- SDLK_WORLD_13 = 173,
+- SDLK_WORLD_14 = 174,
+- SDLK_WORLD_15 = 175,
+- SDLK_WORLD_16 = 176,
+- SDLK_WORLD_17 = 177,
+- SDLK_WORLD_18 = 178,
+- SDLK_WORLD_19 = 179,
+- SDLK_WORLD_20 = 180,
+- SDLK_WORLD_21 = 181,
+- SDLK_WORLD_22 = 182,
+- SDLK_WORLD_23 = 183,
+- SDLK_WORLD_24 = 184,
+- SDLK_WORLD_25 = 185,
+- SDLK_WORLD_26 = 186,
+- SDLK_WORLD_27 = 187,
+- SDLK_WORLD_28 = 188,
+- SDLK_WORLD_29 = 189,
+- SDLK_WORLD_30 = 190,
+- SDLK_WORLD_31 = 191,
+- SDLK_WORLD_32 = 192,
+- SDLK_WORLD_33 = 193,
+- SDLK_WORLD_34 = 194,
+- SDLK_WORLD_35 = 195,
+- SDLK_WORLD_36 = 196,
+- SDLK_WORLD_37 = 197,
+- SDLK_WORLD_38 = 198,
+- SDLK_WORLD_39 = 199,
+- SDLK_WORLD_40 = 200,
+- SDLK_WORLD_41 = 201,
+- SDLK_WORLD_42 = 202,
+- SDLK_WORLD_43 = 203,
+- SDLK_WORLD_44 = 204,
+- SDLK_WORLD_45 = 205,
+- SDLK_WORLD_46 = 206,
+- SDLK_WORLD_47 = 207,
+- SDLK_WORLD_48 = 208,
+- SDLK_WORLD_49 = 209,
+- SDLK_WORLD_50 = 210,
+- SDLK_WORLD_51 = 211,
+- SDLK_WORLD_52 = 212,
+- SDLK_WORLD_53 = 213,
+- SDLK_WORLD_54 = 214,
+- SDLK_WORLD_55 = 215,
+- SDLK_WORLD_56 = 216,
+- SDLK_WORLD_57 = 217,
+- SDLK_WORLD_58 = 218,
+- SDLK_WORLD_59 = 219,
+- SDLK_WORLD_60 = 220,
+- SDLK_WORLD_61 = 221,
+- SDLK_WORLD_62 = 222,
+- SDLK_WORLD_63 = 223,
+- SDLK_WORLD_64 = 224,
+- SDLK_WORLD_65 = 225,
+- SDLK_WORLD_66 = 226,
+- SDLK_WORLD_67 = 227,
+- SDLK_WORLD_68 = 228,
+- SDLK_WORLD_69 = 229,
+- SDLK_WORLD_70 = 230,
+- SDLK_WORLD_71 = 231,
+- SDLK_WORLD_72 = 232,
+- SDLK_WORLD_73 = 233,
+- SDLK_WORLD_74 = 234,
+- SDLK_WORLD_75 = 235,
+- SDLK_WORLD_76 = 236,
+- SDLK_WORLD_77 = 237,
+- SDLK_WORLD_78 = 238,
+- SDLK_WORLD_79 = 239,
+- SDLK_WORLD_80 = 240,
+- SDLK_WORLD_81 = 241,
+- SDLK_WORLD_82 = 242,
+- SDLK_WORLD_83 = 243,
+- SDLK_WORLD_84 = 244,
+- SDLK_WORLD_85 = 245,
+- SDLK_WORLD_86 = 246,
+- SDLK_WORLD_87 = 247,
+- SDLK_WORLD_88 = 248,
+- SDLK_WORLD_89 = 249,
+- SDLK_WORLD_90 = 250,
+- SDLK_WORLD_91 = 251,
+- SDLK_WORLD_92 = 252,
+- SDLK_WORLD_93 = 253,
+- SDLK_WORLD_94 = 254,
+- SDLK_WORLD_95 = 255, /* 0xFF */
+-
+- /* Numeric keypad */
+- SDLK_KP0 = 256,
+- SDLK_KP1 = 257,
+- SDLK_KP2 = 258,
+- SDLK_KP3 = 259,
+- SDLK_KP4 = 260,
+- SDLK_KP5 = 261,
+- SDLK_KP6 = 262,
+- SDLK_KP7 = 263,
+- SDLK_KP8 = 264,
+- SDLK_KP9 = 265,
+- SDLK_KP_PERIOD = 266,
+- SDLK_KP_DIVIDE = 267,
+- SDLK_KP_MULTIPLY = 268,
+- SDLK_KP_MINUS = 269,
+- SDLK_KP_PLUS = 270,
+- SDLK_KP_ENTER = 271,
+- SDLK_KP_EQUALS = 272,
+-
+- /* Arrows + Home/End pad */
+- SDLK_UP = 273,
+- SDLK_DOWN = 274,
+- SDLK_RIGHT = 275,
+- SDLK_LEFT = 276,
+- SDLK_INSERT = 277,
+- SDLK_HOME = 278,
+- SDLK_END = 279,
+- SDLK_PAGEUP = 280,
+- SDLK_PAGEDOWN = 281,
+-
+- /* Function keys */
+- SDLK_F1 = 282,
+- SDLK_F2 = 283,
+- SDLK_F3 = 284,
+- SDLK_F4 = 285,
+- SDLK_F5 = 286,
+- SDLK_F6 = 287,
+- SDLK_F7 = 288,
+- SDLK_F8 = 289,
+- SDLK_F9 = 290,
+- SDLK_F10 = 291,
+- SDLK_F11 = 292,
+- SDLK_F12 = 293,
+- SDLK_F13 = 294,
+- SDLK_F14 = 295,
+- SDLK_F15 = 296,
+-
+- /* Key state modifier keys */
+- SDLK_NUMLOCK = 300,
+- SDLK_CAPSLOCK = 301,
+- SDLK_SCROLLOCK = 302,
+- SDLK_RSHIFT = 303,
+- SDLK_LSHIFT = 304,
+- SDLK_RCTRL = 305,
+- SDLK_LCTRL = 306,
+- SDLK_RALT = 307,
+- SDLK_LALT = 308,
+- SDLK_RMETA = 309,
+- SDLK_LMETA = 310,
+- SDLK_LSUPER = 311, /* Left "Windows" key */
+- SDLK_RSUPER = 312, /* Right "Windows" key */
+- SDLK_MODE = 313, /* "Alt Gr" key */
+- SDLK_COMPOSE = 314, /* Multi-key compose key */
+-
+- /* Miscellaneous function keys */
+- SDLK_HELP = 315,
+- SDLK_PRINT = 316,
+- SDLK_SYSREQ = 317,
+- SDLK_BREAK = 318,
+- SDLK_MENU = 319,
+- SDLK_POWER = 320, /* Power Macintosh power key */
+- SDLK_EURO = 321, /* Some european keyboards */
+- SDLK_UNDO = 322, /* Atari keyboard has Undo */
+-
+- /* Add any other keys here */
+-
+- SDLK_LAST
+-}
+-
+-/* Enumeration of valid key mods (possibly OR'd together) */
+-alias int SDLMod;
+-enum {
+- KMOD_NONE = 0x0000,
+- KMOD_LSHIFT= 0x0001,
+- KMOD_RSHIFT= 0x0002,
+- KMOD_LCTRL = 0x0040,
+- KMOD_RCTRL = 0x0080,
+- KMOD_LALT = 0x0100,
+- KMOD_RALT = 0x0200,
+- KMOD_LMETA = 0x0400,
+- KMOD_RMETA = 0x0800,
+- KMOD_NUM = 0x1000,
+- KMOD_CAPS = 0x2000,
+- KMOD_MODE = 0x4000,
+- KMOD_RESERVED = 0x8000
+-}
+-
+-const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
+-const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
+-const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
+-const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur a2k-org/a2k_src/import/SDL_Keysym.d a2k/a2k_src/import/SDL_Keysym.d
+--- a2k-org/a2k_src/import/SDL_Keysym.d 1970-01-01 01:00:00.000000000 +0100
++++ a2k/a2k_src/import/SDL_Keysym.d 2008-10-07 10:47:18.000000000 +0200
+@@ -0,0 +1,308 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* What we really want is a mapping of every raw key on the keyboard.
++ To support international keyboards, we use the range 0xA1 - 0xFF
++ as international virtual keycodes. We'll follow in the footsteps of X11...
++ The names of the keys
++ */
++
++alias int SDLKey;
++enum {
++ /* The keyboard syms have been cleverly chosen to map to ASCII */
++ SDLK_UNKNOWN = 0,
++ SDLK_FIRST = 0,
++ SDLK_BACKSPACE = 8,
++ SDLK_TAB = 9,
++ SDLK_CLEAR = 12,
++ SDLK_RETURN = 13,
++ SDLK_PAUSE = 19,
++ SDLK_ESCAPE = 27,
++ SDLK_SPACE = 32,
++ SDLK_EXCLAIM = 33,
++ SDLK_QUOTEDBL = 34,
++ SDLK_HASH = 35,
++ SDLK_DOLLAR = 36,
++ SDLK_AMPERSAND = 38,
++ SDLK_QUOTE = 39,
++ SDLK_LEFTPAREN = 40,
++ SDLK_RIGHTPAREN = 41,
++ SDLK_ASTERISK = 42,
++ SDLK_PLUS = 43,
++ SDLK_COMMA = 44,
++ SDLK_MINUS = 45,
++ SDLK_PERIOD = 46,
++ SDLK_SLASH = 47,
++ SDLK_0 = 48,
++ SDLK_1 = 49,
++ SDLK_2 = 50,
++ SDLK_3 = 51,
++ SDLK_4 = 52,
++ SDLK_5 = 53,
++ SDLK_6 = 54,
++ SDLK_7 = 55,
++ SDLK_8 = 56,
++ SDLK_9 = 57,
++ SDLK_COLON = 58,
++ SDLK_SEMICOLON = 59,
++ SDLK_LESS = 60,
++ SDLK_EQUALS = 61,
++ SDLK_GREATER = 62,
++ SDLK_QUESTION = 63,
++ SDLK_AT = 64,
++ /*
++ Skip uppercase letters
++ */
++ SDLK_LEFTBRACKET = 91,
++ SDLK_BACKSLASH = 92,
++ SDLK_RIGHTBRACKET = 93,
++ SDLK_CARET = 94,
++ SDLK_UNDERSCORE = 95,
++ SDLK_BACKQUOTE = 96,
++ SDLK_a = 97,
++ SDLK_b = 98,
++ SDLK_c = 99,
++ SDLK_d = 100,
++ SDLK_e = 101,
++ SDLK_f = 102,
++ SDLK_g = 103,
++ SDLK_h = 104,
++ SDLK_i = 105,
++ SDLK_j = 106,
++ SDLK_k = 107,
++ SDLK_l = 108,
++ SDLK_m = 109,
++ SDLK_n = 110,
++ SDLK_o = 111,
++ SDLK_p = 112,
++ SDLK_q = 113,
++ SDLK_r = 114,
++ SDLK_s = 115,
++ SDLK_t = 116,
++ SDLK_u = 117,
++ SDLK_v = 118,
++ SDLK_w = 119,
++ SDLK_x = 120,
++ SDLK_y = 121,
++ SDLK_z = 122,
++ SDLK_DELETE = 127,
++ /* End of ASCII mapped keysyms */
++
++ /* International keyboard syms */
++ SDLK_WORLD_0 = 160, /* 0xA0 */
++ SDLK_WORLD_1 = 161,
++ SDLK_WORLD_2 = 162,
++ SDLK_WORLD_3 = 163,
++ SDLK_WORLD_4 = 164,
++ SDLK_WORLD_5 = 165,
++ SDLK_WORLD_6 = 166,
++ SDLK_WORLD_7 = 167,
++ SDLK_WORLD_8 = 168,
++ SDLK_WORLD_9 = 169,
++ SDLK_WORLD_10 = 170,
++ SDLK_WORLD_11 = 171,
++ SDLK_WORLD_12 = 172,
++ SDLK_WORLD_13 = 173,
++ SDLK_WORLD_14 = 174,
++ SDLK_WORLD_15 = 175,
++ SDLK_WORLD_16 = 176,
++ SDLK_WORLD_17 = 177,
++ SDLK_WORLD_18 = 178,
++ SDLK_WORLD_19 = 179,
++ SDLK_WORLD_20 = 180,
++ SDLK_WORLD_21 = 181,
++ SDLK_WORLD_22 = 182,
++ SDLK_WORLD_23 = 183,
++ SDLK_WORLD_24 = 184,
++ SDLK_WORLD_25 = 185,
++ SDLK_WORLD_26 = 186,
++ SDLK_WORLD_27 = 187,
++ SDLK_WORLD_28 = 188,
++ SDLK_WORLD_29 = 189,
++ SDLK_WORLD_30 = 190,
++ SDLK_WORLD_31 = 191,
++ SDLK_WORLD_32 = 192,
++ SDLK_WORLD_33 = 193,
++ SDLK_WORLD_34 = 194,
++ SDLK_WORLD_35 = 195,
++ SDLK_WORLD_36 = 196,
++ SDLK_WORLD_37 = 197,
++ SDLK_WORLD_38 = 198,
++ SDLK_WORLD_39 = 199,
++ SDLK_WORLD_40 = 200,
++ SDLK_WORLD_41 = 201,
++ SDLK_WORLD_42 = 202,
++ SDLK_WORLD_43 = 203,
++ SDLK_WORLD_44 = 204,
++ SDLK_WORLD_45 = 205,
++ SDLK_WORLD_46 = 206,
++ SDLK_WORLD_47 = 207,
++ SDLK_WORLD_48 = 208,
++ SDLK_WORLD_49 = 209,
++ SDLK_WORLD_50 = 210,
++ SDLK_WORLD_51 = 211,
++ SDLK_WORLD_52 = 212,
++ SDLK_WORLD_53 = 213,
++ SDLK_WORLD_54 = 214,
++ SDLK_WORLD_55 = 215,
++ SDLK_WORLD_56 = 216,
++ SDLK_WORLD_57 = 217,
++ SDLK_WORLD_58 = 218,
++ SDLK_WORLD_59 = 219,
++ SDLK_WORLD_60 = 220,
++ SDLK_WORLD_61 = 221,
++ SDLK_WORLD_62 = 222,
++ SDLK_WORLD_63 = 223,
++ SDLK_WORLD_64 = 224,
++ SDLK_WORLD_65 = 225,
++ SDLK_WORLD_66 = 226,
++ SDLK_WORLD_67 = 227,
++ SDLK_WORLD_68 = 228,
++ SDLK_WORLD_69 = 229,
++ SDLK_WORLD_70 = 230,
++ SDLK_WORLD_71 = 231,
++ SDLK_WORLD_72 = 232,
++ SDLK_WORLD_73 = 233,
++ SDLK_WORLD_74 = 234,
++ SDLK_WORLD_75 = 235,
++ SDLK_WORLD_76 = 236,
++ SDLK_WORLD_77 = 237,
++ SDLK_WORLD_78 = 238,
++ SDLK_WORLD_79 = 239,
++ SDLK_WORLD_80 = 240,
++ SDLK_WORLD_81 = 241,
++ SDLK_WORLD_82 = 242,
++ SDLK_WORLD_83 = 243,
++ SDLK_WORLD_84 = 244,
++ SDLK_WORLD_85 = 245,
++ SDLK_WORLD_86 = 246,
++ SDLK_WORLD_87 = 247,
++ SDLK_WORLD_88 = 248,
++ SDLK_WORLD_89 = 249,
++ SDLK_WORLD_90 = 250,
++ SDLK_WORLD_91 = 251,
++ SDLK_WORLD_92 = 252,
++ SDLK_WORLD_93 = 253,
++ SDLK_WORLD_94 = 254,
++ SDLK_WORLD_95 = 255, /* 0xFF */
++
++ /* Numeric keypad */
++ SDLK_KP0 = 256,
++ SDLK_KP1 = 257,
++ SDLK_KP2 = 258,
++ SDLK_KP3 = 259,
++ SDLK_KP4 = 260,
++ SDLK_KP5 = 261,
++ SDLK_KP6 = 262,
++ SDLK_KP7 = 263,
++ SDLK_KP8 = 264,
++ SDLK_KP9 = 265,
++ SDLK_KP_PERIOD = 266,
++ SDLK_KP_DIVIDE = 267,
++ SDLK_KP_MULTIPLY = 268,
++ SDLK_KP_MINUS = 269,
++ SDLK_KP_PLUS = 270,
++ SDLK_KP_ENTER = 271,
++ SDLK_KP_EQUALS = 272,
++
++ /* Arrows + Home/End pad */
++ SDLK_UP = 273,
++ SDLK_DOWN = 274,
++ SDLK_RIGHT = 275,
++ SDLK_LEFT = 276,
++ SDLK_INSERT = 277,
++ SDLK_HOME = 278,
++ SDLK_END = 279,
++ SDLK_PAGEUP = 280,
++ SDLK_PAGEDOWN = 281,
++
++ /* Function keys */
++ SDLK_F1 = 282,
++ SDLK_F2 = 283,
++ SDLK_F3 = 284,
++ SDLK_F4 = 285,
++ SDLK_F5 = 286,
++ SDLK_F6 = 287,
++ SDLK_F7 = 288,
++ SDLK_F8 = 289,
++ SDLK_F9 = 290,
++ SDLK_F10 = 291,
++ SDLK_F11 = 292,
++ SDLK_F12 = 293,
++ SDLK_F13 = 294,
++ SDLK_F14 = 295,
++ SDLK_F15 = 296,
++
++ /* Key state modifier keys */
++ SDLK_NUMLOCK = 300,
++ SDLK_CAPSLOCK = 301,
++ SDLK_SCROLLOCK = 302,
++ SDLK_RSHIFT = 303,
++ SDLK_LSHIFT = 304,
++ SDLK_RCTRL = 305,
++ SDLK_LCTRL = 306,
++ SDLK_RALT = 307,
++ SDLK_LALT = 308,
++ SDLK_RMETA = 309,
++ SDLK_LMETA = 310,
++ SDLK_LSUPER = 311, /* Left "Windows" key */
++ SDLK_RSUPER = 312, /* Right "Windows" key */
++ SDLK_MODE = 313, /* "Alt Gr" key */
++ SDLK_COMPOSE = 314, /* Multi-key compose key */
++
++ /* Miscellaneous function keys */
++ SDLK_HELP = 315,
++ SDLK_PRINT = 316,
++ SDLK_SYSREQ = 317,
++ SDLK_BREAK = 318,
++ SDLK_MENU = 319,
++ SDLK_POWER = 320, /* Power Macintosh power key */
++ SDLK_EURO = 321, /* Some european keyboards */
++ SDLK_UNDO = 322, /* Atari keyboard has Undo */
++
++ /* Add any other keys here */
++
++ SDLK_LAST
++}
++
++/* Enumeration of valid key mods (possibly OR'd together) */
++alias int SDLMod;
++enum {
++ KMOD_NONE = 0x0000,
++ KMOD_LSHIFT= 0x0001,
++ KMOD_RSHIFT= 0x0002,
++ KMOD_LCTRL = 0x0040,
++ KMOD_RCTRL = 0x0080,
++ KMOD_LALT = 0x0100,
++ KMOD_RALT = 0x0200,
++ KMOD_LMETA = 0x0400,
++ KMOD_RMETA = 0x0800,
++ KMOD_NUM = 0x1000,
++ KMOD_CAPS = 0x2000,
++ KMOD_MODE = 0x4000,
++ KMOD_RESERVED = 0x8000
++}
++
++const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
++const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
++const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
++const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur a2k-org/a2k_src/import/SDL_mixer.d a2k/a2k_src/import/SDL_mixer.d
+--- a2k-org/a2k_src/import/SDL_mixer.d 2006-07-26 23:24:04.000000000 +0200
++++ a2k/a2k_src/import/SDL_mixer.d 2004-05-08 14:09:18.000000000 +0200
+@@ -24,7 +24,7 @@
+
+ /* $Id: SDL_mixer.h,v 1.24 2002/05/21 05:45:59 slouken Exp $ */
+
+-public import SDL;
++import SDL;
+
+ extern (C) {
+
+diff -Naur a2k-org/a2k_src/import/SDL_mouse.d a2k/a2k_src/import/SDL_mouse.d
+--- a2k-org/a2k_src/import/SDL_mouse.d 2006-07-26 23:25:18.000000000 +0200
++++ a2k/a2k_src/import/SDL_mouse.d 2004-05-08 12:50:44.000000000 +0200
+@@ -22,8 +22,8 @@
+
+ /* Include file for SDL mouse event handling */
+
+-public import SDL_types;
+-public import SDL_video;
++import SDL_types;
++import SDL_video;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_mutex.d a2k/a2k_src/import/SDL_mutex.d
+--- a2k-org/a2k_src/import/SDL_mutex.d 2006-07-26 23:25:20.000000000 +0200
++++ a2k/a2k_src/import/SDL_mutex.d 2002-01-04 15:36:58.000000000 +0100
+@@ -25,7 +25,7 @@
+ These are independent of the other SDL routines.
+ */
+
+-public import SDL_types;
++import SDL_types;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_quit.d a2k/a2k_src/import/SDL_quit.d
+--- a2k-org/a2k_src/import/SDL_quit.d 2006-07-26 23:25:22.000000000 +0200
++++ a2k/a2k_src/import/SDL_quit.d 2003-12-04 04:03:56.000000000 +0100
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL quit event handling */
+
+-public import SDL_events;
++import SDL_events;
+
+ /*
+ An SDL_QUITEVENT is generated when the user tries to close the application
+diff -Naur a2k-org/a2k_src/import/SDL_rwops.d a2k/a2k_src/import/SDL_rwops.d
+--- a2k-org/a2k_src/import/SDL_rwops.d 2006-07-26 23:25:24.000000000 +0200
++++ a2k/a2k_src/import/SDL_rwops.d 2003-12-04 04:11:24.000000000 +0100
+@@ -24,7 +24,7 @@
+ data sources. It can easily be extended to files, memory, etc.
+ */
+
+-public import SDL_types;
++import SDL_types;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_sound.d a2k/a2k_src/import/SDL_sound.d
+--- a2k-org/a2k_src/import/SDL_sound.d 2006-07-26 23:25:26.000000000 +0200
++++ a2k/a2k_src/import/SDL_sound.d 2004-05-08 14:09:58.000000000 +0200
+@@ -62,7 +62,7 @@
+
+ // convert to D by shinichiro.h
+
+-public import SDL;
++import SDL;
+
+ extern (C) {
+ const int SOUND_VER_MAJOR = 1;
+diff -Naur a2k-org/a2k_src/import/SDL_syswm.d a2k/a2k_src/import/SDL_syswm.d
+--- a2k-org/a2k_src/import/SDL_syswm.d 2006-07-26 23:25:32.000000000 +0200
++++ a2k/a2k_src/import/SDL_syswm.d 2004-01-03 16:10:50.000000000 +0100
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-public import SDL_Version;
++import SDL_Version;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_thread.d a2k/a2k_src/import/SDL_thread.d
+--- a2k-org/a2k_src/import/SDL_thread.d 2006-07-26 23:25:36.000000000 +0200
++++ a2k/a2k_src/import/SDL_thread.d 2002-01-04 15:40:06.000000000 +0100
+@@ -25,8 +25,8 @@
+ These are independent of the other SDL routines.
+ */
+
+-public import SDL_types;
+-public import SDL_mutex;
++import SDL_types;
++import SDL_mutex;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_timer.d a2k/a2k_src/import/SDL_timer.d
+--- a2k-org/a2k_src/import/SDL_timer.d 2006-07-26 23:25:38.000000000 +0200
++++ a2k/a2k_src/import/SDL_timer.d 2002-01-04 15:21:04.000000000 +0100
+@@ -20,7 +20,7 @@
+ slouken@devolution.com
+ */
+
+-public import SDL_types;
++import SDL_types;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/import/SDL_version.d a2k/a2k_src/import/SDL_version.d
+--- a2k-org/a2k_src/import/SDL_version.d 2006-07-26 23:25:40.000000000 +0200
++++ a2k/a2k_src/import/SDL_version.d 1970-01-01 01:00:00.000000000 +0100
+@@ -1,75 +0,0 @@
+-/*
+- SDL - Simple DirectMedia Layer
+- Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
+-
+- This library is free software; you can redistribute it and/or
+- modify it under the terms of the GNU Library General Public
+- License as published by the Free Software Foundation; either
+- version 2 of the License, or (at your option) any later version.
+-
+- This library is distributed in the hope that it will be useful,
+- but WITHOUT ANY WARRANTY; without even the implied warranty of
+- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+- Library General Public License for more details.
+-
+- You should have received a copy of the GNU Library General Public
+- License along with this library; if not, write to the Free
+- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+-
+- Sam Lantinga
+- slouken@devolution.com
+-*/
+-
+-/* This header defines the current SDL version */
+-
+-public import SDL_types;
+-
+-extern(C):
+-
+-/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
+-*/
+-const uint SDL_MAJOR_VERSION = 1;
+-const uint SDL_MINOR_VERSION = 2;
+-const uint SDL_PATCHLEVEL = 6;
+-
+-struct SDL_version {
+- Uint8 major;
+- Uint8 minor;
+- Uint8 patch;
+-}
+-
+-/* This macro can be used to fill a version structure with the compile-time
+- * version of the SDL library.
+- */
+-void SDL_VERSION(SDL_version* X)
+-{
+- X.major = SDL_MAJOR_VERSION;
+- X.minor = SDL_MINOR_VERSION;
+- X.patch = SDL_PATCHLEVEL;
+-}
+-
+-/* This macro turns the version numbers into a numeric value:
+- (1,2,3) -> (1203)
+- This assumes that there will never be more than 100 patchlevels
+-*/
+-uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
+-{
+- return X * 1000 + Y * 100 + Z;
+-}
+-
+-/* This is the version number macro for the current SDL version */
+-const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
+- SDL_MINOR_VERSION * 100 +
+- SDL_PATCHLEVEL;
+-
+-/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
+-bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
+-{
+- return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
+-}
+-
+-/* This function gets the version of the dynamically linked SDL library.
+- it should NOT be used to fill a version structure, instead you should
+- use the SDL_Version() macro.
+- */
+-SDL_version * SDL_Linked_Version();
+diff -Naur a2k-org/a2k_src/import/SDL_Version.d a2k/a2k_src/import/SDL_Version.d
+--- a2k-org/a2k_src/import/SDL_Version.d 1970-01-01 01:00:00.000000000 +0100
++++ a2k/a2k_src/import/SDL_Version.d 2008-10-07 10:47:18.000000000 +0200
+@@ -0,0 +1,75 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* This header defines the current SDL version */
++
++import SDL_types;
++
++extern(C):
++
++/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
++*/
++const uint SDL_MAJOR_VERSION = 1;
++const uint SDL_MINOR_VERSION = 2;
++const uint SDL_PATCHLEVEL = 6;
++
++struct SDL_version {
++ Uint8 major;
++ Uint8 minor;
++ Uint8 patch;
++}
++
++/* This macro can be used to fill a version structure with the compile-time
++ * version of the SDL library.
++ */
++void SDL_VERSION(SDL_version* X)
++{
++ X.major = SDL_MAJOR_VERSION;
++ X.minor = SDL_MINOR_VERSION;
++ X.patch = SDL_PATCHLEVEL;
++}
++
++/* This macro turns the version numbers into a numeric value:
++ (1,2,3) -> (1203)
++ This assumes that there will never be more than 100 patchlevels
++*/
++uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return X * 1000 + Y * 100 + Z;
++}
++
++/* This is the version number macro for the current SDL version */
++const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
++ SDL_MINOR_VERSION * 100 +
++ SDL_PATCHLEVEL;
++
++/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
++bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
++}
++
++/* This function gets the version of the dynamically linked SDL library.
++ it should NOT be used to fill a version structure, instead you should
++ use the SDL_Version() macro.
++ */
++SDL_version * SDL_Linked_Version();
+diff -Naur a2k-org/a2k_src/import/SDL_video.d a2k/a2k_src/import/SDL_video.d
+--- a2k-org/a2k_src/import/SDL_video.d 2006-07-26 23:25:42.000000000 +0200
++++ a2k/a2k_src/import/SDL_video.d 2002-05-22 07:45:40.000000000 +0200
+@@ -22,9 +22,9 @@
+
+ /* Header file for access to the SDL raw framebuffer window */
+
+-public import SDL_types;
+-public import SDL_mutex;
+-public import SDL_rwops;
++import SDL_types;
++import SDL_mutex;
++import SDL_rwops;
+
+ extern(C):
+
+diff -Naur a2k-org/a2k_src/src/bg.d a2k/a2k_src/src/bg.d
+--- a2k-org/a2k_src/src/bg.d 2005-01-18 00:34:48.000000000 +0100
++++ a2k/a2k_src/src/bg.d 2008-10-07 09:53:28.000000000 +0200
+@@ -14,7 +14,12 @@
+ private import util_snd;
+ private import define;
+ private import task;
+-private import stg;
++private import stg;
++private import stg01;
++private import stg02;
++private import stg03;
++private import stg04;
++private import stg05;
+ private import effect;
+ private import ship;
+
+@@ -79,20 +84,20 @@
+ TskBuf[fade_id].tx = 1.0f;
+ TskBuf[fade_id].wait = 60;
+ TskBuf[fade_id].step = 2;
+- TskBuf[id].px = cast(float)(rand() % 1536 - 768.0f);
++ TskBuf[id].px = cast(float)(rand() % 1536 - 768.0f);
+ TskBuf[id].py = cast(float)(rand() % 1536 - 768.0f);
+ if((rand() % 100) & 0x01){
+ if(TskBuf[id].px < 0.0f){
+ TskBuf[id].tx = +(cast(float)(rand() % 768));
+ }else{
+- TskBuf[id].tx = -(cast(float)(rand() % 768));
++ TskBuf[id].tx = +(cast(float)(rand() % 768));
+ }
+ TskBuf[id].ty = TskBuf[id].py;
+ }else{
+ if(TskBuf[id].py < 0.0f){
+ TskBuf[id].ty = +(cast(float)(rand() % 768));
+ }else{
+- TskBuf[id].ty = -(cast(float)(rand() % 768));
++ TskBuf[id].ty = +(cast(float)(rand() % 768));
+ }
+ TskBuf[id].tx = TskBuf[id].px;
+ }
+@@ -104,7 +109,7 @@
+ cam_pos = BASE_Z + cam_scr;
+ eid = setTSK(GROUP_08,&TSKbgZoom);
+ TskBuf[eid].wait = 600;
+- TskBuf[eid].tx = BASE_Z - (cast(float)((rand() % 5000) - 2500 + 10000) / 10000.0f);
++ TskBuf[eid].tx = BASE_Z - ((cast(float)(rand() % 5000) - 2500 + 10000) / 10000.0f);
+ TskBuf[id].step++;
+ break;
+ case 2:
+@@ -202,22 +207,34 @@
+ scr_base[Y] = START_Y;
+ scr_ofs[X] = 0.0f;
+ scr_ofs[Y] = 0.0f;
+- cam_pos = BASE_Z + cam_scr;
++ cam_pos = BASE_Z + cam_scr;
++ bg_mode = 0;
++ stg_ctrl = STG_MAIN;
+ switch(area_num){
+ case AREA_01:
+- bg_mode = 0;
++ bg_mode = 0;
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg01);
+ break;
+ case AREA_02:
+- bg_mode = 1;
++ bg_mode = 1;
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg02);
+ break;
+ case AREA_03:
+- bg_mode = 2;
++ bg_mode = 2;
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg03);
+ break;
+ case AREA_04:
+- bg_mode = 3;
++ bg_mode = 3;
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg04);
+ break;
+ case AREA_05:
+- bg_mode = 4;
++ bg_mode = 4;
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg05);
+ break;
+ default:
+ break;
+@@ -296,7 +313,7 @@
+ bg_obj[i].line_list.length = 1;
+ bg_obj[i].line_list[0][X] = +0.0f;
+ bg_obj[i].line_list[0][Y] = +0.0f;
+- bg_obj[i].line_list[0][Z] = -(cast(float)(rand() % 75)) / 100.0f + 0.25f;
++ bg_obj[i].line_list[0][Z] = -cast(float)(rand() % 75) / 100.0f + 0.25f;
+ }
+ break;
+ case 4:
+@@ -600,8 +617,8 @@
+ break;
+ case 1:
+ if(TskBuf[id].wait){
+- TskBuf[id].px = ((rand() % (256.0f * TskBuf[id].vx)) - ((256.0f * TskBuf[id].vx) / 2)) / 256.0f;
+- TskBuf[id].py = ((rand() % (256.0f * TskBuf[id].vy)) - ((256.0f * TskBuf[id].vy) / 2)) / 256.0f;
++ TskBuf[id].px = (cast(float)(rand() % (256.0f * TskBuf[id].vx)) - ((256.0f * TskBuf[id].vx) / 2)) / 256.0f;
++ TskBuf[id].py = (cast(float)(rand() % (256.0f * TskBuf[id].vy)) - ((256.0f * TskBuf[id].vy) / 2)) / 256.0f;
+ TskBuf[id].vx += (0.0f - TskBuf[id].vx) / TskBuf[id].cnt;
+ TskBuf[id].vy += (0.0f - TskBuf[id].vy) / TskBuf[id].cnt;
+ scr_ofs[X] = TskBuf[id].px;
+diff -Naur a2k-org/a2k_src/src/boss01.d a2k/a2k_src/src/boss01.d
+--- a2k-org/a2k_src/src/boss01.d 2008-02-06 01:34:54.000000000 +0100
++++ a2k/a2k_src/src/boss01.d 2008-10-07 09:57:49.000000000 +0200
+@@ -7,7 +7,7 @@
+ */
+
+ private import std.stdio;
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/boss02.d a2k/a2k_src/src/boss02.d
+--- a2k-org/a2k_src/src/boss02.d 2008-02-06 01:35:18.000000000 +0100
++++ a2k/a2k_src/src/boss02.d 2008-10-07 09:58:18.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/04/16 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/boss03.d a2k/a2k_src/src/boss03.d
+--- a2k-org/a2k_src/src/boss03.d 2008-02-06 01:35:30.000000000 +0100
++++ a2k/a2k_src/src/boss03.d 2008-10-07 09:58:28.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/08 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+@@ -358,7 +358,7 @@
+ }
+ if(!cmd.isEnd()) cmd.run();
+ break;
+- TskBuf[id].ang_x = rand() % 65536;
++ TskBuf[id].ang_x = cast(float)rand() % 65536;
+ TskBuf[id].ang_x *= PI / 65536.0f;
+ TskBuf[id].ax =
+ TskBuf[id].ay = sin(TskBuf[id].ang_x) * 5.0f / PI;
+diff -Naur a2k-org/a2k_src/src/boss04.d a2k/a2k_src/src/boss04.d
+--- a2k-org/a2k_src/src/boss04.d 2008-02-06 01:35:34.000000000 +0100
++++ a2k/a2k_src/src/boss04.d 2008-10-07 09:58:35.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/06 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/boss05.d a2k/a2k_src/src/boss05.d
+--- a2k-org/a2k_src/src/boss05.d 2008-02-06 01:35:38.000000000 +0100
++++ a2k/a2k_src/src/boss05.d 2008-10-07 09:58:43.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/09 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/bulletcommand.d a2k/a2k_src/src/bulletcommand.d
+--- a2k-org/a2k_src/src/bulletcommand.d 2008-02-06 01:37:56.000000000 +0100
++++ a2k/a2k_src/src/bulletcommand.d 2008-10-07 09:53:28.000000000 +0200
+@@ -247,7 +247,7 @@
+ double getRand_(BulletMLRunner* runner){
+ double rand_val;
+ //printf("getRand_(%d)\n",BulletCommand.now.id);
+- rand_val = rand() % 10000;
++ rand_val = cast(float)rand() % 10000;
+ rand_val /= 10000;
+ return rand_val;
+ }
+diff -Naur a2k-org/a2k_src/src/effect.d a2k/a2k_src/src/effect.d
+--- a2k-org/a2k_src/src/effect.d 2008-02-06 01:35:40.000000000 +0100
++++ a2k/a2k_src/src/effect.d 2008-10-07 10:03:12.000000000 +0200
+@@ -6,14 +6,15 @@
+ 2004/03/31 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+ private import opengl;
+ private import util_sdl;
+ private import task;
+-private import bg;
++private import bg;
++private import system;
+
+ float fade_r = 0.0f;
+ float fade_g = 0.0f;
+@@ -53,16 +54,16 @@
+ for(int i = 0; i < 3; i++){
+ switch(i){
+ case 0:
+- tpos[X] = -((rand() % 4096) / 1024.0f + 1.0f);
+- tpos[Y] = +((rand() % 4096) / 1024.0f + 1.0f);
++ tpos[X] = -cast(float)((rand() % 4096) / 1024.0f + 1.0f);
++ tpos[Y] = +cast(float)((rand() % 4096) / 1024.0f + 1.0f);
+ break;
+ case 1:
+- tpos[X] = ((rand() % 2048) / 1024.0f - 1.0f);
+- tpos[Y] = -((rand() % 4096) / 1024.0f + 1.0f);
++ tpos[X] = cast(float)((rand() % 2048) / 1024.0f - 1.0f);
++ tpos[Y] = -cast(float)((rand() % 4096) / 1024.0f + 1.0f);
+ break;
+ case 2:
+- tpos[X] = +((rand() % 4096) / 1024.0f + 1.0f);
+- tpos[Y] = +((rand() % 4096) / 1024.0f + 1.0f);
++ tpos[X] = +cast(float)((rand() % 4096) / 1024.0f + 1.0f);
++ tpos[Y] = +cast(float)((rand() % 4096) / 1024.0f + 1.0f);
+ break;
+ default:
+ break;
+@@ -74,8 +75,8 @@
+ tpos[Y] = fabs(tpos[Y]);
+ TskBuf[id].body_ang[i][W] = sqrt(pow(tpos[X],2.0) + pow(tpos[Y],2.0));
+ }
+- TskBuf[id].tx = (rand() % 256000) / 1000.0f - 128.0f;
+- TskBuf[id].ty = (rand() % 256000) / 1000.0f - 128.0f;
++ TskBuf[id].tx = cast(float)(rand() % 256000) / 1000.0f - 128.0f;
++ TskBuf[id].ty = cast(float)(rand() % 256000) / 1000.0f - 128.0f;
+ TskBuf[id].tx += TskBuf[id].px;
+ TskBuf[id].ty += TskBuf[id].py;
+ TskBuf[id].wait = 60;
+@@ -165,16 +166,16 @@
+ for(int i = 0; i < 3; i++){
+ switch(i){
+ case 0:
+- tpos[X] = -((rand() % 12288) / 1024.0f + 3.0f);
+- tpos[Y] = +((rand() % 12288) / 1024.0f + 3.0f);
++ tpos[X] = -(cast(float)(rand() % 12288) / 1024.0f + 3.0f);
++ tpos[Y] = +(cast(float)(rand() % 12288) / 1024.0f + 3.0f);
+ break;
+ case 1:
+- tpos[X] = ((rand() % 6144) / 1024.0f - 3.0f);
+- tpos[Y] = -((rand() % 12288) / 1024.0f + 3.0f);
++ tpos[X] = (cast(float)(rand() % 6144) / 1024.0f - 3.0f);
++ tpos[Y] = -(cast(float)(rand() % 12288) / 1024.0f + 3.0f);
+ break;
+ case 2:
+- tpos[X] = +((rand() % 12288) / 1024.0f + 3.0f);
+- tpos[Y] = +((rand() % 12288) / 1024.0f + 3.0f);
++ tpos[X] = +(cast(float)(rand() % 12288) / 1024.0f + 3.0f);
++ tpos[Y] = +(cast(float)(rand() % 12288) / 1024.0f + 3.0f);
+ break;
+ default:
+ break;
+@@ -186,8 +187,8 @@
+ tpos[Y] = fabs(tpos[Y]);
+ TskBuf[id].body_ang[i][W] = sqrt(pow(tpos[X],2.0) + pow(tpos[Y],2.0));
+ }
+- TskBuf[id].tx = (rand() % 512000) / 1000.0f - 256.0f;
+- TskBuf[id].ty = (rand() % 512000) / 1000.0f - 256.0f;
++ TskBuf[id].tx = cast(float)(rand() % 512000) / 1000.0f - 256.0f;
++ TskBuf[id].ty = cast(float)(rand() % 512000) / 1000.0f - 256.0f;
+ TskBuf[id].tx += TskBuf[id].px;
+ TskBuf[id].ty += TskBuf[id].py;
+ TskBuf[id].wait = 60;
+@@ -279,13 +280,13 @@
+ TskBuf[id].fp_draw = &TSKBrokenBodyDraw;
+ TskBuf[id].fp_exit = &TSKBrokenBodyExit;
+ TskBuf[id].alpha = 1.0f;
+- TskBuf[id].tx = (rand() % 256000) / 1000.0f - 128.0f;
+- TskBuf[id].ty = (rand() % 256000) / 1000.0f - 128.0f;
++ TskBuf[id].tx = cast(float)(rand() % 256000) / 1000.0f - 128.0f;
++ TskBuf[id].ty = cast(float)(rand() % 256000) / 1000.0f - 128.0f;
+ TskBuf[id].tx *= 2.0f;
+ TskBuf[id].ty *= 2.0f;
+ TskBuf[id].tx += TskBuf[id].px;
+ TskBuf[id].ty += TskBuf[id].py;
+- TskBuf[id].rot_add = (rand % 30) - 15;
++ TskBuf[id].rot_add = cast(float)(rand % 30) - 15;
+ if(!(TskBuf[id].rot_add - 15)) TskBuf[id].rot_add = -1;
+ else if(!(TskBuf[id].rot_add + 15)) TskBuf[id].rot_add = +1;
+ if(TskBuf[id].rot_add < 0) TskBuf[id].rot_add = PI / (TskBuf[id].rot_add - 15);
+@@ -410,13 +411,13 @@
+ TskBuf[id].fp_draw = &TSKBrokenLineDraw;
+ TskBuf[id].fp_exit = &TSKBrokenLineExit;
+ TskBuf[id].alpha = 1.0f;
+- TskBuf[id].tx = (rand() % 256000) / 1000.0f - 128.0f;
+- TskBuf[id].ty = (rand() % 256000) / 1000.0f - 128.0f;
++ TskBuf[id].tx = cast(float)(rand() % 256000) / 1000.0f - 128.0f;
++ TskBuf[id].ty = cast(float)(rand() % 256000) / 1000.0f - 128.0f;
+ TskBuf[id].tx *= 2.0f;
+ TskBuf[id].ty *= 2.0f;
+ TskBuf[id].tx += TskBuf[id].px;
+ TskBuf[id].ty += TskBuf[id].py;
+- TskBuf[id].rot_add = (rand % 30) - 15;
++ TskBuf[id].rot_add = cast(float)(rand % 30) - 15;
+ if(!(TskBuf[id].rot_add - 15)) TskBuf[id].rot_add = -1;
+ else if(!(TskBuf[id].rot_add + 15)) TskBuf[id].rot_add = +1;
+ if(TskBuf[id].rot_add < 0) TskBuf[id].rot_add = PI / (TskBuf[id].rot_add - 15);
+diff -Naur a2k-org/a2k_src/src/enemy01.d a2k/a2k_src/src/enemy01.d
+--- a2k-org/a2k_src/src/enemy01.d 2008-02-06 01:35:46.000000000 +0100
++++ a2k/a2k_src/src/enemy01.d 2008-10-07 10:03:51.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/03/27 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -63,8 +63,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy01Draw;
+ TskBuf[id].fp_exit = &TSKenemy01Exit;
+diff -Naur a2k-org/a2k_src/src/enemy02.d a2k/a2k_src/src/enemy02.d
+--- a2k-org/a2k_src/src/enemy02.d 2008-02-06 01:35:48.000000000 +0100
++++ a2k/a2k_src/src/enemy02.d 2008-10-07 10:04:05.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/04/11 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -63,8 +63,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy02Draw;
+ TskBuf[id].fp_exit = &TSKenemy02Exit;
+diff -Naur a2k-org/a2k_src/src/enemy03.d a2k/a2k_src/src/enemy03.d
+--- a2k-org/a2k_src/src/enemy03.d 2008-02-06 01:35:52.000000000 +0100
++++ a2k/a2k_src/src/enemy03.d 2008-10-07 10:04:19.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/04/11 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -63,8 +63,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].tid = ship_id;
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy03Draw;
+diff -Naur a2k-org/a2k_src/src/enemy04.d a2k/a2k_src/src/enemy04.d
+--- a2k-org/a2k_src/src/enemy04.d 2008-02-06 01:35:56.000000000 +0100
++++ a2k/a2k_src/src/enemy04.d 2008-10-07 10:05:41.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/04/11 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -53,8 +53,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].tid = ship_id;
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy04Draw;
+@@ -132,14 +132,14 @@
+ TskBuf[id].vx = TskBuf[id].px;
+ TskBuf[id].vy = TskBuf[id].py;
+ if(!TskBuf[id].cnt){
+- TskBuf[id].tx = (rand() % 512) + 256.0f;
+- TskBuf[id].ty = (rand() % 512) + 256.0f;
++ TskBuf[id].tx = cast(float)(rand() % 512) + 256.0f;
++ TskBuf[id].ty = cast(float)(rand() % 512) + 256.0f;
+ if(TskBuf[id].px < ship_px) TskBuf[id].tx = +TskBuf[id].tx;
+ else TskBuf[id].tx = -TskBuf[id].tx;
+ if(TskBuf[id].py < ship_py) TskBuf[id].ty = +TskBuf[id].ty;
+ else TskBuf[id].ty = -TskBuf[id].ty;
+- if((rand() % 100) > 97) TskBuf[id].tx = -TskBuf[id].tx;
+- if((rand() % 100) > 97) TskBuf[id].ty = -TskBuf[id].ty;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].tx = -TskBuf[id].tx;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].ty = -TskBuf[id].ty;
+ TskBuf[id].tx = TskBuf[id].px + TskBuf[id].tx;
+ TskBuf[id].ty = TskBuf[id].py + TskBuf[id].ty;
+ if(TskBuf[id].tx < -ENEMY_AREAMAX) TskBuf[id].tx = -ENEMY_AREAMAX + 1.0f;
+diff -Naur a2k-org/a2k_src/src/enemy05.d a2k/a2k_src/src/enemy05.d
+--- a2k-org/a2k_src/src/enemy05.d 2008-02-06 01:35:58.000000000 +0100
++++ a2k/a2k_src/src/enemy05.d 2008-10-07 10:08:43.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/05/30 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -53,8 +53,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].tid = ship_id;
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy05Draw;
+@@ -127,42 +127,31 @@
+ }
+ }
+ /* 座標更新 */
+- if(TskBuf[id].px < ship_px){
+- if(TskBuf[id].vx > +0.0f) TskBuf[id].vx += 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vx += 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vx > +MAX_SPEED) TskBuf[id].vx = +MAX_SPEED;
+- }else{
+- if(TskBuf[id].vx < +0.0f) TskBuf[id].vx -= 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vx -= 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vx < -MAX_SPEED) TskBuf[id].vx = -MAX_SPEED;
+- }
+- if(TskBuf[id].py < ship_py){
+- if(TskBuf[id].vy > +0.0f) TskBuf[id].vy += 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vy += 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vy > +MAX_SPEED) TskBuf[id].vy = +MAX_SPEED;
+- }else{
+- if(TskBuf[id].vy < +0.0f) TskBuf[id].vy -= 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vy -= 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vy < -MAX_SPEED) TskBuf[id].vy = -MAX_SPEED;
+- }
+- TskBuf[id].px += TskBuf[id].vx;
+- TskBuf[id].py += TskBuf[id].vy;
+- if(TskBuf[id].px < -ENEMY_AREAMAX){
+- TskBuf[id].px = -ENEMY_AREAMAX;
+- TskBuf[id].vx = -TskBuf[id].vx / 2;
+- }
+- if(TskBuf[id].px > +ENEMY_AREAMAX){
+- TskBuf[id].px = +ENEMY_AREAMAX;
+- TskBuf[id].vx = -TskBuf[id].vx / 2;
+- }
+- if(TskBuf[id].py < -ENEMY_AREAMAX){
+- TskBuf[id].py = -ENEMY_AREAMAX;
+- TskBuf[id].vy = -TskBuf[id].vy / 2;
+- }
+- if(TskBuf[id].py > +ENEMY_AREAMAX){
+- TskBuf[id].py = +ENEMY_AREAMAX;
+- TskBuf[id].vy = -TskBuf[id].vy / 2;
+- }
++ TskBuf[id].vx = TskBuf[id].px;
++ TskBuf[id].vy = TskBuf[id].py;
++ if(!TskBuf[id].cnt){
++ TskBuf[id].tx = cast(float)(rand() % 512) + 256.0f;
++ TskBuf[id].ty = cast(float)(rand() % 512) + 256.0f;
++ if(TskBuf[id].px < ship_px) TskBuf[id].tx = +TskBuf[id].tx;
++ else TskBuf[id].tx = -TskBuf[id].tx;
++ if(TskBuf[id].py < ship_py) TskBuf[id].ty = +TskBuf[id].ty;
++ else TskBuf[id].ty = -TskBuf[id].ty;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].tx = -TskBuf[id].tx;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].ty = -TskBuf[id].ty;
++ TskBuf[id].tx = TskBuf[id].px + TskBuf[id].tx;
++ TskBuf[id].ty = TskBuf[id].py + TskBuf[id].ty;
++ if(TskBuf[id].tx < -ENEMY_AREAMAX) TskBuf[id].tx = -ENEMY_AREAMAX + 1.0f;
++ if(TskBuf[id].tx > +ENEMY_AREAMAX) TskBuf[id].tx = +ENEMY_AREAMAX - 1.0f;
++ if(TskBuf[id].ty < -ENEMY_AREAMAX) TskBuf[id].ty = -ENEMY_AREAMAX + 1.0f;
++ if(TskBuf[id].ty > +ENEMY_AREAMAX) TskBuf[id].ty = +ENEMY_AREAMAX - 1.0f;
++ TskBuf[id].cnt = 180;
++ }else{
++ TskBuf[id].cnt--;
++ }
++ TskBuf[id].px += (TskBuf[id].tx - TskBuf[id].px) / (180 / 4);
++ TskBuf[id].py += (TskBuf[id].ty - TskBuf[id].py) / (180 / 4);
++ TskBuf[id].vx -= TskBuf[id].px;
++ TskBuf[id].vy -= TskBuf[id].py;
+ TskBuf[id].rot = atan2(-TskBuf[id].vx, -TskBuf[id].vy);
+ break;
+ default:
+diff -Naur a2k-org/a2k_src/src/enemy06.d a2k/a2k_src/src/enemy06.d
+--- a2k-org/a2k_src/src/enemy06.d 2008-02-06 01:36:00.000000000 +0100
++++ a2k/a2k_src/src/enemy06.d 2008-10-07 10:10:11.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/04 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -65,8 +65,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].tid = ship_id;
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy06Draw;
+@@ -145,14 +145,14 @@
+ TskBuf[id].vx = TskBuf[id].px;
+ TskBuf[id].vy = TskBuf[id].py;
+ if(TskBuf[id].cnt == TskBuf[id].mov_cnt){
+- TskBuf[id].tx = (rand() % 512) + 256.0f;
+- TskBuf[id].ty = (rand() % 512) + 256.0f;
++ TskBuf[id].tx = cast(float)(rand() % 512) + 256.0f;
++ TskBuf[id].ty = cast(float)(rand() % 512) + 256.0f;
+ if(TskBuf[id].px < ship_px) TskBuf[id].tx = +TskBuf[id].tx;
+ else TskBuf[id].tx = -TskBuf[id].tx;
+ if(TskBuf[id].py < ship_py) TskBuf[id].ty = +TskBuf[id].ty;
+ else TskBuf[id].ty = -TskBuf[id].ty;
+- if((rand() % 100) > 97) TskBuf[id].tx = -TskBuf[id].tx;
+- if((rand() % 100) > 97) TskBuf[id].ty = -TskBuf[id].ty;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].tx = -TskBuf[id].tx;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].ty = -TskBuf[id].ty;
+ TskBuf[id].tx = TskBuf[id].px + TskBuf[id].tx;
+ TskBuf[id].ty = TskBuf[id].py + TskBuf[id].ty;
+ if(TskBuf[id].tx < -ENEMY_AREAMAX) TskBuf[id].tx = -ENEMY_AREAMAX + 1.0f;
+diff -Naur a2k-org/a2k_src/src/enemy07.d a2k/a2k_src/src/enemy07.d
+--- a2k-org/a2k_src/src/enemy07.d 2008-02-06 01:36:02.000000000 +0100
++++ a2k/a2k_src/src/enemy07.d 2008-10-07 10:11:42.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/05 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -63,8 +63,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].tid = ship_id;
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy07Draw;
+@@ -137,42 +137,31 @@
+ }
+ }
+ /* 座標更新 */
+- if(TskBuf[id].px < ship_px){
+- if(TskBuf[id].vx > +0.0f) TskBuf[id].vx += 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vx += 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vx > +MAX_SPEED) TskBuf[id].vx = +MAX_SPEED;
+- }else{
+- if(TskBuf[id].vx < +0.0f) TskBuf[id].vx -= 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vx -= 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vx < -MAX_SPEED) TskBuf[id].vx = -MAX_SPEED;
+- }
+- if(TskBuf[id].py < ship_py){
+- if(TskBuf[id].vy > +0.0f) TskBuf[id].vy += 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vy += 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vy > +MAX_SPEED) TskBuf[id].vy = +MAX_SPEED;
+- }else{
+- if(TskBuf[id].vy < +0.0f) TskBuf[id].vy -= 1.0f / SPEED_RATE * 2.0f;
+- else TskBuf[id].vy -= 1.0f / SPEED_RATE * 1.5f;
+- if(TskBuf[id].vy < -MAX_SPEED) TskBuf[id].vy = -MAX_SPEED;
+- }
+- TskBuf[id].px += TskBuf[id].vx;
+- TskBuf[id].py += TskBuf[id].vy;
+- if(TskBuf[id].px < -ENEMY_AREAMAX){
+- TskBuf[id].px = -ENEMY_AREAMAX;
+- TskBuf[id].vx = -TskBuf[id].vx / 2;
+- }
+- if(TskBuf[id].px > +ENEMY_AREAMAX){
+- TskBuf[id].px = +ENEMY_AREAMAX;
+- TskBuf[id].vx = -TskBuf[id].vx / 2;
+- }
+- if(TskBuf[id].py < -ENEMY_AREAMAX){
+- TskBuf[id].py = -ENEMY_AREAMAX;
+- TskBuf[id].vy = -TskBuf[id].vy / 2;
+- }
+- if(TskBuf[id].py > +ENEMY_AREAMAX){
+- TskBuf[id].py = +ENEMY_AREAMAX;
+- TskBuf[id].vy = -TskBuf[id].vy / 2;
+- }
++ TskBuf[id].vx = TskBuf[id].px;
++ TskBuf[id].vy = TskBuf[id].py;
++ if(!TskBuf[id].cnt){
++ TskBuf[id].tx = cast(float)(rand() % 512) + 256.0f;
++ TskBuf[id].ty = cast(float)(rand() % 512) + 256.0f;
++ if(TskBuf[id].px < ship_px) TskBuf[id].tx = +TskBuf[id].tx;
++ else TskBuf[id].tx = -TskBuf[id].tx;
++ if(TskBuf[id].py < ship_py) TskBuf[id].ty = +TskBuf[id].ty;
++ else TskBuf[id].ty = -TskBuf[id].ty;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].tx = -TskBuf[id].tx;
++ if(cast(float)(rand() % 100) > 97) TskBuf[id].ty = -TskBuf[id].ty;
++ TskBuf[id].tx = TskBuf[id].px + TskBuf[id].tx;
++ TskBuf[id].ty = TskBuf[id].py + TskBuf[id].ty;
++ if(TskBuf[id].tx < -ENEMY_AREAMAX) TskBuf[id].tx = -ENEMY_AREAMAX + 1.0f;
++ if(TskBuf[id].tx > +ENEMY_AREAMAX) TskBuf[id].tx = +ENEMY_AREAMAX - 1.0f;
++ if(TskBuf[id].ty < -ENEMY_AREAMAX) TskBuf[id].ty = -ENEMY_AREAMAX + 1.0f;
++ if(TskBuf[id].ty > +ENEMY_AREAMAX) TskBuf[id].ty = +ENEMY_AREAMAX - 1.0f;
++ TskBuf[id].cnt = 180;
++ }else{
++ TskBuf[id].cnt--;
++ }
++ TskBuf[id].px += (TskBuf[id].tx - TskBuf[id].px) / (180 / 4);
++ TskBuf[id].py += (TskBuf[id].ty - TskBuf[id].py) / (180 / 4);
++ TskBuf[id].vx -= TskBuf[id].px;
++ TskBuf[id].vy -= TskBuf[id].py;
+ TskBuf[id].rot = atan2(-TskBuf[id].vx, -TskBuf[id].vy);
+ break;
+ default:
+diff -Naur a2k-org/a2k_src/src/enemy08.d a2k/a2k_src/src/enemy08.d
+--- a2k-org/a2k_src/src/enemy08.d 2008-02-06 01:36:04.000000000 +0100
++++ a2k/a2k_src/src/enemy08.d 2008-10-07 10:11:52.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/05 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import SDL;
+ private import opengl;
+@@ -65,8 +65,8 @@
+ switch(TskBuf[id].step){
+ case 0:
+ TskBuf[id].tskid |= TSKID_ZAKO;
+- TskBuf[id].px = (rand() % 1536) - 768.0f;
+- TskBuf[id].py = (rand() % 1536) - 768.0f;
++ TskBuf[id].px = (cast(float)(rand() % 1536) - 768.0f);
++ TskBuf[id].py = (cast(float)(rand() % 1536) - 768.0f);
+ TskBuf[id].tid = ship_id;
+ TskBuf[id].fp_int = null;
+ TskBuf[id].fp_draw = &TSKenemy08Draw;
+diff -Naur a2k-org/a2k_src/src/enemy.d a2k/a2k_src/src/enemy.d
+--- a2k-org/a2k_src/src/enemy.d 2008-02-06 01:35:42.000000000 +0100
++++ a2k/a2k_src/src/enemy.d 2008-10-07 10:03:38.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/04/14 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import SDL;
+ private import opengl;
+ private import util_sdl;
+@@ -158,6 +158,7 @@
+ return;
+ }
+
++
+ void TSKeshotInt(int id)
+ {
+ TskBuf[id].step = -1;
+@@ -165,6 +166,7 @@
+ return;
+ }
+
++
+ void TSKeshotDrawSimple(int id)
+ {
+ float[XYZ] pos;
+@@ -198,6 +200,7 @@
+ glEnd();
+ }
+
++
+ void TSKeshotDrawActive(int id)
+ {
+ float[XYZ] pos;
+@@ -231,6 +234,7 @@
+ glEnd();
+ }
+
++
+ void TSKeshotExit(int id)
+ {
+ BulletCommand cmd = TskBuf[id].bullet_command;
+@@ -243,6 +247,7 @@
+ }
+ }
+
++
+ float getShipDirection(int id)
+ {
+ float px,py;
+@@ -257,3 +262,4 @@
+ return dir;
+ }
+
++
+diff -Naur a2k-org/a2k_src/src/init.d a2k/a2k_src/src/init.d
+--- a2k-org/a2k_src/src/init.d 2005-05-19 22:31:30.000000000 +0200
++++ a2k/a2k_src/src/init.d 2008-10-07 09:53:28.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2003/12/01 jumpei isshiki
+ */
+
+-private import std.stdio;
++private import std.c.stdio;
+ private import std.stream;
+ private import util_sdl;
+ private import util_snd;
+@@ -101,7 +101,7 @@
+ fd.open("score.dat");
+ if(fd.size() != 12){
+ fd.close();
+- writefln("score.dat initialized");
++ printf("score.dat initialized");
+ fd.create("score.dat");
+ fd.write(high_easy);
+ fd.write(high_normal);
+@@ -112,7 +112,7 @@
+ fd.read(high_hard);
+ }
+ } catch (Error e) {
+- writefln("score.dat initialized");
++ printf("score.dat initialized");
+ fd.create("score.dat");
+ fd.write(high_easy);
+ fd.write(high_normal);
+@@ -126,7 +126,7 @@
+ try {
+ if(fd.size() != 12){
+ fd.close();
+- writefln("config.dat initialized");
++ printf("config.dat initialized");
+ fd.create("config.dat");
+ fd.write(pad_type);
+ fd.write(vol_se);
+@@ -139,7 +139,7 @@
+ volumeSNDmusic(vol_music);
+ }
+ } catch (Error e) {
+- writefln("config.dat initialized");
++ printf("config.dat initialized");
+ fd.create("config.dat");
+ fd.write(pad_type);
+ fd.write(vol_se);
+diff -Naur a2k-org/a2k_src/src/luminous.d a2k/a2k_src/src/luminous.d
+--- a2k-org/a2k_src/src/luminous.d 2008-02-06 01:39:52.000000000 +0100
++++ a2k/a2k_src/src/luminous.d 2008-10-07 09:53:29.000000000 +0200
+@@ -7,7 +7,7 @@
+ */
+
+ private import std.math;
+-private import std.string;
++private import std.c.string;
+ private import opengl;
+ private import util_sdl;
+ private import task;
+diff -Naur a2k-org/a2k_src/src/main.d a2k/a2k_src/src/main.d
+--- a2k-org/a2k_src/src/main.d 2008-02-07 00:42:58.000000000 +0100
++++ a2k/a2k_src/src/main.d 2008-10-07 10:18:53.000000000 +0200
+@@ -6,8 +6,9 @@
+ 2003/11/28 jumpei isshiki
+ */
+
+-private import std.c.windows.windows;
+-private import SDL;
++//private import std.c.windows.windows;
++private import SDL;
++private import SDL_Keysym;
+ private import opengl;
+ private import util_sdl;
+ private import util_pad;
+@@ -31,25 +32,29 @@
+ int pause = 0;
+ int pause_flag = 0;
+ int skip = 0;
+-
++/*
+ extern (Windows)
+ int WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine, int nCmdShow)
+ {
++*/
++public int main(char[][] args) {
+ int result;
+-
++/*
+ gc_init();
+ _minit();
+
+ try{
+ _moduleCtor();
+- _moduleUnitTests();
++ _moduleUnitTests();
++*/
+ result = boot();
++/*
+ }catch (Object o){
+ MessageBoxA(null, cast(char*)o.toString(), "Error", MB_OK | MB_ICONEXCLAMATION);
+ result = 0;
+ }
+ gc_term();
+-
++*/
+ return result;
+ }
+
+diff -Naur a2k-org/a2k_src/src/middle01.d a2k/a2k_src/src/middle01.d
+--- a2k-org/a2k_src/src/middle01.d 2008-02-06 01:36:06.000000000 +0100
++++ a2k/a2k_src/src/middle01.d 2008-10-07 10:19:15.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/05/05 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/middle02.d a2k/a2k_src/src/middle02.d
+--- a2k-org/a2k_src/src/middle02.d 2008-02-06 01:36:08.000000000 +0100
++++ a2k/a2k_src/src/middle02.d 2008-10-07 10:19:24.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/03 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/middle03.d a2k/a2k_src/src/middle03.d
+--- a2k-org/a2k_src/src/middle03.d 2008-02-06 01:36:12.000000000 +0100
++++ a2k/a2k_src/src/middle03.d 2008-10-07 10:19:32.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/06/07 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/middle04.d a2k/a2k_src/src/middle04.d
+--- a2k-org/a2k_src/src/middle04.d 2008-02-06 01:36:14.000000000 +0100
++++ a2k/a2k_src/src/middle04.d 2008-10-07 10:19:40.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/07/05 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/middle05.d a2k/a2k_src/src/middle05.d
+--- a2k-org/a2k_src/src/middle05.d 2008-02-06 01:36:16.000000000 +0100
++++ a2k/a2k_src/src/middle05.d 2008-10-07 10:19:47.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/07/06 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.random;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/ship.d a2k/a2k_src/src/ship.d
+--- a2k-org/a2k_src/src/ship.d 2008-02-12 23:41:50.000000000 +0100
++++ a2k/a2k_src/src/ship.d 2008-10-07 10:41:21.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2003/12/01 jumpei isshiki
+ */
+
+-private import std.math;
++private import std.c.math;
+ private import std.intrinsic;
+ private import std.random;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/stg.d a2k/a2k_src/src/stg.d
+--- a2k-org/a2k_src/src/stg.d 2005-05-19 22:52:14.000000000 +0200
++++ a2k/a2k_src/src/stg.d 2008-10-07 09:53:29.000000000 +0200
+@@ -91,25 +91,36 @@
+ void TSKstgCtrl(int id)
+ {
+ switch(TskBuf[id].step){
+- case 0:
++ case 0:
+ area_num = AREA_01;
+- scene_num = SCENE_01;
+- debug{
+- //area_num = AREA_02;
+- //area_num = AREA_03;
+- //area_num = AREA_04;
+- //area_num = AREA_05;
+- //scene_num = SCENE_02;
+- //scene_num = SCENE_03;
+- //scene_num = SCENE_04;
+- //scene_num = SCENE_05;
+- //scene_num = SCENE_06;
+- //scene_num = SCENE_07;
+- //scene_num = SCENE_08;
+- //scene_num = SCENE_09;
+- //scene_num = SCENE_10;
+- }
+- stg_bgm = -1;
++ scene_num = SCENE_01;
++
++ switch(area_num){
++ case AREA_01:
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg01);
++ break;
++ case AREA_02:
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg02);
++ break;
++ case AREA_03:
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg03);
++ break;
++ case AREA_04:
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg04);
++ break;
++ case AREA_05:
++ stg_ctrl = STG_MAIN;
++ setTSK(GROUP_01,&TSKstg05);
++ break;
++ default:
++ g_step = GSTEP_CLEAR;
++ break;
++ }
++ stg_bgm = -1;
+ stg_ctrl = STG_INIT;
+ TskBuf[id].step++;
+ break;
+@@ -177,7 +188,7 @@
+ {
+ switch(TskBuf[id].step){
+ case 0:
+- stg_ctrl = STG_INIT;
++// stg_ctrl = ;
+ TskBuf[id].step++;
+ break;
+ case 1:
+diff -Naur a2k-org/a2k_src/src/system.d a2k/a2k_src/src/system.d
+--- a2k-org/a2k_src/src/system.d 2005-05-19 22:31:20.000000000 +0200
++++ a2k/a2k_src/src/system.d 2008-10-07 09:53:29.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/03/24 jumpei isshiki
+ */
+
+-private import std.stdio;
++private import std.c.stdio;
+ private import std.math;
+ private import std.random;
+ private import std.string;
+@@ -22,6 +22,11 @@
+ private import stg;
+ private import bg;
+ private import ship;
++
++const real PI = 0x1.921fb54442d1846ap+1;
++const real PI_2 = 1.57079632679489661923;
++const real PI_4 = 0.78539816339744830962;
++const real SQRT2 = 1.41421356237309504880;
+
+ private char[] str_buf;
+ private int wrk1_time;
+diff -Naur a2k-org/a2k_src/src/task.d a2k/a2k_src/src/task.d
+--- a2k-org/a2k_src/src/task.d 2008-02-07 00:38:58.000000000 +0100
++++ a2k/a2k_src/src/task.d 2008-10-07 09:53:29.000000000 +0200
+@@ -153,7 +153,9 @@
+ TskBuf[i].fp_exit = null;
+ TskBuf[i].image = null;
+ TskBuf[i].bullet_command = null;
+- TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_accx = 0;
++ TskBuf[i].bullet_accy = 0;
+ }
+ TskBuf[i].tskid = TSKID_NONE;
+ TskBuf[i].entry = -1;
+diff -Naur a2k-org/a2k_src/src/title.d a2k/a2k_src/src/title.d
+--- a2k-org/a2k_src/src/title.d 2008-02-12 23:50:14.000000000 +0100
++++ a2k/a2k_src/src/title.d 2008-10-07 09:53:29.000000000 +0200
+@@ -6,7 +6,7 @@
+ 2004/04/08 jumpei isshiki
+ */
+
+-private import std.stdio;
++private import std.c.stdio;
+ private import std.math;
+ private import std.string;
+ private import SDL;
+diff -Naur a2k-org/a2k_src/src/util_ascii.d a2k/a2k_src/src/util_ascii.d
+--- a2k-org/a2k_src/src/util_ascii.d 2005-05-19 22:30:50.000000000 +0200
++++ a2k/a2k_src/src/util_ascii.d 2008-10-07 09:53:29.000000000 +0200
+@@ -13,7 +13,15 @@
+
+ const float ASC_SIZE = (16.0f + 2.0f);
+
+-private float[][] ascii_font = [
++float[][] ascii_font;
++
++
++
++private char[] ascii_dict = "ABCDEFGHIJKLMNOPQRSTUVWXYZ.:!?\"'-=+ 0123456789";
++
++void initASCII()
++{
++static float[][] af = [
+ /* 'A' */
+ [
+ 3, 0, 11, 2,
+@@ -328,10 +336,14 @@
+ ],
+ ];
+
+-private char[] ascii_dict = "ABCDEFGHIJKLMNOPQRSTUVWXYZ.:!?\"'-=+ 0123456789";
++ ascii_font.length = af.length;
++ for (int i = 0; i < ascii_font.length; i++) {
++ ascii_font[i].length = af[i].length;
++ for (int j = 0; j < ascii_font[i].length; j++) {
++ ascii_font[i][j] = af[i][j];
++ }
++ }
+
+-void initASCII()
+-{
+ for(int i = 0; i < ascii_font.length; i++){
+ for(int j = 0; j < ascii_font[i].length; j += 4){
+ ascii_font[i][j+2] += 1.0f;
+diff -Naur a2k-org/a2k_src/src/util_pad.d a2k/a2k_src/src/util_pad.d
+--- a2k-org/a2k_src/src/util_pad.d 2008-02-12 23:46:38.000000000 +0100
++++ a2k/a2k_src/src/util_pad.d 2008-10-07 09:53:29.000000000 +0200
+@@ -7,7 +7,8 @@
+ */
+
+ private import SDL;
+-
++private import SDL_Keysym;
++private import SDL_keyboard;
+ enum{
+ PAD_UP = 0x01,
+ PAD_DOWN = 0x02,
+diff -Naur a2k-org/a2k_src/src/util_sdl.d a2k/a2k_src/src/util_sdl.d
+--- a2k-org/a2k_src/src/util_sdl.d 2008-02-06 01:41:02.000000000 +0100
++++ a2k/a2k_src/src/util_sdl.d 2008-10-07 10:30:33.000000000 +0200
+@@ -6,9 +6,12 @@
+ 2003/11/28 jumpei isshiki
+ */
+
++private import std.stdio;
+ private import std.string;
+-private import SDL;
++private import SDL;
++private import SDL_mouse;
+ private import opengl;
++private import util_pad;
+ private import define;
+
+ enum{
+@@ -30,11 +33,18 @@
+ EX,
+ EY,
+ }
+-
++
++struct VEC_POS {
++ float px;
++ float py;
++ float pz;
++}
+
+ SDL_Surface* primary;
+ SDL_Surface*[] offscreen;
+-
++
++const float SCREEN_RATIOX = cast(float)(SCREEN_X / 2.0f);
++const float SCREEN_RATIOY = cast(float)(SCREEN_Y / 2.0f);
+ const float BASE_Z = 2.0f;
+ float cam_scr = -0.75f;
+ float cam_pos;
+@@ -43,20 +53,27 @@
+ private int height = SCREEN_Y;
+ private float nearPlane = 0.0f;
+ private float farPlane = 1000.0f;
+-
++private GLuint TEXTURE_NONE = 0xffffffff;
+ private GLuint[] tex_bank;
+
+-int initSDL()
++int initSDL()
++
+ {
+ if(SDL_Init(SDL_INIT_VIDEO|SDL_INIT_JOYSTICK) < 0){
+ return 0;
+ }
+
+ Uint32 videoFlags;
+- videoFlags = SDL_OPENGL | SDL_FULLSCREEN;
++// videoFlags = SDL_OPENGL | SDL_FULLSCREEN;
+ //videoFlags = SDL_OPENGL | SDL_RESIZABLE;
+ debug{
+- videoFlags = SDL_OPENGL | SDL_RESIZABLE;
++ if((pads & PAD_BUTTON1)){
++ videoFlags = SDL_OPENGL | SDL_FULLSCREEN;
++ }else{
++ videoFlags = SDL_OPENGL | SDL_RESIZABLE;
++ }
++ }else{
++ videoFlags = SDL_OPENGL | SDL_FULLSCREEN;
+ }
+ primary = SDL_SetVideoMode(width, height, 0, videoFlags);
+ if(primary == null){
+@@ -67,14 +84,15 @@
+ tex_bank.length = SURFACE_MAX;
+ for(int i = 0; i < SURFACE_MAX; i++){
+ offscreen[i] = null;
+- tex_bank[i] = cast(GLuint)-1;
++ tex_bank[i] = TEXTURE_NONE;
+ }
+
+ glClearColor(0.0f, 0.0f, 0.0f, 0.0f);
+ resizedSDL(width, height);
+ SDL_ShowCursor(SDL_DISABLE);
+
+- SDL_WM_SetCaption(cast(char*)PROJECT_NAME, null);
++ SDL_WM_SetCaption(cast(char*)PROJECT_NAME, null);
++ SDL_WM_SetIcon(SDL_LoadBMP("icon.bmp"), null);
+
+ return 1;
+ }
+@@ -96,9 +114,9 @@
+ SDL_ShowCursor(SDL_ENABLE);
+ SDL_Quit();
+ }
++
+
+-
+-void readSDLtexture(char[] fname, int bank)
++void readSDLtexture(char[] fname, int bank)
+ {
+ offscreen[bank] = SDL_LoadBMP(toStringz(fname));
+ if(offscreen[bank]){
+@@ -110,31 +128,28 @@
+ }
+ }
+
+-
+-void bindSDLtexture(int bank)
++void bindSDLtexture(int bank)
+ {
+- if(tex_bank[bank] != -1) glBindTexture(GL_TEXTURE_2D, tex_bank[bank]);
++ if(tex_bank[bank] != TEXTURE_NONE) glBindTexture(GL_TEXTURE_2D, tex_bank[bank]);
+ }
+
+-
+-void clearSDL()
++void clearSDL()
+ {
+ glClear(GL_COLOR_BUFFER_BIT);
+ }
+
+-
+-void flipSDL()
++void flipSDL()
+ {
+ glFlush();
+ SDL_GL_SwapBuffers();
+ }
+
+-
+-void resizedSDL(int w, int h)
++void resizedSDL(int w, int h)
+ {
+ glViewport(0, 0, w, h);
+ glMatrixMode(GL_PROJECTION);
+ glLoadIdentity();
++ w = (w ? w : 1);
+ glFrustum(-nearPlane,nearPlane,
+ -nearPlane * h / w,
+ nearPlane * h / w,
+diff -Naur a2k-org/makefile a2k/makefile
+--- a2k-org/makefile 1970-01-01 01:00:00.000000000 +0100
++++ a2k/makefile 2008-10-07 09:53:29.000000000 +0200
+@@ -0,0 +1,18 @@
++DSRC=$(shell find a2k_src/src -name "*.d")
++SOURCES=$(DSRC) a2k_src/import/SDL_video.d a2k_src/import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++CFLAGS=
++DFLAGS=-O -Ia2k_src/import -Ia2k_src/src -I/usr/X11R6/include/
++EXE=area2048
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc $(CFLAGS) -o $@ $(OBJS) $(COBJS) -lbulletml_d -L/usr/local/lib -L/usr/lib -lgphobos -lpthread -lGLU -lGL -lglut -lm -lstdc++ -lSDL -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ gdmd -d -c -of$@ $(DFLAGS) $<
++
++clean:
++ rm a2k_src/src/*.o
++
diff --git a/games-action/area2048/files/area2048.png b/games-action/area2048/files/area2048.png
new file mode 100644
index 0000000..7dd52e2
--- /dev/null
+++ b/games-action/area2048/files/area2048.png
Binary files differ
diff --git a/games-action/area2048/metadata.xml b/games-action/area2048/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/area2048/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/deadlysoccerball/Manifest b/games-action/deadlysoccerball/Manifest
new file mode 100644
index 0000000..7e11ec1
--- /dev/null
+++ b/games-action/deadlysoccerball/Manifest
@@ -0,0 +1,5 @@
+AUX deadlysoccerball-0.1.diff 561 RMD160 104df42f09960bcc5092568e130c32986c4b9bf0 SHA1 cf5c1a83ded2216dcb0921f7996eda659015e049 SHA256 7f515e40ca909002007ccd6b0c86ca3866c54c0e8d1d8c43b2a23014925b294b
+AUX deadlysoccerball.png 2642 RMD160 e4a5f36d892233fb4d2e393373ced367ce21ed35 SHA1 ff14cd15cb6d6fa5cf493b24ed6f30064f97871f SHA256 1d275f874e1904fa0e6702fdbe22653a6ae9e72ec2d67daa141a563d8d075217
+DIST theDeadlySoccerBall.tar.gz 1496687 RMD160 c7d364a6f48d7f8d578dc724cb94347f8102e2aa SHA1 16107c085250f2091786574d3756f6a898fe93af SHA256 3dc85df981d6faca07f2b37137fff708ea69755016b754ae1be08c6423b692d7
+EBUILD deadlysoccerball-0.1.ebuild 1254 RMD160 b904310f98180269e0a642c9a13385b1217e8b0d SHA1 ccd9be2d6a65d664f9d288e94ce3a8aec11c51e7 SHA256 0bdcdccdef9b183a0635ca426ae41473f4eee32a482c101b684c4352f6e77526
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/deadlysoccerball/deadlysoccerball-0.1.ebuild b/games-action/deadlysoccerball/deadlysoccerball-0.1.ebuild
new file mode 100644
index 0000000..f51b43a
--- /dev/null
+++ b/games-action/deadlysoccerball/deadlysoccerball-0.1.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit eutils games
+
+MY_PN=deadlysoccerball
+
+DESCRIPTION="space soccer ball shooting missiles around"
+HOMEPAGE="http://www-graphics.stanford.edu/courses/cs248-videogame-competition/cs248-05/"
+SRC_URI="http://www-graphics.stanford.edu/courses/cs248-videogame-competition/cs248-05/theDeadlySoccerBall.tar.gz"
+
+LICENSE="unknown"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+DEPEND="media-libs/libsdl
+ media-libs/mesa"
+RDEPEND=""
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${P}.diff
+ cd src/
+ sed -i \
+ -e 's:"\(Sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i World.cpp \
+ -e 's:"\(Textures/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i World.cpp \
+ || die "sed failed"
+ sed -s \
+ -e 's/\theDeadlySoccerBall/deadlysoccerball/g' -i Makefile \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin theDeadlySoccerBall
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r Sounds Textures || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry theDeadlySoccerBall ${PN}
+ dodoc README.txt
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/deadlysoccerball/files/deadlysoccerball-0.1.diff b/games-action/deadlysoccerball/files/deadlysoccerball-0.1.diff
new file mode 100644
index 0000000..3d793c8
--- /dev/null
+++ b/games-action/deadlysoccerball/files/deadlysoccerball-0.1.diff
@@ -0,0 +1,12 @@
+diff -Naur src/World.cpp src-gentoo/World.cpp
+--- src/World.cpp 2005-12-07 20:32:58.000000000 +0100
++++ src-gentoo/World.cpp 2007-11-01 11:31:46.000000000 +0100
+@@ -712,7 +712,7 @@
+ Sphere::loadTexture("Textures/welcome.bmp", &this->welcomeTextureId);
+ Sphere::loadTexture("Textures/white.bmp", &this->whiteTextureId);
+ Sphere::loadTexture("Textures/sphere.bmp", &this->smallSphereTextureId);
+- char filename[15] = "Textures/i.bmp";
++ char filename[255] = "Textures/i.bmp";
+ for (int i=0; i<10; i++)
+ {
+ filename[9] = '0' + i;
diff --git a/games-action/deadlysoccerball/files/deadlysoccerball.png b/games-action/deadlysoccerball/files/deadlysoccerball.png
new file mode 100644
index 0000000..150140d
--- /dev/null
+++ b/games-action/deadlysoccerball/files/deadlysoccerball.png
Binary files differ
diff --git a/games-action/deadlysoccerball/files/digest-deadlysoccerball-0.1 b/games-action/deadlysoccerball/files/digest-deadlysoccerball-0.1
new file mode 100644
index 0000000..d9651d4
--- /dev/null
+++ b/games-action/deadlysoccerball/files/digest-deadlysoccerball-0.1
@@ -0,0 +1,3 @@
+MD5 78b88c0dbe6130209d305bed0e4ac76a theDeadlySoccerBall.tar.gz 1496687
+RMD160 c7d364a6f48d7f8d578dc724cb94347f8102e2aa theDeadlySoccerBall.tar.gz 1496687
+SHA256 3dc85df981d6faca07f2b37137fff708ea69755016b754ae1be08c6423b692d7 theDeadlySoccerBall.tar.gz 1496687
diff --git a/games-action/deadlysoccerball/metadata.xml b/games-action/deadlysoccerball/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/deadlysoccerball/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/exception_conflict/Manifest b/games-action/exception_conflict/Manifest
new file mode 100644
index 0000000..327322c
--- /dev/null
+++ b/games-action/exception_conflict/Manifest
@@ -0,0 +1,11 @@
+AUX disable-netplay-1.09.patch 1116 RMD160 a804f0772917c727e0e39fe1b31794c7c8d91d96 SHA1 24263d64edde9d8229a8098bde22595a52f524a6 SHA256 46e7a5ecb2f21c878dd3534003f2a2ddf174ed9762483f4aeb25f0c618d93554
+AUX exception_conflict.png 460 RMD160 ce0a75146ea496af0deb7413284d7e729cf5ec04 SHA1 f92ce0bce71d8aeb6947b06d911c1e3b5fca31d0 SHA256 5b7669748610345803494e590a33beeaa0c1b94bd7344c8506e3b47bfac340b2
+AUX gcc-4.3-fixes-1.09.patch 351 RMD160 816171ce7fc96faf0e990144dff2efe66c55b87a SHA1 b956ae3b2e9a577dfa7abd72047a27627619fbb4 SHA256 360b86067edc55d495c824b9bc3bda4625c8e14495efec3ee432a99bd0333bb2
+AUX gcc-4.3-fixes.patch 343 RMD160 b5438beec5a81f8eaf6630f040e8dc8d15cf6886 SHA1 69cfe2910e77b6ba1b80ea1dd49e4c9e9548fa08 SHA256 9a7733fa0766bb2a4d262cf517c1a19cf5bd7cec15ba31d8e584fc7a0568ad5b
+AUX linuxfixes-1.09.patch 4080 RMD160 8787d194fae7c15f39f00cdff05e5d594925bd1b SHA1 945a1c2e62361405025ed216f072c0a64eda9792 SHA256 0dda3880fc0d12924c7367e6544c25362bf289c2cabf51afa4b053b575b86677
+AUX linuxfixes.patch 3021 RMD160 25a591adaddf53a44a81ca0bc6496e8b521d678f SHA1 5b7794f0bc2eb4bef49e102da3952cde269b8aff SHA256 bc4aaf1b560c305a6ed9a661e14fc6ddb1eb779909cf6342bbbde77f8fc6e89e
+DIST 109.zip 1310305 RMD160 8bcd9f12275096e92fc9101230297b5ff055f8e7 SHA1 21b877bff1fe4a8cef0018b91919d850a427f9d6 SHA256 98630bebadd29003e2a2d990688734d71f07c3c171156fed5b1bb80f98208b29
+DIST exception_conflict.zip 41706682 RMD160 2092d6e1328b7ceed1efdf0b15be83ff295ad521 SHA1 f3be89eac3fd567559ebeb9749b60bdc4b5fcb4c SHA256 b41ad9ccfdaf73213ead858faf0db0f02fb9fb8b1b64d5f2d5b2a94ad28b054f
+EBUILD exception_conflict-1.03.ebuild 1381 RMD160 6df59ca577535fa0f8254f4aaf8e81133f855f73 SHA1 43ba725e20bb52bd1064d3220cf2b178330c6aaa SHA256 44099b0182d2cf5af8bdfbf3f688f0811b23c60c881c69d147bae26ca6994f3b
+EBUILD exception_conflict-1.09.ebuild 1536 RMD160 bb24a71ac1eef4b91a91eb71df93b0bcc9abcc3b SHA1 e86a990e1ebea22a960dcec6f1ae94152f334b10 SHA256 3f3efa8e622b6b1b83979ab4694f729273678322322d6321ddce030164b0e82c
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/exception_conflict/exception_conflict-1.03.ebuild b/games-action/exception_conflict/exception_conflict-1.03.ebuild
new file mode 100644
index 0000000..ffc7d12
--- /dev/null
+++ b/games-action/exception_conflict/exception_conflict-1.03.ebuild
@@ -0,0 +1,67 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=2
+inherit eutils games
+
+DESCRIPTION="outstanding shmup using opengl and sdl"
+HOMEPAGE="http://i-saint.skr.jp/exception_conflict/"
+SRC_URI="http://xes.plala.jp/demo4/g4033/${PN}.zip"
+
+LICENSE="${PN}"
+SLOT="0"
+KEYWORDS="~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/ftgl
+ media-libs/freetype
+ media-libs/libpng
+ dev-ruby/rake
+ virtual/opengl
+ dev-libs/boost
+ media-libs/glew
+ media-libs/freeglut
+ media-libs/sdl-mixer"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${PN}/src
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ unzip src.zip
+}
+
+src_prepare(){
+ cd "${S}"/src
+ epatch "${FILESDIR}"/linuxfixes.patch
+ epatch "${FILESDIR}"/gcc-4.3-fixes.patch
+ sed -i -e "s:resource/:"${GAMES_DATADIR}"/"${PN}"/resource/:" -i app.cc
+ sed -i -e "s:resource/:"${GAMES_DATADIR}"/"${PN}"/resource/:" -i resource.cc
+
+}
+
+src_compile() {
+ cd "${S}"/src
+ rake || die
+}
+
+src_install() {
+ dogamesbin "${S}"/src/${PN} || die "dogamesbin ${PN} failed"
+
+ local datadir="${GAMES_DATADIR}"/"${PN}"
+ dodir ${datadir}
+ insinto "${datadir}"
+ doins -r "${WORKDIR}"/${PN}/resource || die "doins resource failed"
+
+ newicon "${FILESDIR}"/"${PN}.png" "${PN}.png"
+ make_desktop_entry "${PN}" "${PN}"
+ dodoc "${WORKDIR}"/${PN}/copyrights || die
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/exception_conflict/exception_conflict-1.09.ebuild b/games-action/exception_conflict/exception_conflict-1.09.ebuild
new file mode 100644
index 0000000..958be8e
--- /dev/null
+++ b/games-action/exception_conflict/exception_conflict-1.09.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=2
+inherit eutils games
+
+DESCRIPTION="outstanding shmup using opengl and sdl"
+HOMEPAGE="http://i-saint.skr.jp/exception_conflict/"
+SRC_URI="http://xes.plala.jp/demo4/g4033/${PN}.zip
+ http://i-saint.skr.jp/exception_conflict/update/109.zip"
+
+LICENSE="${PN}"
+SLOT="0"
+KEYWORDS="~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/ftgl
+ media-libs/freetype
+ media-libs/libpng
+ dev-ruby/rake
+ virtual/opengl
+ dev-libs/boost
+ media-libs/glew
+ media-libs/freeglut
+ media-libs/sdl-mixer"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${PN}/src
+
+src_unpack() {
+ unpack ${A}
+ cp "${WORKDIR}"/src/src.zip "${S}"
+ cd "${S}"
+ unzip src.zip
+}
+
+src_prepare(){
+ cd "${S}"/src
+ epatch "${FILESDIR}"/linuxfixes-${PV}.patch
+ epatch "${FILESDIR}"/gcc-4.3-fixes-${PV}.patch
+ epatch "${FILESDIR}"/disable-netplay-${PV}.patch
+ sed -i -e "s:resource/:"${GAMES_DATADIR}"/"${PN}"/resource/:" -i app.cc
+ sed -i -e "s:resource/:"${GAMES_DATADIR}"/"${PN}"/resource/:" -i resource.cc
+
+}
+
+src_compile() {
+ cd "${S}"/src
+ rake || die
+}
+
+src_install() {
+ dogamesbin "${S}"/src/${PN} || die "dogamesbin ${PN} failed"
+
+ local datadir="${GAMES_DATADIR}"/"${PN}"
+ dodir ${datadir}
+ insinto "${datadir}"
+ doins -r "${WORKDIR}"/${PN}/resource || die "doins resource failed"
+
+ newicon "${FILESDIR}"/"${PN}.png" "${PN}.png"
+ make_desktop_entry "${PN}" "${PN}"
+ dodoc "${WORKDIR}"/${PN}/copyrights || die
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/exception_conflict/files/disable-netplay-1.09.patch b/games-action/exception_conflict/files/disable-netplay-1.09.patch
new file mode 100644
index 0000000..4f1bf68
--- /dev/null
+++ b/games-action/exception_conflict/files/disable-netplay-1.09.patch
@@ -0,0 +1,36 @@
+diff -Naur src/app.cc src-patch/app.cc
+--- src/app.cc 2009-01-21 05:52:46.000000000 +0100
++++ src-patch/app.cc 2009-07-15 12:14:38.000000000 +0200
+@@ -1967,11 +1967,13 @@
+ else if(!g_iclient) {
+ g_iclient.reset(new InputClientLocal());
+ }
++#ifdef EXCEPTION_ENABLE_NETPLAY
+ else if(InputClientIP* icip = dynamic_cast<InputClientIP*>(g_iclient.get())) {
+ if(!icip->isRunning()) {
+ throw Error("disconnected");
+ }
+ }
++#endif // EXCEPTION_ENABLE_NETPLAY
+ IGame *game = CreateGame(m_opt);
+ CreateGamePanel(game);
+
+diff -Naur src/network.cc src-patch/network.cc
+--- src/network.cc 2009-01-21 05:52:46.000000000 +0100
++++ src-patch/network.cc 2009-07-15 12:16:36.000000000 +0200
+@@ -297,6 +297,7 @@
+ ::SetConsoleCtrlHandler(Server_OnShutdown, TRUE);
+ #endif // WIN32
+ }
++#ifdef WIN32
+ g_print = PrintConsole;
+
+ Print(sgui::Format("exception conflict server %.2f\n\n", float(EXCEPTION_VERSION)/100.0f).c_str());
+@@ -344,6 +345,7 @@
+ if(g_logfile) {
+ fclose(g_logfile);
+ }
++#endif // WIN32
+ }
+
+
diff --git a/games-action/exception_conflict/files/exception_conflict.png b/games-action/exception_conflict/files/exception_conflict.png
new file mode 100644
index 0000000..7f2167b
--- /dev/null
+++ b/games-action/exception_conflict/files/exception_conflict.png
Binary files differ
diff --git a/games-action/exception_conflict/files/gcc-4.3-fixes-1.09.patch b/games-action/exception_conflict/files/gcc-4.3-fixes-1.09.patch
new file mode 100644
index 0000000..08e0597
--- /dev/null
+++ b/games-action/exception_conflict/files/gcc-4.3-fixes-1.09.patch
@@ -0,0 +1,11 @@
+diff -Naur src/lib/ist/bstream.h src-patch/lib/ist/bstream.h
+--- src/lib/ist/bstream.h 2009-01-01 19:13:42.000000000 +0100
++++ src-patch/lib/ist/bstream.h 2009-07-15 12:05:29.000000000 +0200
+@@ -8,6 +8,7 @@
+ #include <algorithm>
+ #include <iostream>
+ #include <fstream>
++#include <cstring>
+ #ifdef IST_BSTREAM_ENABLE_ZLIB
+ #include <zlib.h>
+ #endif
diff --git a/games-action/exception_conflict/files/gcc-4.3-fixes.patch b/games-action/exception_conflict/files/gcc-4.3-fixes.patch
new file mode 100644
index 0000000..22fdd62
--- /dev/null
+++ b/games-action/exception_conflict/files/gcc-4.3-fixes.patch
@@ -0,0 +1,11 @@
+diff -Naur src/lib/ist/bstream.h src-p/lib/ist/bstream.h
+--- src/lib/ist/bstream.h 2009-07-15 10:20:37.000000000 +0200
++++ src-p/lib/ist/bstream.h 2009-07-15 10:19:14.000000000 +0200
+@@ -8,6 +8,7 @@
+ #include <algorithm>
+ #include <iostream>
+ #include <fstream>
++#include <cstring>
+ #ifdef IST_BSTREAM_ENABLE_ZLIB
+ #include <zlib.h>
+ #endif
diff --git a/games-action/exception_conflict/files/linuxfixes-1.09.patch b/games-action/exception_conflict/files/linuxfixes-1.09.patch
new file mode 100644
index 0000000..5744b32
--- /dev/null
+++ b/games-action/exception_conflict/files/linuxfixes-1.09.patch
@@ -0,0 +1,112 @@
+diff -Naur src/character/rule_base.h src-diff/character/rule_base.h
+--- src/character/rule_base.h 2008-12-31 18:41:14.000000000 +0100
++++ src-diff/character/rule_base.h 2009-04-17 14:10:31.000000000 +0200
+@@ -68,7 +68,7 @@
+ ~RuleBase()
+ {
+ g_round2 = false;
+- g_rand.reset();
++// g_rand.reset();
+ }
+
+ float getDrawPriority() { return 10.0f; }
+diff -Naur src/app.cc src-patch/app.cc
+--- src/app.cc 2009-01-21 05:52:46.000000000 +0100
++++ src-patch/app.cc 2009-07-15 12:09:08.000000000 +0200
+@@ -1516,7 +1516,7 @@
+
+ base+=sgui::Point(0, 25);
+ new sgui::Label(this, base, sgui::Size(60, 20), L"u[");
+- swprintf(buf, L"%.1f", conf.bloom);
++ //swprintf(buf, L"%.1f", conf.bloom);
+ b = new sgui::Button(this, base+sgui::Point(55, 0), sgui::Size(20, 20), L"<", BU_BLOOM_DEC);
+ new sgui::ToolTip(b, L"VF[_ĹA邢ڂ\nῂɂGtFNg̋ݒ肵܂B\nVF[_gȂݒ̏ꍇῶ܂B");
+ m_bloom = new sgui::Label(this, base+sgui::Point(80, 0), sgui::Size(20, 20), buf);
+diff -Naur src/game.h src-patch/game.h
+--- src/game.h 2009-01-21 05:13:50.000000000 +0100
++++ src-patch/game.h 2009-07-15 12:09:49.000000000 +0200
+@@ -100,7 +100,9 @@
+
+ void save()
+ {
+- FILE *f = fopen("config", "wb");
++ char path[PATH_MAX];
++ snprintf(path, PATH_MAX, "%s/.exception_conflict/config", getenv("HOME"));
++ FILE *f = fopen(path, "wb");
+ if(!f) {
+ return;
+ }
+@@ -181,7 +183,9 @@
+
+ void load()
+ {
+- FILE *in = fopen("config", "rb");
++ char path[PATH_MAX];
++ snprintf(path, PATH_MAX, "%s/.exception_conflict/config", getenv("HOME"));
++ FILE *in = fopen(path, "rb");
+ if(!in) {
+ return;
+ }
+diff -Naur src/lib/sgui/sgui.h src-patch/lib/sgui/sgui.h
+--- src/lib/sgui/sgui.h 2009-01-16 16:38:20.000000000 +0100
++++ src-patch/lib/sgui/sgui.h 2009-07-15 12:10:35.000000000 +0200
+@@ -23,7 +23,7 @@
+ #include <dirent.h>
+ #endif
+ #include <boost/thread.hpp>
+-#include <FTGL/FTGLTextureFont.h>
++#include <FTGL/ftgl.h>
+ #include <SDL/SDL.h>
+ #include "sgui.h"
+
+diff -Naur src/main.cc src-patch/main.cc
+--- src/main.cc 2009-01-16 16:38:20.000000000 +0100
++++ src-patch/main.cc 2009-07-15 12:11:04.000000000 +0200
+@@ -33,6 +33,9 @@
+ char *hoge = new char[128];
+ #endif
+
++ char cfg_path[PATH_MAX];
++ snprintf(cfg_path, PATH_MAX, "%s/.exception_conflict/", getenv("HOME"));
++ mkdir(cfg_path, 0755);
+
+ while(exception::FindProcess("updater.exe")) {
+ sgui::Sleep(100);
+diff -Naur src/Rakefile src-patch/Rakefile
+--- src/Rakefile 2009-01-01 19:13:42.000000000 +0100
++++ src-patch/Rakefile 2009-07-15 12:12:04.000000000 +0200
+@@ -4,7 +4,7 @@
+
+ CFLAGS = "-O2 -I ./ -I lib #{`freetype-config --cflags`} #{`sdl-config --cflags`}".gsub(/\n/, '')
+ LFLAGS = ''
+-LIBS = "-L lib/ist -L lib/sgui -lsgui -list -lboost_regex-gcc41-mt -lboost_date_time-gcc41-mt -lboost_system-gcc41-mt -lboost_thread-gcc41-mt -lz -lpng -lGL -lGLU -lGLEW -lftgl #{`sdl-config --libs`} -lSDL_mixer #{`freetype-config --libs`}".gsub(/\n/, '')
++LIBS = "-L lib/ist -L lib/sgui -lsgui -list -lboost_regex-mt -lboost_date_time-mt -lboost_system-mt -lboost_thread-mt -lz -lpng -lGL -lGLU -lGLEW -lftgl #{`sdl-config --libs`} -lSDL_mixer #{`freetype-config --libs`}".gsub(/\n/, '')
+ CC = 'g++'
+
+ SRCS = Dir.glob("{.,character}/*.cc")
+@@ -25,11 +25,10 @@
+
+
+ task "default" => "all"
+-task "all" => ["ist", "sgui", "exception"]
++task "all" => ["ist", "sgui", "exception_conflict"]
+
+-file "exception" => OBJS do |t|
++file "exception_conflict" => OBJS do |t|
+ sh "#{CC} -o #{t.name} #{t.prerequisites.join(' ')} #{CFLAGS} #{LIBS}"
+- sh "cp #{t.name} ../#{t.name}"
+ end
+
+ rule ".o" => ".cc" do |t|
+diff -Naur src/system.h src-patch/system.h
+--- src/system.h 2009-01-14 21:34:42.000000000 +0100
++++ src-patch/system.h 2009-07-15 12:12:13.000000000 +0200
+@@ -1,7 +1,7 @@
+ #ifndef system_h
+ #define system_h
+
+-#include <windows.h>
++//#include <windows.h>
+ #include <vector>
+ #include <string>
+ #include <functional>
diff --git a/games-action/exception_conflict/files/linuxfixes.patch b/games-action/exception_conflict/files/linuxfixes.patch
new file mode 100644
index 0000000..4d2f6ff
--- /dev/null
+++ b/games-action/exception_conflict/files/linuxfixes.patch
@@ -0,0 +1,88 @@
+diff -Naur src/character/rule_base.h src-diff/character/rule_base.h
+--- src/character/rule_base.h 2008-12-31 18:41:14.000000000 +0100
++++ src-diff/character/rule_base.h 2009-04-17 14:10:31.000000000 +0200
+@@ -68,7 +68,7 @@
+ ~RuleBase()
+ {
+ g_round2 = false;
+- g_rand.reset();
++// g_rand.reset();
+ }
+
+ float getDrawPriority() { return 10.0f; }
+diff -Naur src/game.h src-diff/game.h
+--- src/game.h 2009-01-04 01:05:04.000000000 +0100
++++ src-diff/game.h 2009-04-17 14:10:12.000000000 +0200
+@@ -82,7 +82,9 @@
+
+ void save()
+ {
+- FILE *f = fopen("config", "wb");
++ char path[PATH_MAX];
++ snprintf(path, PATH_MAX, "%s/.exception_conflict/config", getenv("HOME"));
++ FILE *f = fopen(path, "wb");
+ if(!f) {
+ return;
+ }
+@@ -143,7 +145,9 @@
+
+ void load()
+ {
+- FILE *in = fopen("config", "rb");
++ char path[PATH_MAX];
++ snprintf(path, PATH_MAX, "%s/.exception_conflict/config", getenv("HOME"));
++ FILE *in = fopen(path, "rb");
+ if(!in) {
+ return;
+ }
+diff -Naur src/lib/sgui/sgui.h src-diff/lib/sgui/sgui.h
+--- src/lib/sgui/sgui.h 2009-01-04 13:33:14.000000000 +0100
++++ src-diff/lib/sgui/sgui.h 2009-04-17 14:21:29.000000000 +0200
+@@ -23,7 +23,7 @@
+ #include <dirent.h>
+ #endif
+ #include <boost/thread.hpp>
+-#include <FTGL/FTGLTextureFont.h>
++#include <FTGL/ftgl.h>
+ #include <SDL/SDL.h>
+ #include "sgui.h"
+
+diff -Naur src/main.cc src-diff/main.cc
+--- src/main.cc 2009-01-01 19:13:42.000000000 +0100
++++ src-diff/main.cc 2009-04-17 14:41:33.000000000 +0200
+@@ -56,6 +56,9 @@
+ char *hoge = new char[128];
+ #endif
+
++ char cfg_path[PATH_MAX];
++ snprintf(cfg_path, PATH_MAX, "%s/.exception_conflict/", getenv("HOME"));
++ mkdir(cfg_path, 0755);
+
+ #ifdef WIN32
+ while(FindProcess("updater.exe")) {
+diff -Naur src/Rakefile src-diff/Rakefile
+--- src/Rakefile 2009-01-01 19:13:42.000000000 +0100
++++ src-diff/Rakefile 2009-04-17 14:26:47.000000000 +0200
+@@ -4,7 +4,7 @@
+
+ CFLAGS = "-O2 -I ./ -I lib #{`freetype-config --cflags`} #{`sdl-config --cflags`}".gsub(/\n/, '')
+ LFLAGS = ''
+-LIBS = "-L lib/ist -L lib/sgui -lsgui -list -lboost_regex-gcc41-mt -lboost_date_time-gcc41-mt -lboost_system-gcc41-mt -lboost_thread-gcc41-mt -lz -lpng -lGL -lGLU -lGLEW -lftgl #{`sdl-config --libs`} -lSDL_mixer #{`freetype-config --libs`}".gsub(/\n/, '')
++LIBS = "-L lib/ist -L lib/sgui -lsgui -list -lboost_regex-mt -lboost_date_time-mt -lboost_system-mt -lboost_thread-mt -lz -lpng -lGL -lGLU -lGLEW -lftgl #{`sdl-config --libs`} -lSDL_mixer #{`freetype-config --libs`}".gsub(/\n/, '')
+ CC = 'g++'
+
+ SRCS = Dir.glob("{.,character}/*.cc")
+@@ -25,11 +25,10 @@
+
+
+ task "default" => "all"
+-task "all" => ["ist", "sgui", "exception"]
++task "all" => ["ist", "sgui", "exception_conflict"]
+
+-file "exception" => OBJS do |t|
++file "exception_conflict" => OBJS do |t|
+ sh "#{CC} -o #{t.name} #{t.prerequisites.join(' ')} #{CFLAGS} #{LIBS}"
+- sh "cp #{t.name} ../#{t.name}"
+ end
+
+ rule ".o" => ".cc" do |t|
diff --git a/games-action/exception_conflict/metadata.xml b/games-action/exception_conflict/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/exception_conflict/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/gradleunison/Manifest b/games-action/gradleunison/Manifest
new file mode 100644
index 0000000..1988dbc
--- /dev/null
+++ b/games-action/gradleunison/Manifest
@@ -0,0 +1,6 @@
+AUX gradleunison-0.10.diff 10597 RMD160 ed309b1970815a6f6ac79415d0789f25e976c4ec SHA1 55991eba01fdcc60641b608e6dd93914aa13cd9e SHA256 0d7f273777fe35c832da125ec3419e4985ad58faa65d62e77646233960300e20
+AUX gradleunison.png 4207 RMD160 6ed7ab4086b4bfbcec53d24692cf6dd291416774 SHA1 897d8f333b5d0148873cbfca5d18efb443aecf1d SHA256 474ccdd8886e7aa12bc628fdc2621025838ac5d6f1bd549708adf975703e0823
+AUX gu-score.dat 320 RMD160 71f7469d6fc0926e8cb71065927913bdf4157999 SHA1 d22ed6a6bb81b66e99594db7f522ff2f61f318ee SHA256 17776030d404abf6de6000a362c35bf7fb6ff32f9effa309e8e5f9edf673ce3c
+DIST GU.zip 5352279 RMD160 951fca121f5c445bf026f51c99c27690c51a28af SHA1 c81e5aa471e62c8ee2a76d0e139c81cf7c74f185 SHA256 49960fb50ebe7edc8012bebd634417bcd009deb4ed5d912f4c5fee22af011eee
+EBUILD gradleunison-0.10.ebuild 1919 RMD160 1e3e159b8fd92806b4e34d112ed19e8be15511a3 SHA1 d5c6a8b24bc1da2cac71a2ef35ef6827e707e5f9 SHA256 76d82c8722111654f75ab0519682d3b83e5063c2a63bc5cd89eb1f1f0eca5c7a
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/gradleunison/files/gradleunison-0.10.diff b/games-action/gradleunison/files/gradleunison-0.10.diff
new file mode 100644
index 0000000..3988143
--- /dev/null
+++ b/games-action/gradleunison/files/gradleunison-0.10.diff
@@ -0,0 +1,350 @@
+diff -Naur GU/Makefile GU-gentoo/Makefile
+--- GU/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ GU-gentoo/Makefile 2007-10-10 19:30:12.000000000 +0200
+@@ -0,0 +1,17 @@
++DC=gdmd
++DFLAGS=-g -O -d -release -Iimport -Isrc
++DOUT=-of
++
++DSRC=$(shell find src/ -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d import/SDL_mouse.d
++OBJS=$(SOURCES:.d=.o)
++EXE=gradleunison
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
+diff -Naur GU/import/SDL.d GU-gentoo/import/SDL.d
+--- GU/import/SDL.d 2004-05-08 14:14:14.000000000 +0200
++++ GU-gentoo/import/SDL.d 2007-10-10 19:30:12.000000000 +0200
+@@ -20,18 +20,21 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_types;
++public import SDL_getenv;
++public import SDL_error;
++public import SDL_rwops;
++public import SDL_timer;
++public import SDL_audio;
++public import SDL_cdrom;
++public import SDL_keyboard;
++public import SDL_keysym;
++public import SDL_joystick;
++public import SDL_mouse;
++public import SDL_events;
++public import SDL_video;
++public import SDL_byteorder;
++public import SDL_version;
+
+ extern(C):
+
+@@ -72,10 +75,10 @@
+ * dynamically linked library. You should call it upon all exit conditions.
+ */
+ void SDL_Quit();
+-
++/+
+ void SDL_SetModuleHandle(void *hInst);
+ //extern(Windows) void* GetModuleHandle(char*);
+-extern(Windows) void* GetModuleHandleA(char*);
++extern(Windows) void* GetModuleHandle(char*);
+
+ static this()
+ {
+@@ -83,10 +86,11 @@
+ if (SDL_Init(SDL_INIT_NOPARACHUTE) < 0)
+ throw new Error("Error loading SDL");
+ // SDL_SetModuleHandle(GetModuleHandle(null));
+- SDL_SetModuleHandle(GetModuleHandleA(null));
++ SDL_SetModuleHandle(GetModuleHandle(null));
+ }
+
+ static ~this()
+ {
+ SDL_Quit();
+ }
+++/
+diff -Naur GU/import/SDL_endian.d GU-gentoo/import/SDL_endian.d
+--- GU/import/SDL_endian.d 2004-05-08 12:55:52.000000000 +0200
++++ GU-gentoo/import/SDL_endian.d 2007-10-10 19:30:12.000000000 +0200
+@@ -47,7 +47,7 @@
+ */
+
+ Uint16 SDL_Swap16(Uint16 D) {
+- return((D<<8)|(D>>8));
++ return cast(Uint16)((D<<8)|(D>>8));
+ }
+
+ Uint32 SDL_Swap32(Uint32 D) {
+diff -Naur GU/import/SDL_events.d GU-gentoo/import/SDL_events.d
+--- GU/import/SDL_events.d 2004-12-02 15:48:16.000000000 +0100
++++ GU-gentoo/import/SDL_events.d 2007-10-10 19:30:12.000000000 +0200
+@@ -105,7 +105,7 @@
+ Uint8 type; /* SDL_KEYDOWN or SDL_KEYUP */
+ Uint8 which; /* The keyboard device index */
+ Uint8 state; /* SDL_PRESSED or SDL_RELEASED */
+- SDL_keysym keysym;
++ SDL_keysym2 keysym;
+ }
+
+ /* Mouse motion event structure */
+diff -Naur GU/import/SDL_keyboard.d GU-gentoo/import/SDL_keyboard.d
+--- GU/import/SDL_keyboard.d 2002-01-04 15:28:12.000000000 +0100
++++ GU-gentoo/import/SDL_keyboard.d 2007-10-10 19:30:12.000000000 +0200
+@@ -26,7 +26,7 @@
+ // !!! A hack! struct SDL_keysym is defined in this module,
+ // !!! so we need to resolve the nameclash...
+ // !!! Definitely won't work on *NIX but for now will do.
+-import SDL_Keysym;
++import SDL_keysym;
+
+ extern(C):
+
+@@ -46,7 +46,7 @@
+ An international character..
+ }
+ */
+-struct SDL_keysym {
++struct SDL_keysym2 {
+ Uint8 scancode; /* hardware specific scancode */
+ SDLKey sym; /* SDL virtual keysym */
+ SDLMod mod; /* current key modifiers */
+diff -Naur GU/import/SDL_syswm.d GU-gentoo/import/SDL_syswm.d
+--- GU/import/SDL_syswm.d 2004-01-03 16:10:50.000000000 +0100
++++ GU-gentoo/import/SDL_syswm.d 2007-10-10 19:30:12.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-import SDL_Version;
++import SDL_version;
+
+ extern(C):
+
+diff -Naur GU/import/opengl.d GU-gentoo/import/opengl.d
+--- GU/import/opengl.d 2004-01-09 10:52:04.000000000 +0100
++++ GU-gentoo/import/opengl.d 2007-10-10 19:30:12.000000000 +0200
+@@ -1,10 +1,6 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
++
+ extern(C):
+-}
++
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1112,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1365,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur GU/import/openglu.d GU-gentoo/import/openglu.d
+--- GU/import/openglu.d 2003-12-04 04:15:26.000000000 +0100
++++ GU-gentoo/import/openglu.d 2007-10-10 19:30:12.000000000 +0200
+@@ -1,11 +1,8 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
++
+ extern(C):
+-}
++
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur GU/src/bulletcommand.d GU-gentoo/src/bulletcommand.d
+--- GU/src/bulletcommand.d 2006-08-16 18:07:38.000000000 +0200
++++ GU-gentoo/src/bulletcommand.d 2007-10-10 19:31:33.000000000 +0200
+@@ -37,7 +37,7 @@
+
+ buf.length = 256;
+ buf = fname ~ "\0";
+- parser[bank] = BulletMLParserTinyXML_new(buf);
++ parser[bank] = BulletMLParserTinyXML_new(buf.ptr);
+ if(parser[bank]) BulletMLParserTinyXML_parse(parser[bank]);
+ buf.length = 0;
+ }
+@@ -171,7 +171,8 @@
+ if(eid != -1){
+ TskBuf[eid].parent = BulletCommand.now.id;
+ d = (d <= 180.0f ? d : -(360.0f - d));
+- d = d / ROTVAL;
++ d = d / ROTVAL;
++ TskBuf[eid].roll = 0;
+ TskBuf[eid].bullet_speed = s;
+ TskBuf[eid].bullet_direction = d;
+ TskBuf[eid].bullet_velx = (sin(d) * (-s * VEL_SDM_SS_RATIO));
+diff -Naur GU/src/luminous.d GU-gentoo/src/luminous.d
+--- GU/src/luminous.d 2006-07-08 04:49:12.000000000 +0200
++++ GU-gentoo/src/luminous.d 2007-10-10 19:32:36.000000000 +0200
+@@ -7,7 +7,7 @@
+ */
+
+ private import std.math;
+-private import std.string;
++private import std.c.string;
+ private import opengl;
+ private import util_sdl;
+ private import task;
+@@ -68,11 +68,11 @@
+
+ static void makeLuminousTexture()
+ {
+- uint *data = td;
++ uint *data = td.ptr;
+ int i;
+
+ td[0..length] = 0;
+- //memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
++ memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
+ glGenTextures(1, &luminousTexture);
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 4, luminousTextureWidth, luminousTextureHeight, 0, GL_RGBA, GL_UNSIGNED_BYTE, data);
+diff -Naur GU/src/main.d GU-gentoo/src/main.d
+--- GU/src/main.d 2006-09-01 21:02:40.000000000 +0200
++++ GU-gentoo/src/main.d 2007-10-10 19:30:12.000000000 +0200
+@@ -6,14 +6,14 @@
+ 2006/07/07 jumpei isshiki
+ */
+
+-private import std.c.windows.windows;
++//private import std.c.windows.windows;
+ private import std.stdio;
+ private import std.string;
+ private import std.random;
+ private import std.math;
+ private import SDL;
+ private import opengl;
+-private import reflection;
++//private import reflection;
+ private import util_sdl;
+ private import util_glbf;
+ private import util_pad;
+@@ -66,9 +66,11 @@
+ for(int i = 0; i < argc; i++){
+ str_buf[i] = lpCmdLine[i];
+ }
+- split_buf = split(str_buf);
++ split_buf = split(str_buf);
++/*
+ if(split_buf[0].length > 1) Reflection.init(split_buf[0]);
+- else Reflection.init("main.exe");
++ else Reflection.init("main.exe");
++*/
+ }
+
+ try{
+@@ -86,7 +88,7 @@
+ }else{
+ int main(char[][] argv)
+ {
+- Reflection.init(argv[argv.length-1]);
++ // Reflection.init(argv[argv.length-1]);
+ return boot();
+ }
+ }
+diff -Naur GU/src/task.d GU-gentoo/src/task.d
+--- GU/src/task.d 2006-08-24 17:35:26.000000000 +0200
++++ GU-gentoo/src/task.d 2007-10-10 19:33:42.000000000 +0200
+@@ -182,7 +182,9 @@
+ TskBuf[i].fp_draw = null;
+ TskBuf[i].fp_exit = null;
+ TskBuf[i].bullet_command = null;
+- TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_accx = 0;
++ TskBuf[i].bullet_accy = 0;
+ }
+ TskBuf[i].tskid = TSKID_NONE;
+ TskBuf[i].entry = -1;
+diff -Naur GU/src/util_glbf.d GU-gentoo/src/util_glbf.d
+--- GU/src/util_glbf.d 2006-07-07 17:37:52.000000000 +0200
++++ GU-gentoo/src/util_glbf.d 2007-10-10 19:30:12.000000000 +0200
+@@ -156,7 +156,7 @@
+ {
+ glBindTexture(GL_TEXTURE_2D, font.texture); // Select Our Font Texture
+ glListBase(font.base-32); // Choose The Font Set (0 or 1)
+- glCallLists(str.length, GL_BYTE, str); // Write The Text To The Screen
++ glCallLists(str.length, GL_BYTE, str.ptr); // Write The Text To The Screen
+ }
+
+ int glbfInit(GLBitmapFont* font, char* filename, GLfloat xsize, GLfloat xdots, GLfloat ydots)
+diff -Naur GU/src/util_rand.d GU-gentoo/src/util_rand.d
+--- GU/src/util_rand.d 2006-07-26 16:50:10.000000000 +0200
++++ GU-gentoo/src/util_rand.d 2007-10-10 19:30:12.000000000 +0200
+@@ -112,14 +112,14 @@
+
+ void next_state()
+ {
+- uint *p=state;
++ uint *p=state.ptr;
+
+ /* if init_genrand() has not been called, */
+ /* a default initial seed is used */
+ if (initf==0) init_genrand(5489);
+
+ left = N;
+- next = state;
++ next = state.ptr;
+
+ for (int j=N-M+1; --j; p++)
+ *p = p[M] ^ TWIST(p[0], p[1]);
+diff -Naur GU/src/util_snd.d GU-gentoo/src/util_snd.d
+--- GU/src/util_snd.d 2006-07-23 17:34:42.000000000 +0200
++++ GU-gentoo/src/util_snd.d 2007-10-10 19:30:12.000000000 +0200
+@@ -99,7 +99,7 @@
+
+ char[] fileName = name ~ "\0";
+
+- music[ch] = Mix_LoadMUS(fileName);
++ music[ch] = Mix_LoadMUS(fileName.ptr);
+ if(!music[ch]){
+ writefln("snd load error %s", name);
+ sound_use = false;
+@@ -119,7 +119,7 @@
+
+ char[] fileName = name ~ "\0";
+
+- chunk[bank] = Mix_LoadWAV(fileName);
++ chunk[bank] = Mix_LoadWAV(fileName.ptr);
+ if(!chunk[bank]){
+ sound_use = false;
+ }
diff --git a/games-action/gradleunison/files/gradleunison.png b/games-action/gradleunison/files/gradleunison.png
new file mode 100644
index 0000000..613736f
--- /dev/null
+++ b/games-action/gradleunison/files/gradleunison.png
Binary files differ
diff --git a/games-action/gradleunison/files/gu-score.dat b/games-action/gradleunison/files/gu-score.dat
new file mode 100644
index 0000000..3a5aacb
--- /dev/null
+++ b/games-action/gradleunison/files/gu-score.dat
Binary files differ
diff --git a/games-action/gradleunison/gradleunison-0.10.ebuild b/games-action/gradleunison/gradleunison-0.10.ebuild
new file mode 100644
index 0000000..4c1e7b7
--- /dev/null
+++ b/games-action/gradleunison/gradleunison-0.10.ebuild
@@ -0,0 +1,72 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=GU
+MY_PV=${PV//./_}
+
+DESCRIPTION="jumpei isshiki's HelloWorldProject (2006/09/02) "
+HOMEPAGE="http://homepage2.nifty.com/isshiki/prog_win_d.html"
+SRC_URI="http://isshiki.la.coocan.jp/game/${MY_PN}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_unpack(){
+ unpack ${A}
+}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ mv src/reflection.d src/reflection.d-OFF
+ sed -i \
+ -e 's:"\(title.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(next.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(gameover.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(edificio.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/main.d \
+ -e 's:"\(icon.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/util_sdl.d \
+ -e 's:"\(se_[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(gu_[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(./bullet[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(score.dat[^"]*\)":"'${GAMES_STATEDIR}'/'gu-'\1":g' -i src/gctrl.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r bullet *.bmp *.ogg *.wav || die
+
+ if [ ! -e "${GAMES_STATEDIR}"/gu-score.dat ]
+ then
+ dodir "${GAMES_STATEDIR}"
+ insinto "${GAMES_STATEDIR}"
+ doins "${FILESDIR}"/gu-score.dat || die
+ fperms 660 "${GAMES_STATEDIR}"/gu-score.dat
+ fi
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/gradleunison/metadata.xml b/games-action/gradleunison/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/gradleunison/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/gunroar/Manifest b/games-action/gunroar/Manifest
new file mode 100644
index 0000000..bc0f9f8
--- /dev/null
+++ b/games-action/gunroar/Manifest
@@ -0,0 +1,5 @@
+AUX gunroar-0.15.diff 20725 RMD160 6ffacd9e5d0f109226510751a05613ef1ab9dad2 SHA1 72750b8e32d470458e605d7091fe59a467cd6bc3 SHA256 4c89e4814e18992e59f66d1cbabdf30691dd2c9fb6d4f11b1e41d4ce19404e14
+AUX gunroar.png 3146 RMD160 5661e00eec3d43c7ac39093184b51984f4ee2e9d SHA1 68d49c9e669587cd1ec1db827abcbab8439a67f3 SHA256 a82df7f32e8e96fb5797a96a1a52f5b761417be9ab3df03d9cad09f5f6cdd30b
+DIST gr0_15.zip 5499246 RMD160 9ed84d0a97cf7a0d474d74818646b07ac86daf97 SHA1 5744271617f9c6dd57393e5eaef667bd32de048d SHA256 6ec5cf6f0a28cba738f51020629b2e1c4b6a7298712caa1764f0189c2dec508f
+EBUILD gunroar-0.15.ebuild 1552 RMD160 b6f7d32ca5762b52b3cddd30c9dd153d8f1be598 SHA1 62c35c090c799f64a7abdedc1266bd301d5d6b50 SHA256 fc611059062e5b935222f9182dae9f1ffd5932b59a42cc9afb6e8052ddb21e6c
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/gunroar/files/digest-gunroar-0.15 b/games-action/gunroar/files/digest-gunroar-0.15
new file mode 100644
index 0000000..deaf234
--- /dev/null
+++ b/games-action/gunroar/files/digest-gunroar-0.15
@@ -0,0 +1,3 @@
+MD5 a7ba4b75ff9208131d391f3a5243b5cf gr0_15.zip 5499246
+RMD160 9ed84d0a97cf7a0d474d74818646b07ac86daf97 gr0_15.zip 5499246
+SHA256 6ec5cf6f0a28cba738f51020629b2e1c4b6a7298712caa1764f0189c2dec508f gr0_15.zip 5499246
diff --git a/games-action/gunroar/files/gunroar-0.15.diff b/games-action/gunroar/files/gunroar-0.15.diff
new file mode 100644
index 0000000..ee24506
--- /dev/null
+++ b/games-action/gunroar/files/gunroar-0.15.diff
@@ -0,0 +1,589 @@
+diff -Naur gr/import/opengl.d gr-gentoo/import/opengl.d
+--- gr/import/opengl.d 2005-06-18 02:45:59.000000000 +0200
++++ gr-gentoo/import/opengl.d 2007-09-19 22:41:13.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur gr/import/openglu.d gr-gentoo/import/openglu.d
+--- gr/import/openglu.d 2005-06-18 02:45:59.000000000 +0200
++++ gr-gentoo/import/openglu.d 2007-09-19 22:40:03.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur gr/import/SDL.d gr-gentoo/import/SDL.d
+--- gr/import/SDL.d 2005-06-18 02:45:59.000000000 +0200
++++ gr-gentoo/import/SDL.d 2007-09-19 22:39:40.000000000 +0200
+@@ -20,18 +20,28 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_Keysym;
++public import SDL_Version;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+
+ extern(C):
+
+diff -Naur gr/Makefile gr-gentoo/Makefile
+--- gr/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ gr-gentoo/Makefile 2007-09-19 22:39:40.000000000 +0200
+@@ -0,0 +1,25 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-O -d -release -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -frelease -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/abagames -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=gunroar
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
+diff -Naur gr/src/abagames/gr/bullet.d gr-gentoo/src/abagames/gr/bullet.d
+--- gr/src/abagames/gr/bullet.d 2005-06-18 02:46:00.000000000 +0200
++++ gr-gentoo/src/abagames/gr/bullet.d 2007-09-19 22:39:40.000000000 +0200
+@@ -202,7 +202,7 @@
+ public int removeIndexedBullets(int idx) {
+ int n = 0;
+ foreach (Bullet b; actor) {
+- if (b.exists && b.enemyIdx == idx) {
++ if (b.exists == true && b.enemyIdx == idx) {
+ b.changeToCrystal();
+ n++;
+ }
+@@ -212,7 +212,7 @@
+
+ public void checkShotHit(Vector pos, Collidable shape, Shot shot) {
+ foreach (Bullet b; actor)
+- if (b.exists && b.destructive)
++ if (b.exists == true && b.destructive == true)
+ b.checkShotHit(pos, shape, shot);
+ }
+ }
+diff -Naur gr/src/abagames/gr/enemy.d gr-gentoo/src/abagames/gr/enemy.d
+--- gr/src/abagames/gr/enemy.d 2005-07-17 13:02:45.000000000 +0200
++++ gr-gentoo/src/abagames/gr/enemy.d 2007-09-19 22:39:40.000000000 +0200
+@@ -755,7 +755,7 @@
+ public bool checkShipCollision(EnemyState es, float x, float y, bool largeOnly = false) {
+ if (es.destroyedCnt >= 0 || (largeOnly && type != EnemyType.LARGE))
+ return false;
+- return shape.checkShipCollision(x - es.pos.x, y - es.pos.y, es.deg);
++ return shape.checkShipCollision(x - es.pos.x, y - es.pos.y, es.deg);
+ }
+
+ public bool move(EnemyState es) {
+@@ -1080,7 +1080,7 @@
+ tgs.num = rearMainTurretNum;
+ tgs.alignType = TurretGroupSpec.AlignType.STRAIGHT;
+ tgs.offset.y = size * (0.9f + rand.nextSignedFloat(0.05f));
+- }
++ }
+ TurretSpec pts;
+ if (subTurretNum > 0) {
+ int frontSubTurretNum = (subTurretNum + 2) / 4;
+@@ -1408,7 +1408,7 @@
+
+ public Enemy checkHitShip(float x, float y, Enemy deselection = null, bool largeOnly = false) {
+ foreach (Enemy e; actor)
+- if (e.exists && e != deselection)
++ if (e.exists == true && e != deselection)
+ if (e.checkHitShip(x, y, largeOnly))
+ return e;
+ return null;
+@@ -1416,7 +1416,7 @@
+
+ public bool hasBoss() {
+ foreach (Enemy e; actor)
+- if (e.exists && e.isBoss)
++ if (e.exists == true && e.isBoss == true)
+ return true;
+ return false;
+ }
+diff -Naur gr/src/abagames/gr/gamemanager.d gr-gentoo/src/abagames/gr/gamemanager.d
+--- gr/src/abagames/gr/gamemanager.d 2005-09-11 02:47:40.000000000 +0200
++++ gr-gentoo/src/abagames/gr/gamemanager.d 2007-09-19 22:39:40.000000000 +0200
+@@ -503,7 +503,7 @@
+ MouseState mouseInput = (cast(RecordableMouse) mouse).getState(false);
+ if ((input.button & PadState.Button.A) ||
+ (gameMode == InGameState.GameMode.MOUSE &&
+- (mouseInput.button & MouseState.Button.LEFT))) {
++ (mouseInput.buttona & MouseState.Buttonf.LEFT))) {
+ if (gameOverCnt > 60 && !btnPressed)
+ gameManager.startTitle(true);
+ btnPressed = true;
+diff -Naur gr/src/abagames/gr/mouse.d gr-gentoo/src/abagames/gr/mouse.d
+--- gr/src/abagames/gr/mouse.d 2005-09-11 02:47:40.000000000 +0200
++++ gr-gentoo/src/abagames/gr/mouse.d 2007-09-19 22:39:40.000000000 +0200
+@@ -4,7 +4,8 @@
+ * Copyright 2005 Kenta Cho. Some rights reserved.
+ */
+ module abagames.gr.mouse;
+-
++
++public import SDL_mouse;
+ private import abagames.util.sdl.mouse;
+ private import abagames.util.sdl.screen;
+
+diff -Naur gr/src/abagames/gr/reel.d gr-gentoo/src/abagames/gr/reel.d
+--- gr/src/abagames/gr/reel.d 2005-06-18 02:46:00.000000000 +0200
++++ gr-gentoo/src/abagames/gr/reel.d 2007-09-19 22:39:40.000000000 +0200
+@@ -165,7 +165,8 @@
+ public void targetDeg(float td) {
+ if ((td - _targetDeg) > 1)
+ ofs += 0.1f;
+- return _targetDeg = td;
++ _targetDeg = td;
++ return;
+ }
+
+ public void accelerate() {
+@@ -272,7 +273,7 @@
+ }
+
+ public void set(int n, IndicatorType type, float size, float x, float y) {
+- if (exists && this.type == IndicatorType.SCORE) {
++ if (exists == true && this.type == IndicatorType.SCORE) {
+ if (this.target[targetIdx].flyingTo == FlyingToType.RIGHT)
+ decTargetY();
+ scoreReel.addReelScore(target[targetNum - 1].n);
+diff -Naur gr/src/abagames/gr/ship.d gr-gentoo/src/abagames/gr/ship.d
+--- gr/src/abagames/gr/ship.d 2005-09-11 02:47:40.000000000 +0200
++++ gr-gentoo/src/abagames/gr/ship.d 2007-09-19 22:39:40.000000000 +0200
+@@ -130,7 +130,7 @@
+ float sf = false;
+ for (int i = 0; i < boatNum; i++) {
+ boat[i].move();
+- if (boat[i].hasCollision &&
++ if (boat[i].hasCollision == true &&
+ boat[i].pos.x > field.size.x / 3 && boat[i].pos.y < -field.size.y / 4 * 3)
+ sf = true;
+ }
+@@ -162,7 +162,8 @@
+ public void draw() {
+ for (int i = 0; i < boatNum; i++)
+ boat[i].draw();
+- if (gameMode == InGameState.GameMode.DOUBLE_PLAY && boat[0].hasCollision) {
++ if (gameMode == InGameState.GameMode.DOUBLE_PLAY &&
++ boat[0].hasCollision == true) {
+ Screen.setColor(0.5f, 0.5f, 0.9f, 0.8f);
+ glBegin(GL_LINE_STRIP);
+ glVertex2f(boat[0].pos.x, boat[0].pos.y);
+@@ -183,7 +184,7 @@
+ for (int i = 0; i < boatNum; i++)
+ boat[i].drawFront();
+ }
+-
++
+ public void drawShape() {
+ boat[0].drawShape();
+ }
+@@ -898,13 +899,13 @@
+ foy = 0.01f;
+ fireDeg = atan2(fox, foy);
+ assert(fireDeg <>= 0);
+- if (mouseInput.button & (MouseState.Button.LEFT | MouseState.Button.RIGHT)) {
++ if (mouseInput.buttona & (MouseState.Buttonf.LEFT | MouseState.Buttonf.RIGHT)) {
+ if (fireCnt <= 0) {
+ SoundManager.playSe("shot.wav");
+ int foc = (fireSprCnt % 2) * 2 - 1;
+ float rsd = stickInput.right.vctSize;
+ float fstd = 0.05f;
+- if (mouseInput.button & MouseState.Button.RIGHT)
++ if (mouseInput.buttona & MouseState.Buttonf.RIGHT)
+ fstd += 0.5f;
+ fireSprDeg += (fstd - fireSprDeg) * 0.16f;
+ firePos.x = _pos.x + cos(fireDeg + PI) * 0.2f * foc;
+diff -Naur gr/src/abagames/gr/title.d gr-gentoo/src/abagames/gr/title.d
+--- gr/src/abagames/gr/title.d 2005-09-11 02:47:40.000000000 +0200
++++ gr-gentoo/src/abagames/gr/title.d 2007-09-19 22:39:40.000000000 +0200
+@@ -56,7 +56,7 @@
+ glEnable(GL_TEXTURE_2D);
+ logo.bind();
+ Screen.setColor(1, 1, 1);
+- glBegin(GL_TRIANGLE_FAN);
++ glBegin(GL_TRIANGLE_FAN);
+ glTexCoord2f(0, 0);
+ glVertex2f(0, -63);
+ glTexCoord2f(1, 0);
+@@ -118,7 +118,7 @@
+ if (btnPressedCnt <= 0) {
+ if (((input.button & PadState.Button.A) ||
+ (gameMode == InGameState.GameMode.MOUSE &&
+- (mouseInput.button & MouseState.Button.LEFT))) &&
++ (mouseInput.buttona & MouseState.Buttonf.LEFT))) &&
+ gameMode >= 0)
+ gameManager.startInGame(gameMode);
+ int gmc = 0;
+@@ -145,7 +145,7 @@
+ }
+ if ((input.button & (PadState.Button.A | PadState.Button.B)) ||
+ (input.dir & (PadState.Dir.UP | PadState.Dir.DOWN)) ||
+- (mouseInput.button & MouseState.Button.LEFT))
++ (mouseInput.buttona & MouseState.Buttonf.LEFT))
+ btnPressedCnt = 6;
+ else
+ btnPressedCnt--;
+diff -Naur gr/src/abagames/gr/turret.d gr-gentoo/src/abagames/gr/turret.d
+--- gr/src/abagames/gr/turret.d 2005-07-17 13:02:46.000000000 +0200
++++ gr-gentoo/src/abagames/gr/turret.d 2007-09-19 22:39:40.000000000 +0200
+@@ -142,7 +142,7 @@
+ else if (deg < -spec.turnRange)
+ deg = -spec.turnRange;
+ cnt++;
+- if (field.checkInField(pos) || (parent.isBoss && cnt % 4 == 0))
++ if (field.checkInField(pos) || (parent.isBoss == true && cnt % 4 == 0))
+ appCnt++;
+ if (cnt >= spec.interval) {
+ if (spec.blind || (fabs(od) <= spec.turnSpeed &&
+@@ -155,7 +155,7 @@
+ }
+ if (cnt <= 0 && -cnt % spec.burstInterval == 0 &&
+ ((spec.invisible && field.checkInField(pos)) ||
+- (spec.invisible && parent.isBoss && field.checkInOuterField(pos)) ||
++ (spec.invisible && parent.isBoss == true && field.checkInOuterField(pos)) ||
+ (!spec.invisible && field.checkInFieldExceptTop(pos))) &&
+ pos.dist(shipPos) > spec.minRange) {
+ float bd = baseDeg + deg;
+@@ -913,7 +913,7 @@
+ assert(swingAmpVel <>= 0);
+ assert(distRatio <>= 0);
+ assert(xReverse == 1 || xReverse == -1);
+-
++
+ }
+
+ public this() {
+diff -Naur gr/src/abagames/util/logger.d gr-gentoo/src/abagames/util/logger.d
+--- gr/src/abagames/util/logger.d 2005-07-03 09:05:23.000000000 +0200
++++ gr-gentoo/src/abagames/util/logger.d 2007-09-19 22:39:40.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.util.logger;
+
+-private import std.cstream;
++private import std.stream;
+ private import std.string;
+
+ /**
+@@ -55,29 +55,23 @@
+ public class Logger {
+
+ public static void info(char[] msg, bool nline = true) {
+- if (nline)
+- std.cstream.derr.writeLine(msg);
+- else
+- std.cstream.derr.writeString(msg);
++// stderr.writeString(msg);
+ }
+
+ public static void info(double n, bool nline = true) {
+- if (nline)
+- std.cstream.derr.writeLine(std.string.toString(n));
+- else
+- std.cstream.derr.writeString(std.string.toString(n) ~ " ");
++ // stderr.writeString(std.string.toString(n) ~ " ");
+ }
+
+ public static void error(char[] msg) {
+- std.cstream.derr.writeLine("Error: " ~ msg);
++ //stderr.writeLine("Error: " ~ msg);
+ }
+
+ public static void error(Exception e) {
+- std.cstream.derr.writeLine("Error: " ~ e.toString());
++ // stderr.writeLine("Error: " ~ e.toString());
+ }
+
+ public static void error(Error e) {
+- std.cstream.derr.writeLine("Error: " ~ e.toString());
++ // stderr.writeLine("Error: " ~ e.toString());
+ if (e.next)
+ error(e.next);
+ }
+diff -Naur gr/src/abagames/util/rand.d gr-gentoo/src/abagames/util/rand.d
+--- gr/src/abagames/util/rand.d 2005-06-18 02:46:00.000000000 +0200
++++ gr-gentoo/src/abagames/util/rand.d 2007-09-19 22:39:40.000000000 +0200
+@@ -165,14 +165,14 @@
+
+ void next_state()
+ {
+- uint *p=state;
++ uint *p=state.ptr;
+
+ /* if init_genrand() has not been called, */
+ /* a default initial seed is used */
+ if (initf==0) init_genrand(5489UL);
+
+ left = N;
+- next = state;
++ next = state.ptr;
+
+ for (int j=N-M+1; --j; p++)
+ *p = p[M] ^ TWIST(p[0], p[1]);
+diff -Naur gr/src/abagames/util/sdl/luminous.d gr-gentoo/src/abagames/util/sdl/luminous.d
+--- gr/src/abagames/util/sdl/luminous.d 2005-06-18 02:46:00.000000000 +0200
++++ gr-gentoo/src/abagames/util/sdl/luminous.d 2007-09-19 22:39:40.000000000 +0200
+@@ -32,9 +32,9 @@
+ }
+
+ private void makeLuminousTexture() {
+- uint *data = td;
++ uint *data = td.ptr;
+ int i;
+- memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
++ // memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
+ glGenTextures(1, &luminousTexture);
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 4, luminousTextureWidth, luminousTextureHeight, 0,
+diff -Naur gr/src/abagames/util/sdl/mouse.d gr-gentoo/src/abagames/util/sdl/mouse.d
+--- gr/src/abagames/util/sdl/mouse.d 2005-09-11 02:47:41.000000000 +0200
++++ gr-gentoo/src/abagames/util/sdl/mouse.d 2007-09-19 22:39:40.000000000 +0200
+@@ -7,7 +7,28 @@
+
+ private import std.string;
+ private import std.stream;
+-private import SDL;
++public import SDL_Keysym;
++public import SDL_Version;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+ private import abagames.util.sdl.input;
+ private import abagames.util.sdl.recordableinput;
+ private import abagames.util.sdl.screen;
+@@ -38,6 +59,16 @@
+
+ public void handleEvent(SDL_Event *event) {
+ }
++
++uint SDL_BUTTON(uint X) { return SDL_PRESSED << (X-1); }
++const uint SDL_BUTTON_LEFT = 1;
++const uint SDL_BUTTON_MIDDLE = 2;
++const uint SDL_BUTTON_RIGHT = 3;
++const uint SDL_BUTTON_WHEELUP = 4;
++const uint SDL_BUTTON_WHEELDOWN = 5;
++const uint SDL_BUTTON_LMASK = SDL_PRESSED << (SDL_BUTTON_LEFT - 1);
++const uint SDL_BUTTON_MMASK = SDL_PRESSED << (SDL_BUTTON_MIDDLE - 1);
++const uint SDL_BUTTON_RMASK = SDL_PRESSED << (SDL_BUTTON_RIGHT - 1);
+
+ public MouseState getState() {
+ int mx, my;
+@@ -56,11 +87,11 @@
+ state.y = 0;
+ else if (state.y >= screen.height)
+ state.x = screen.height - 1;*/
+- state.button = 0;
++ state.buttona = 0;
+ if (btn & SDL_BUTTON(1))
+- state.button |= MouseState.Button.LEFT;
++ state.buttona |= MouseState.Buttonf.LEFT;
+ if (btn & SDL_BUTTON(3))
+- state.button |= MouseState.Button.RIGHT;
++ state.buttona |= MouseState.Buttonf.RIGHT;
+ adjustPos(state);
+ return state;
+ }
+@@ -75,11 +106,11 @@
+
+ public class MouseState {
+ public:
+- static enum Button {
++ static enum Buttonf {
+ LEFT = 1, RIGHT = 2,
+ };
+ float x, y;
+- int button;
++ int buttona;
+ private:
+
+ public static MouseState newInstance() {
+@@ -101,27 +132,27 @@
+ public void set(MouseState s) {
+ x = s.x;
+ y = s.y;
+- button = s.button;
++ buttona = s.buttona;
+ }
+
+ public void clear() {
+- button = 0;
++ buttona = 0;
+ }
+
+ public void read(File fd) {
+ fd.read(x);
+ fd.read(y);
+- fd.read(button);
++ fd.read(buttona);
+ }
+
+ public void write(File fd) {
+ fd.write(x);
+ fd.write(y);
+- fd.write(button);
++ fd.write(buttona);
+ }
+
+ public bool equals(MouseState s) {
+- if (x == s.x && y == s.y && button == s.button)
++ if (x == s.x && y == s.y && buttona == s.buttona)
+ return true;
+ else
+ return false;
+diff -Naur gr/src/abagames/util/sdl/pad.d gr-gentoo/src/abagames/util/sdl/pad.d
+--- gr/src/abagames/util/sdl/pad.d 2005-07-03 09:05:23.000000000 +0200
++++ gr-gentoo/src/abagames/util/sdl/pad.d 2007-09-19 22:39:40.000000000 +0200
+@@ -49,7 +49,7 @@
+ x = SDL_JoystickGetAxis(stick, 0);
+ y = SDL_JoystickGetAxis(stick, 1);
+ }
+- if (keys[SDLK_RIGHT] == SDL_PRESSED || keys[SDLK_KP6] == SDL_PRESSED ||
++ if (keys[SDLK_RIGHT] == SDL_PRESSED || keys[SDLK_KP6] == SDL_PRESSED ||
+ keys[SDLK_d] == SDL_PRESSED || keys[SDLK_l] == SDL_PRESSED ||
+ x > JOYSTICK_AXIS)
+ state.dir |= PadState.Dir.RIGHT;
+@@ -77,7 +77,7 @@
+ SDL_JoystickGetButton(stick, 9) + SDL_JoystickGetButton(stick, 10);
+ }
+ if (keys[SDLK_z] == SDL_PRESSED || keys[SDLK_PERIOD] == SDL_PRESSED ||
+- keys[SDLK_LCTRL] == SDL_PRESSED || keys[SDLK_RCTRL] == SDL_PRESSED ||
++ keys[SDLK_LCTRL] == SDL_PRESSED || keys[SDLK_RCTRL] == SDL_PRESSED ||
+ btn1) {
+ if (!buttonReversed)
+ state.button |= PadState.Button.A;
+@@ -162,6 +162,8 @@
+
+ public class RecordablePad: Pad {
+ mixin RecordableInput!(PadState);
++ public this() {
++ }
+ private:
+
+ public PadState getState(bool doRecord = true) {
+diff -Naur gr/src/abagames/util/sdl/texture.d gr-gentoo/src/abagames/util/sdl/texture.d
+--- gr/src/abagames/util/sdl/texture.d 2005-07-03 09:05:23.000000000 +0200
++++ gr-gentoo/src/abagames/util/sdl/texture.d 2007-09-19 22:39:40.000000000 +0200
+@@ -103,13 +103,13 @@
+ }
+ glBindTexture(GL_TEXTURE_2D, num + ti);
+ gluBuild2DMipmaps(GL_TEXTURE_2D, 4, panelWidth, panelHeight,
+- GL_RGBA, GL_UNSIGNED_BYTE, pixels);
++ GL_RGBA, GL_UNSIGNED_BYTE, pixels.ptr);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ if (maskColor != 0xffffffffu) {
+ glBindTexture(GL_TEXTURE_2D, maskNum + ti);
+ gluBuild2DMipmaps(GL_TEXTURE_2D, 4, panelWidth, panelHeight,
+- GL_RGBA, GL_UNSIGNED_BYTE, maskPixels);
++ GL_RGBA, GL_UNSIGNED_BYTE, maskPixels.ptr);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ }
+diff -Naur gr/src/abagames/util/sdl/twinstick.d gr-gentoo/src/abagames/util/sdl/twinstick.d
+--- gr/src/abagames/util/sdl/twinstick.d 2006-03-18 03:42:09.000000000 +0100
++++ gr-gentoo/src/abagames/util/sdl/twinstick.d 2007-09-19 22:39:40.000000000 +0200
+@@ -174,6 +174,8 @@
+
+ public class RecordableTwinStick: TwinStick {
+ mixin RecordableInput!(TwinStickState);
++ public this() {
++ }
+ private:
+
+ public TwinStickState getState(bool doRecord = true) {
diff --git a/games-action/gunroar/files/gunroar.png b/games-action/gunroar/files/gunroar.png
new file mode 100644
index 0000000..26aff3e
--- /dev/null
+++ b/games-action/gunroar/files/gunroar.png
Binary files differ
diff --git a/games-action/gunroar/gunroar-0.15.ebuild b/games-action/gunroar/gunroar-0.15.ebuild
new file mode 100644
index 0000000..51d5698
--- /dev/null
+++ b/games-action/gunroar/gunroar-0.15.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=gr
+MY_PV=${PV//./_}
+
+DESCRIPTION="Guns, Guns, Guns! 360-degree gunboat shooter, 'Gunroar'"
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/gr_e.html"
+SRC_URI="http://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer"
+
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(gr.prf[^"]*\)":"'${GAMES_STATEDIR}'/'${PN}'/\1":g' -i src/abagames/gr/prefmanager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+ dodir "${GAMES_STATEDIR}/${PN}" "${GAMES_STATEDIR}/${PN}/replay"
+ local statedir="${GAMES_STATEDIR}"/${PN}
+
+ if [ ! -e ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf ]; then
+ touch ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf
+ chmod ug+rw ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf
+ fperms 660 ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r images sounds || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/gunroar/metadata.xml b/games-action/gunroar/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/gunroar/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/gunroarhi/Manifest b/games-action/gunroarhi/Manifest
new file mode 100644
index 0000000..46fc6a1
--- /dev/null
+++ b/games-action/gunroarhi/Manifest
@@ -0,0 +1,5 @@
+AUX gunroarhi-0.30.diff 5154 RMD160 c1aaf017b13622a8cf9474ec34f245b96e8cd601 SHA1 662f35305195cc68b9b89cc16b54e70723e7c344 SHA256 0aba15b7e043e40f2f033ff619f909d9f371b670c2d6d3f4d546a5d9a2ff447a
+AUX gunroarhi.png 3544 RMD160 f98b11eb0250eaf0bd859d8b3aad3545d52e404e SHA1 8694da4a1fbb34cf7dedc7ead192f62d2b43350a SHA256 c855b79b3c1c95da5fcdf592261f56568114a03252821f71a2cd9a1e60c15e65
+DIST gr_hi0_30.zip 5502395 RMD160 d321ba0f8a4eaa2f1f84c6c3a48f4d29f43c7f07 SHA1 4238a995f5d766f22ea396ccce86036886b32205 SHA256 c2adc4d1aa616736e968d4214a2bc52b0d2a21ae1dbbe5a01e9c57826901692a
+EBUILD gunroarhi-0.30.ebuild 1497 RMD160 10c59046203f579eb9578e309faadfbcb0318d23 SHA1 422f115e24b06338f093f85f61329cedf0fada78 SHA256 10a24bcf9ff65efd269996762c6cc148adb51adfb5aad8521abcab2e26a42674
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/gunroarhi/files/digest-gunroarhi-0.30 b/games-action/gunroarhi/files/digest-gunroarhi-0.30
new file mode 100644
index 0000000..28c60c0
--- /dev/null
+++ b/games-action/gunroarhi/files/digest-gunroarhi-0.30
@@ -0,0 +1,3 @@
+MD5 0702fc87bcf9d77530af0e84e8a94d7a gr_hi0_30.zip 5502395
+RMD160 d321ba0f8a4eaa2f1f84c6c3a48f4d29f43c7f07 gr_hi0_30.zip 5502395
+SHA256 c2adc4d1aa616736e968d4214a2bc52b0d2a21ae1dbbe5a01e9c57826901692a gr_hi0_30.zip 5502395
diff --git a/games-action/gunroarhi/files/gunroarhi-0.30.diff b/games-action/gunroarhi/files/gunroarhi-0.30.diff
new file mode 100644
index 0000000..0acba13
--- /dev/null
+++ b/games-action/gunroarhi/files/gunroarhi-0.30.diff
@@ -0,0 +1,153 @@
+diff -Naur gr_hi/import/opengl.d gr_hi-gentoo/import/opengl.d
+--- gr_hi/import/opengl.d 2005-06-18 02:46:00.000000000 +0200
++++ gr_hi-gentoo/import/opengl.d 2007-09-20 08:18:12.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur gr_hi/import/openglu.d gr_hi-gentoo/import/openglu.d
+--- gr_hi/import/openglu.d 2005-06-18 02:46:00.000000000 +0200
++++ gr_hi-gentoo/import/openglu.d 2007-09-20 08:15:01.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur gr_hi/import/SDL.d gr_hi-gentoo/import/SDL.d
+--- gr_hi/import/SDL.d 2005-06-18 02:46:00.000000000 +0200
++++ gr_hi-gentoo/import/SDL.d 2007-09-20 08:14:23.000000000 +0200
+@@ -20,18 +20,28 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_Keysym;
++public import SDL_Version;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+
+ extern(C):
+
+diff -Naur gr_hi/Makefile gr_hi-gentoo/Makefile
+--- gr_hi/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ gr_hi-gentoo/Makefile 2007-09-20 08:14:23.000000000 +0200
+@@ -0,0 +1,25 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-O -d -release -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -frelease -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/abagames -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=gunroarhi
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
+diff -Naur gr_hi/src/abagames/util/sdl/luminous.d gr_hi-gentoo/src/abagames/util/sdl/luminous.d
+--- gr_hi/src/abagames/util/sdl/luminous.d 2005-06-18 02:46:00.000000000 +0200
++++ gr_hi-gentoo/src/abagames/util/sdl/luminous.d 2007-09-20 08:14:23.000000000 +0200
+@@ -34,7 +34,7 @@
+ private void makeLuminousTexture() {
+ uint *data = td;
+ int i;
+- memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
++ // memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
+ glGenTextures(1, &luminousTexture);
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 4, luminousTextureWidth, luminousTextureHeight, 0,
+diff -Naur gr_hi/src/abagames/util/sdl/mouse.d gr_hi-gentoo/src/abagames/util/sdl/mouse.d
+--- gr_hi/src/abagames/util/sdl/mouse.d 2005-09-11 02:47:42.000000000 +0200
++++ gr_hi-gentoo/src/abagames/util/sdl/mouse.d 2007-09-20 08:14:23.000000000 +0200
+@@ -11,6 +11,17 @@
+ private import abagames.util.sdl.input;
+ private import abagames.util.sdl.recordableinput;
+ private import abagames.util.sdl.screen;
++
++uint SDL_BUTTON(uint X) { return SDL_PRESSED << (X-1); }
++const uint SDL_BUTTON_LEFT = 1;
++const uint SDL_BUTTON_MIDDLE = 2;
++const uint SDL_BUTTON_RIGHT = 3;
++const uint SDL_BUTTON_WHEELUP = 4;
++const uint SDL_BUTTON_WHEELDOWN = 5;
++const uint SDL_BUTTON_LMASK = SDL_PRESSED << (SDL_BUTTON_LEFT - 1);
++const uint SDL_BUTTON_MMASK = SDL_PRESSED << (SDL_BUTTON_MIDDLE - 1);
++const uint SDL_BUTTON_RMASK = SDL_PRESSED << (SDL_BUTTON_RIGHT - 1);
++
+
+ /**
+ * Mouse input.
diff --git a/games-action/gunroarhi/files/gunroarhi.png b/games-action/gunroarhi/files/gunroarhi.png
new file mode 100644
index 0000000..68943a2
--- /dev/null
+++ b/games-action/gunroarhi/files/gunroarhi.png
Binary files differ
diff --git a/games-action/gunroarhi/gunroarhi-0.30.ebuild b/games-action/gunroarhi/gunroarhi-0.30.ebuild
new file mode 100644
index 0000000..0ccd94b
--- /dev/null
+++ b/games-action/gunroarhi/gunroarhi-0.30.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=gr_hi
+MY_PV=${PV//./_}
+
+DESCRIPTION="Guns, Guns, Guns! 360-degree gunboat shooter, fork of ABAs 'Gunroar'"
+HOMEPAGE="http://www.edit.ne.jp/~otoyan/soft/gr_hi.html"
+SRC_URI="http://www.edit.ne.jp/~otoyan/soft/gr_hi/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(gr.prf[^"]*\)":"'${GAMES_STATEDIR}'/'${PN}'/\1":g' -i src/abagames/gr/prefmanager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+ dodir "${GAMES_STATEDIR}/${PN}" "${GAMES_STATEDIR}/${PN}/replay"
+ local statedir="${GAMES_STATEDIR}"/${PN}
+
+ if [ ! -e ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf ]; then
+ touch ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf
+ chmod ug+rw ${D}"${GAMES_STATEDIR}"/${PN}/gr.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r images sounds || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/gunroarhi/metadata.xml b/games-action/gunroarhi/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/gunroarhi/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/mucade/Manifest b/games-action/mucade/Manifest
new file mode 100644
index 0000000..997b0e7
--- /dev/null
+++ b/games-action/mucade/Manifest
@@ -0,0 +1,5 @@
+AUX mucade-0.11.diff 14316 RMD160 3440830b1871d9b108db4d109a2fd16ec3469acf SHA1 62f2e383ce102173363d1b1c9f05b687f081ef45 SHA256 058a14cebffc3632bb646fdda028140ad8115d6d3beef292b61ff893ebca9cbf
+AUX mucade.png 3122 RMD160 6a96d66ad64836ffc387daaf6003fcaee0db2f0e SHA1 8a583e274e921e19c77f715e2932f9fba9cae234 SHA256 356711fccdad5cd3f1738381b090db9db7054cb24fc608e7a5a8f30e0b9029c6
+DIST mcd0_11.zip 6315975 RMD160 da94578f49e401f8503aa9ab11b40730ecd15e36 SHA1 cdd326b85eaa3af17c60e4adb629d5076e8c9a4f SHA256 e5acd67e06d765c63ea7dc7df6488ca3edd3410a05bd995b3842fe8e3b78451e
+EBUILD mucade-0.11.ebuild 1609 RMD160 fc2692ee8d4ebf9c444a9daca857b907dd5f0841 SHA1 95daddc875fe2b70dfb82c11d2fafcd5f106c2ec SHA256 b35d5e1e1386a27f71be64c704d5fd7d621350b21e1e56b7245ea37d97f9a389
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/mucade/files/digest-mucade-0.11 b/games-action/mucade/files/digest-mucade-0.11
new file mode 100644
index 0000000..e550e2f
--- /dev/null
+++ b/games-action/mucade/files/digest-mucade-0.11
@@ -0,0 +1,3 @@
+MD5 59915ec27f7899cdf1e417987ead4ace mcd0_11.zip 6315975
+RMD160 da94578f49e401f8503aa9ab11b40730ecd15e36 mcd0_11.zip 6315975
+SHA256 e5acd67e06d765c63ea7dc7df6488ca3edd3410a05bd995b3842fe8e3b78451e mcd0_11.zip 6315975
diff --git a/games-action/mucade/files/mucade-0.11.diff b/games-action/mucade/files/mucade-0.11.diff
new file mode 100644
index 0000000..e06ea81
--- /dev/null
+++ b/games-action/mucade/files/mucade-0.11.diff
@@ -0,0 +1,454 @@
+diff -Naur mcd/import/ode/common.d mcd-gentoo/import/ode/common.d
+--- mcd/import/ode/common.d 2006-02-19 05:57:26.000000000 +0100
++++ mcd-gentoo/import/ode/common.d 2007-09-20 08:21:23.000000000 +0200
+@@ -24,7 +24,8 @@
+ private import std.c.math;
+ private import std.c.stdlib;
+ import ode.config;
+-import ode.error;
++import ode.error;
++import ode.objects;
+
+ extern(C):
+
+@@ -68,8 +69,8 @@
+
+ /* floating point data type, vector, matrix and quaternion types */
+
+-alias double dReal;
+-
++//alias double dReal;
++alias float dReal;
+
+ /* round an integer up to a multiple of 4, except that 0 and 1 are unmodified
+ * (used to compute matrix leading dimensions)
+@@ -119,8 +120,8 @@
+ struct dxWorld; /* dynamics world */
+ struct dxSpace; /* collision space */
+ struct dxBody; /* rigid body (dynamics object) */
+-struct dxGeom; /* geometry (collision object) */
+-struct dxJoint;
++struct dxGeom { };
++struct dxJoint { };
+ struct dxJointNode;
+ struct dxJointGroup;
+
+diff -Naur mcd/import/ode/ode.d mcd-gentoo/import/ode/ode.d
+--- mcd/import/ode/ode.d 2006-02-19 05:57:26.000000000 +0100
++++ mcd-gentoo/import/ode/ode.d 2007-09-20 08:21:23.000000000 +0200
+@@ -23,21 +23,21 @@
+
+ /* include *everything* here */
+
+-import ode.config;
+-import ode.compatibility;
+-import ode.common;
+-import ode.contact;
+-import ode.error;
+-import ode.memory;
+-import ode.odemath;
+-import ode.matrix;
+-import ode.timer;
+-import ode.rotation;
+-import ode.mass;
+-import ode.misc;
+-import ode.objects;
++public import ode.config;
++public import ode.compatibility;
++public import ode.common;
++public import ode.contact;
++public import ode.error;
++public import ode.memory;
++public import ode.odemath;
++public import ode.matrix;
++public import ode.timer;
++public import ode.rotation;
++public import ode.mass;
++public import ode.misc;
++public import ode.objects;
+ //import ode.odecpp;
+-import ode.collision_space;
+-import ode.collision;
++public import ode.collision_space;
++public import ode.collision;
+ //import ode.odecpp_collision;
+-import ode.export_dif;
++public import ode.export_dif;
+diff -Naur mcd/import/opengl.d mcd-gentoo/import/opengl.d
+--- mcd/import/opengl.d 2006-02-19 05:57:25.000000000 +0100
++++ mcd-gentoo/import/opengl.d 2007-09-20 08:21:54.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur mcd/import/openglu.d mcd-gentoo/import/openglu.d
+--- mcd/import/openglu.d 2006-02-19 05:57:25.000000000 +0100
++++ mcd-gentoo/import/openglu.d 2007-09-20 08:22:01.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur mcd/import/SDL.d mcd-gentoo/import/SDL.d
+--- mcd/import/SDL.d 2006-02-19 05:57:25.000000000 +0100
++++ mcd-gentoo/import/SDL.d 2007-09-20 08:21:23.000000000 +0200
+@@ -20,18 +20,28 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_Keysym;
++public import SDL_Version;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+
+ extern(C):
+
+diff -Naur mcd/Makefile mcd-gentoo/Makefile
+--- mcd/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ mcd-gentoo/Makefile 2007-09-20 08:21:23.000000000 +0200
+@@ -0,0 +1,26 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-O -g -debug -d -release -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -frelease -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/abagames -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d $(wildcard import/ode/*.d)
++OBJS=$(SOURCES:.d=.o)
++EXE=mucade
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer -lstdc++ -lode
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
++
+diff -Naur mcd/src/abagames/mcd/barrage.d mcd-gentoo/src/abagames/mcd/barrage.d
+--- mcd/src/abagames/mcd/barrage.d 2006-03-18 03:42:50.000000000 +0100
++++ mcd-gentoo/src/abagames/mcd/barrage.d 2007-09-20 08:21:23.000000000 +0200
+@@ -62,7 +62,8 @@
+
+ public static void load() {
+ char[][] dirs = listdir(BARRAGE_DIR_NAME);
+- foreach (char[] dirName; dirs) {
++ foreach (char[] dirName; dirs) {
++ parser[dirName] = null;
+ char[][] files = listdir(BARRAGE_DIR_NAME ~ "/" ~ dirName);
+ foreach (char[] fileName; files) {
+ if (getExt(fileName) != "xml")
+diff -Naur mcd/src/abagames/mcd/enemy.d mcd-gentoo/src/abagames/mcd/enemy.d
+--- mcd/src/abagames/mcd/enemy.d 2006-03-18 03:42:50.000000000 +0100
++++ mcd-gentoo/src/abagames/mcd/enemy.d 2007-09-20 08:21:23.000000000 +0200
+@@ -7,7 +7,20 @@
+
+ private import std.math;
+ private import opengl;
+-private import ode.ode;
++private import ode.ode;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.vector;
+ private import abagames.util.rand;
+ private import abagames.util.math;
+diff -Naur mcd/src/abagames/mcd/shape.d mcd-gentoo/src/abagames/mcd/shape.d
+--- mcd/src/abagames/mcd/shape.d 2006-02-19 05:57:26.000000000 +0100
++++ mcd-gentoo/src/abagames/mcd/shape.d 2007-09-20 08:21:23.000000000 +0200
+@@ -6,7 +6,20 @@
+ module abagames.mcd.shape;
+
+ private import opengl;
+-private import ode.ode;
++private import ode.ode;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.vector;
+ private import abagames.util.sdl.displaylist;
+ private import abagames.util.ode.odeactor;
+@@ -34,7 +47,7 @@
+ }
+
+ public void setMass(OdeActor oa, Vector3 sizeScale = null, float massScale = 1) {
+- dMass m;
++ dMass m = void;
+ dMassSetZero(&m);
+ addMass(&m, sizeScale, massScale);
+ oa.setMass(m);
+@@ -87,7 +100,7 @@
+ }
+
+ public void addMass(dMass* m, Vector3 sizeScale = null, float massScale = 1) {
+- dMass sm;
++ dMass sm = void;
+ if (sizeScale) {
+ dMassSetBox(&sm, 1, size.x * sizeScale.x, size.y * sizeScale.y, size.z * sizeScale.z);
+ dMassTranslate(&sm, pos.x * sizeScale.x, pos.y * sizeScale.y, pos.z * sizeScale.z);
+@@ -436,7 +449,7 @@
+
+ public void beginRecord() {
+ posIdx = 0;
+- glGetFloatv(GL_MODELVIEW_MATRIX, m);
++ glGetFloatv(GL_MODELVIEW_MATRIX, m.ptr);
+ }
+
+ public void setPos(Vector3 p) {
+diff -Naur mcd/src/abagames/mcd/ship.d mcd-gentoo/src/abagames/mcd/ship.d
+--- mcd/src/abagames/mcd/ship.d 2006-03-18 03:42:50.000000000 +0100
++++ mcd-gentoo/src/abagames/mcd/ship.d 2007-09-20 08:21:23.000000000 +0200
+@@ -7,7 +7,20 @@
+
+ private import std.math;
+ private import opengl;
+-private import ode.ode;
++private import ode.ode;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.vector;
+ private import abagames.util.rand;
+ private import abagames.util.math;
+@@ -520,7 +533,7 @@
+ Ship ship;
+ ParticlePool particles;
+ ConnectedParticlePool connectedParticles;
+- dMass m;
++ dMass m = void;
+ Shape shape;
+ LinePoint linePoint;
+ dJointID joint;
+diff -Naur mcd/src/abagames/mcd/spec.d mcd-gentoo/src/abagames/mcd/spec.d
+--- mcd/src/abagames/mcd/spec.d 2006-03-18 03:42:50.000000000 +0100
++++ mcd-gentoo/src/abagames/mcd/spec.d 2007-09-20 08:21:23.000000000 +0200
+@@ -7,7 +7,21 @@
+
+ private import std.math;
+ private import opengl;
+-private import ode.ode;
++private import ode.ode;
++import ode.objects;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.vector;
+ private import abagames.util.math;
+ private import abagames.util.ode.odeactor;
+diff -Naur mcd/src/abagames/mcd/stagemanager.d mcd-gentoo/src/abagames/mcd/stagemanager.d
+--- mcd/src/abagames/mcd/stagemanager.d 2006-03-18 03:42:50.000000000 +0100
++++ mcd-gentoo/src/abagames/mcd/stagemanager.d 2007-09-20 08:21:23.000000000 +0200
+@@ -9,7 +9,20 @@
+ private import std.string;
+ private import std.stream;
+ private import opengl;
+-private import ode.ode;
++private import ode.ode;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.tokenizer;
+ private import abagames.util.iterator;
+ private import abagames.util.rand;
+diff -Naur mcd/src/abagames/util/ode/odeactor.d mcd-gentoo/src/abagames/util/ode/odeactor.d
+--- mcd/src/abagames/util/ode/odeactor.d 2006-02-19 05:57:26.000000000 +0100
++++ mcd-gentoo/src/abagames/util/ode/odeactor.d 2007-09-20 08:21:23.000000000 +0200
+@@ -7,7 +7,20 @@
+
+ private import std.math;
+ private import opengl;
+-private import ode.ode;
++private import ode.ode;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.actor;
+ private import abagames.util.vector;
+ private import abagames.util.ode.world;
+diff -Naur mcd/src/abagames/util/ode/world.d mcd-gentoo/src/abagames/util/ode/world.d
+--- mcd/src/abagames/util/ode/world.d 2006-02-22 23:27:47.000000000 +0100
++++ mcd-gentoo/src/abagames/util/ode/world.d 2007-09-20 08:21:23.000000000 +0200
+@@ -5,7 +5,20 @@
+ */
+ module abagames.util.ode.world;
+
+-private import ode.ode;
++private import ode.ode;
++import ode.config;
++import ode.compatibility;
++import ode.common;
++import ode.contact;
++import ode.error;
++import ode.memory;
++import ode.odemath;
++import ode.matrix;
++import ode.timer;
++import ode.rotation;
++import ode.mass;
++import ode.misc;
++import ode.objects;
+ private import abagames.util.ode.odeactor;
+
+ /**
+diff -Naur mcd/src/abagames/util/sdl/texture.d mcd-gentoo/src/abagames/util/sdl/texture.d
+--- mcd/src/abagames/util/sdl/texture.d 2006-02-19 05:57:26.000000000 +0100
++++ mcd-gentoo/src/abagames/util/sdl/texture.d 2007-09-20 08:21:23.000000000 +0200
+@@ -103,13 +103,13 @@
+ }
+ glBindTexture(GL_TEXTURE_2D, num + ti);
+ gluBuild2DMipmaps(GL_TEXTURE_2D, 4, panelWidth, panelHeight,
+- GL_RGBA, GL_UNSIGNED_BYTE, pixels);
++ GL_RGBA, GL_UNSIGNED_BYTE, pixels.ptr);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ if (maskColor != 0xffffffffu) {
+ glBindTexture(GL_TEXTURE_2D, maskNum + ti);
+ gluBuild2DMipmaps(GL_TEXTURE_2D, 4, panelWidth, panelHeight,
+- GL_RGBA, GL_UNSIGNED_BYTE, maskPixels);
++ GL_RGBA, GL_UNSIGNED_BYTE, maskPixels.ptr);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ }
+diff -Naur mcd/src/abagames/util/sdl/twinstickpad.d mcd-gentoo/src/abagames/util/sdl/twinstickpad.d
+--- mcd/src/abagames/util/sdl/twinstickpad.d 2006-03-18 04:36:00.000000000 +0100
++++ mcd-gentoo/src/abagames/util/sdl/twinstickpad.d 2007-09-20 08:21:23.000000000 +0200
+@@ -8,7 +8,8 @@
+ private import std.string;
+ private import std.stream;
+ private import std.math;
+-private import SDL;
++private import SDL;
++private import SDL_keyboard;
+ private import abagames.util.vector;
+ private import abagames.util.sdl.input;
+ private import abagames.util.sdl.recordableinput;
diff --git a/games-action/mucade/files/mucade.png b/games-action/mucade/files/mucade.png
new file mode 100644
index 0000000..a108c7c
--- /dev/null
+++ b/games-action/mucade/files/mucade.png
Binary files differ
diff --git a/games-action/mucade/metadata.xml b/games-action/mucade/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/mucade/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/mucade/mucade-0.11.ebuild b/games-action/mucade/mucade-0.11.ebuild
new file mode 100644
index 0000000..0b3ddc2
--- /dev/null
+++ b/games-action/mucade/mucade-0.11.ebuild
@@ -0,0 +1,61 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=mcd
+MY_PV=${PV//./_}
+
+DESCRIPTION="The Physics Centipede Invasion. Smashup waggly shmup, 'Mu-cade'."
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/mcd_e.html"
+SRC_URI="http://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ <dev-games/ode-10.1
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/texture.d \
+ -e 's:"\(barrage[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/mcd/barrage.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(mcd.prf[^"]*\)":"'${GAMES_STATEDIR}'/'${PN}'/\1":g' -i src/abagames/mcd/prefmanager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+ dodir "${GAMES_STATEDIR}/${PN}" "${GAMES_STATEDIR}/${PN}/replay"
+
+ if [ ! -e ${D}"${GAMES_STATEDIR}"/${PN}/mcd.prf ]; then
+ touch ${D}"${GAMES_STATEDIR}"/${PN}/mcd.prf
+ chmod ug+rw ${D}"${GAMES_STATEDIR}"/${PN}/mcd.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r barrage images sounds || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/openlierox/ChangeLog b/games-action/openlierox/ChangeLog
new file mode 100644
index 0000000..b10a34e
--- /dev/null
+++ b/games-action/openlierox/ChangeLog
@@ -0,0 +1,28 @@
+# ChangeLog for games-action/openlierox
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: $
+
+ 21 Jan 2009; Piotr Szymaniak <lazy_bum@o2.pl>
+ openlierox-0.57_beta8.ebuild:
+ Added missing || die.
+
+ 20 Jan 2009; Piotr Szymaniak <lazy_bum@o2.pl>
+ -openlierox-0.57_beta5.ebuild, openlierox-0.57_beta8.ebuild:
+ Ported to EAPI=2.
+
+ 12 Oct 2008; Piotr Szymaniak <lazy_bum@o2.pl>
+ +openlierox-0.57_beta8.ebuild:
+ Version bump.
+
+ 10 Aug 2008; Piotr Szymaniak <lazy_bum@o2.pl>
+ openlierox-0.57_beta5.ebuild:
+ Fixed some repoman reported errors.
+
+ 01 May 2008; Piotr Szymaniak <lazy_bum@o2.pl>
+ openlierox-0.57_beta5.ebuild:
+ Remove icon extension from desktop entry to match Icon Theme Specification.
+
+ 15 Mar 2008; Piotr Szymaniak <lazy_bum@o2.pl>
+ -openlierox-0.57_beta3.ebuild, +openlierox-0.57_beta5.ebuild:
+ Version bump (bug #164009)
+
diff --git a/games-action/openlierox/Manifest b/games-action/openlierox/Manifest
new file mode 100644
index 0000000..f4eae68
--- /dev/null
+++ b/games-action/openlierox/Manifest
@@ -0,0 +1,3 @@
+DIST OpenLieroX_0.57_beta8.src.tar.bz2 49121319 RMD160 0b4753e91cae2e9c70097721a1f691f2695d747e SHA1 e1b3a8366e8e163416214359a7fd25e9d172b4a9 SHA256 0dd9c624a5d6a804f354263327dd4052f3b4d464b90e318e6255ec12d70077a8
+EBUILD openlierox-0.57_beta8.ebuild 1682 RMD160 803f4a5c628d04f2db7942ec5e8d0b457cb40f69 SHA1 1b77be754c01576b8a9e5486dff421693f37b87d SHA256 65f6388f6d1d8deeafb154a45f43c18ac259eebf48aca37976ab315227e2b9fb
+MISC ChangeLog 879 RMD160 9f5cfe0cd5661a1fa7167dccf2464d5a7475d874 SHA1 9a040cad92a3b87184688cbcf132aa0246010ac9 SHA256 33d630f41ac2990df4728ecafc96f728b5b9b6dbe41c2f60a6b8325dbaa17339
diff --git a/games-action/openlierox/openlierox-0.57_beta8.ebuild b/games-action/openlierox/openlierox-0.57_beta8.ebuild
new file mode 100644
index 0000000..8bc094c
--- /dev/null
+++ b/games-action/openlierox/openlierox-0.57_beta8.ebuild
@@ -0,0 +1,65 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI=2
+
+inherit eutils toolchain-funcs games
+
+DESCRIPTION="A real-time excessive Worms-clone"
+HOMEPAGE="http://openlierox.sourceforge.net/"
+SRC_URI="mirror://sourceforge/openlierox/OpenLieroX_${PV}.src.tar.bz2"
+
+LICENSE="LGPL-2"
+SLOT="0"
+KEYWORDS="~ppc ~x86 ~amd64"
+IUSE="X debug"
+
+RDEPEND="media-libs/libsdl
+ media-libs/sdl-mixer
+ media-libs/sdl-image
+ dev-games/hawknl
+ media-libs/gd
+ dev-libs/libxml2
+ dev-libs/libzip
+ X? ( x11-libs/libX11
+ media-libs/libsdl[X] )"
+
+DEPEND="${RDEPEND}"
+
+MY_PN=OpenLieroX
+MY_P=${MY_PN}_${PV}
+S=${WORKDIR}/${MY_PN}
+
+src_compile() {
+ # SYSTEM_DATA_DIR/OpenLieroX will be the search path
+ # the compile.sh will also take care of CXXFLAGS
+ SYSTEM_DATA_DIR="${GAMES_DATADIR}" \
+ COMPILER=$(tc-getCXX) \
+ DEBUG=$(use debug && echo 1 || echo 0) \
+ X11=$(use X && echo 1 || echo 0) \
+ VERSION=${PV} \
+ ./compile.sh || die "compilation failed"
+}
+
+src_install() {
+ einfo "copying binary ..."
+ dogamesbin bin/openlierox || die "cannot copy binary"
+
+ einfo "copying gamedata-files ..."
+ # HINT: the app uses case-insensitive file-handling
+ insinto "${GAMES_DATADIR}"/${PN}/
+ doins -r share/gamedir/* || die "failed while copying gamedata"
+
+ einfo "installing doc ..."
+ dodoc doc/README doc/ChangeLog \
+ doc/Development doc/TODO || die "dodoc failed"
+ insinto "/usr/share/doc/${PF}"
+ doins -r doc/original_lx_docs || die "doins failed"
+
+ einfo "creating icon and desktop entry ..."
+ doicon share/OpenLieroX.* || die "doicon failed"
+ make_desktop_entry openlierox OpenLieroX OpenLieroX.svg "Game;ActionGame;ArcadeGame;"
+
+ prepgamesdirs
+}
diff --git a/games-action/parsec47/Manifest b/games-action/parsec47/Manifest
new file mode 100644
index 0000000..e020554
--- /dev/null
+++ b/games-action/parsec47/Manifest
@@ -0,0 +1,6 @@
+AUX p47.prf 368 RMD160 855abb93a708507b383f12de0298bd5efb784a75 SHA1 fb23a51a8958dde65c3cad984ba9db02034cfe97 SHA256 4af09b3decae27d752dfb64d394f87ba3543df42eb4ad0adaa6b2edd5dde2bd9
+AUX parsec47-0.2.diff 115201 RMD160 c2ceb6c4a89f09f06dad30d0acdecda6244511ca SHA1 e074cf6504eef7e0aa3aea549bc6b7f881453b88 SHA256 02a3fd93f2c4ee031b22ab6055af5f89dcd7982a6b75c2c06cd1dc5c715c4250
+AUX parsec47.png 2792 RMD160 c78f285ee2fdf07f02f08197d96e54494d1b2cb5 SHA1 51b543967c8b02a08dea3b5c7c3b5b709fb59522 SHA256 c8b8b0fc49ec013223c5af34316db694889fd2d62619e7a564daf3ebc4c095e4
+DIST p47_0_2.zip 4783134 RMD160 2760214a8f0e69c3c415458019a753d8c0661f4a SHA1 81d0443cfa205c61c24362e99c34f6690d561b6d SHA256 1a944185b4594e7f2681204680ec4d885109f56e2156a24b090638c38df47ef0
+EBUILD parsec47-0.2.ebuild 2917 RMD160 383ce231e416a339ad32d91c147aa32583dc2854 SHA1 1f32aba1a8df2f15f1e48f769ae8e3d3526f155b SHA256 d5b1567df269ca8ccc9e29925554f85387f1acea69426f7979bc5fb384a7303b
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/parsec47/files/digest-parsec47-0.2 b/games-action/parsec47/files/digest-parsec47-0.2
new file mode 100644
index 0000000..20f0ebd
--- /dev/null
+++ b/games-action/parsec47/files/digest-parsec47-0.2
@@ -0,0 +1,3 @@
+MD5 9d90057a269591fe992b7ed44de2d29f p47_0_2.zip 4783134
+RMD160 2760214a8f0e69c3c415458019a753d8c0661f4a p47_0_2.zip 4783134
+SHA256 1a944185b4594e7f2681204680ec4d885109f56e2156a24b090638c38df47ef0 p47_0_2.zip 4783134
diff --git a/games-action/parsec47/files/p47.prf b/games-action/parsec47/files/p47.prf
new file mode 100644
index 0000000..dfa3d6b
--- /dev/null
+++ b/games-action/parsec47/files/p47.prf
Binary files differ
diff --git a/games-action/parsec47/files/parsec47-0.2.diff b/games-action/parsec47/files/parsec47-0.2.diff
new file mode 100644
index 0000000..15fa504
--- /dev/null
+++ b/games-action/parsec47/files/parsec47-0.2.diff
@@ -0,0 +1,2806 @@
+diff -Naur p47/import/opengl.d p47-gentoo/import/opengl.d
+--- p47/import/opengl.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/opengl.d 2007-09-20 08:25:32.000000000 +0200
+@@ -1,6 +1,4 @@
+-import std.c.windows.windows;
+-
+-extern(Windows):
++ extern(C):
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1111,345 +1109,343 @@
+
+ /*************************************************************/
+
+-extern(Windows) void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-extern(Windows) void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
+-extern(Windows) GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+-extern(Windows) void /*APIENTRY*/glArrayElement (GLint i);
+-extern(Windows) void /*APIENTRY*/glBegin (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glBindTexture (GLenum target, GLuint texture);
+-extern(Windows) void /*APIENTRY*/glBitmap (GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, GLubyte *bitmap);
+-extern(Windows) void /*APIENTRY*/glBlendFunc (GLenum sfactor, GLenum dfactor);
+-extern(Windows) void /*APIENTRY*/glCallList (GLuint list);
+-extern(Windows) void /*APIENTRY*/glCallLists (GLsizei n, GLenum type, GLvoid *lists);
+-extern(Windows) void /*APIENTRY*/glClear (GLbitfield mask);
+-extern(Windows) void /*APIENTRY*/glClearAccum (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+-extern(Windows) void /*APIENTRY*/glClearColor (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
+-extern(Windows) void /*APIENTRY*/glClearDepth (GLclampd depth);
+-extern(Windows) void /*APIENTRY*/glClearIndex (GLfloat c);
+-extern(Windows) void /*APIENTRY*/glClearStencil (GLint s);
+-extern(Windows) void /*APIENTRY*/glClipPlane (GLenum plane, GLdouble *equation);
+-extern(Windows) void /*APIENTRY*/glColor3b (GLbyte red, GLbyte green, GLbyte blue);
+-extern(Windows) void /*APIENTRY*/glColor3bv (GLbyte *v);
+-extern(Windows) void /*APIENTRY*/glColor3d (GLdouble red, GLdouble green, GLdouble blue);
+-extern(Windows) void /*APIENTRY*/glColor3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glColor3f (GLfloat red, GLfloat green, GLfloat blue);
+-extern(Windows) void /*APIENTRY*/glColor3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glColor3i (GLint red, GLint green, GLint blue);
+-extern(Windows) void /*APIENTRY*/glColor3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glColor3s (GLshort red, GLshort green, GLshort blue);
+-extern(Windows) void /*APIENTRY*/glColor3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glColor3ub (GLubyte red, GLubyte green, GLubyte blue);
+-extern(Windows) void /*APIENTRY*/glColor3ubv (GLubyte *v);
+-extern(Windows) void /*APIENTRY*/glColor3ui (GLuint red, GLuint green, GLuint blue);
+-extern(Windows) void /*APIENTRY*/glColor3uiv (GLuint *v);
+-extern(Windows) void /*APIENTRY*/glColor3us (GLushort red, GLushort green, GLushort blue);
+-extern(Windows) void /*APIENTRY*/glColor3usv (GLushort *v);
+-extern(Windows) void /*APIENTRY*/glColor4b (GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
+-extern(Windows) void /*APIENTRY*/glColor4bv (GLbyte *v);
+-extern(Windows) void /*APIENTRY*/glColor4d (GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
+-extern(Windows) void /*APIENTRY*/glColor4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glColor4f (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
+-extern(Windows) void /*APIENTRY*/glColor4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glColor4i (GLint red, GLint green, GLint blue, GLint alpha);
+-extern(Windows) void /*APIENTRY*/glColor4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glColor4s (GLshort red, GLshort green, GLshort blue, GLshort alpha);
+-extern(Windows) void /*APIENTRY*/glColor4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glColor4ub (GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
+-extern(Windows) void /*APIENTRY*/glColor4ubv (GLubyte *v);
+-extern(Windows) void /*APIENTRY*/glColor4ui (GLuint red, GLuint green, GLuint blue, GLuint alpha);
+-extern(Windows) void /*APIENTRY*/glColor4uiv (GLuint *v);
+-extern(Windows) void /*APIENTRY*/glColor4us (GLushort red, GLushort green, GLushort blue, GLushort alpha);
+-extern(Windows) void /*APIENTRY*/glColor4usv (GLushort *v);
+-extern(Windows) void /*APIENTRY*/glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
+-extern(Windows) void /*APIENTRY*/glColorMaterial (GLenum face, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glColorPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glCopyPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
+-extern(Windows) void /*APIENTRY*/glCopyTexImage1D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
+-extern(Windows) void /*APIENTRY*/glCopyTexImage2D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
+-extern(Windows) void /*APIENTRY*/glCopyTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
+-extern(Windows) void /*APIENTRY*/glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
+-extern(Windows) void /*APIENTRY*/glCullFace (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glDeleteLists (GLuint list, GLsizei range);
+-extern(Windows) void /*APIENTRY*/glDeleteTextures (GLsizei n, GLuint *textures);
+-extern(Windows) void /*APIENTRY*/glDepthFunc (GLenum func);
+-extern(Windows) void /*APIENTRY*/glDepthMask (GLboolean flag);
+-extern(Windows) void /*APIENTRY*/glDepthRange (GLclampd zNear, GLclampd zFar);
+-extern(Windows) void /*APIENTRY*/glDisable (GLenum cap);
+-extern(Windows) void /*APIENTRY*/glDisableClientState (GLenum array);
+-extern(Windows) void /*APIENTRY*/glDrawArrays (GLenum mode, GLint first, GLsizei count);
+-extern(Windows) void /*APIENTRY*/glDrawBuffer (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glDrawElements (GLenum mode, GLsizei count, GLenum type, GLvoid *indices);
+-extern(Windows) void /*APIENTRY*/glDrawPixels (GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glEdgeFlag (GLboolean flag);
+-extern(Windows) void /*APIENTRY*/glEdgeFlagPointer (GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glEdgeFlagv (GLboolean *flag);
+-extern(Windows) void /*APIENTRY*/glEnable (GLenum cap);
+-extern(Windows) void /*APIENTRY*/glEnableClientState (GLenum array);
+-extern(Windows) void /*APIENTRY*/glEnd ();
+-extern(Windows) void /*APIENTRY*/glEndList ();
+-extern(Windows) void /*APIENTRY*/glEvalCoord1d (GLdouble u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord1dv (GLdouble *u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord1f (GLfloat u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord1fv (GLfloat *u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2d (GLdouble u, GLdouble v);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2dv (GLdouble *u);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2f (GLfloat u, GLfloat v);
+-extern(Windows) void /*APIENTRY*/glEvalCoord2fv (GLfloat *u);
+-extern(Windows) void /*APIENTRY*/glEvalMesh1 (GLenum mode, GLint i1, GLint i2);
+-extern(Windows) void /*APIENTRY*/glEvalMesh2 (GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
+-extern(Windows) void /*APIENTRY*/glEvalPoint1 (GLint i);
+-extern(Windows) void /*APIENTRY*/glEvalPoint2 (GLint i, GLint j);
+-extern(Windows) void /*APIENTRY*/glFeedbackBuffer (GLsizei size, GLenum type, GLfloat *buffer);
+-extern(Windows) void /*APIENTRY*/glFinish ();
+-extern(Windows) void /*APIENTRY*/glFlush ();
+-extern(Windows) void /*APIENTRY*/glFogf (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glFogfv (GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glFogi (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glFogiv (GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glFrontFace (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glFrustum (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+-extern(Windows) GLuint /*APIENTRY*/glGenLists (GLsizei range);
+-extern(Windows) void /*APIENTRY*/glGenTextures (GLsizei n, GLuint *textures);
+-extern(Windows) void /*APIENTRY*/glGetBooleanv (GLenum pname, GLboolean *params);
+-extern(Windows) void /*APIENTRY*/glGetClipPlane (GLenum plane, GLdouble *equation);
+-extern(Windows) void /*APIENTRY*/glGetDoublev (GLenum pname, GLdouble *params);
+-extern(Windows) GLenum /*APIENTRY*/glGetError ();
+-extern(Windows) void /*APIENTRY*/glGetFloatv (GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetIntegerv (GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetLightfv (GLenum light, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetLightiv (GLenum light, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetMapdv (GLenum target, GLenum query, GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glGetMapfv (GLenum target, GLenum query, GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glGetMapiv (GLenum target, GLenum query, GLint *v);
+-extern(Windows) void /*APIENTRY*/glGetMaterialfv (GLenum face, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetMaterialiv (GLenum face, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetPixelMapfv (GLenum map, GLfloat *values);
+-extern(Windows) void /*APIENTRY*/glGetPixelMapuiv (GLenum map, GLuint *values);
+-extern(Windows) void /*APIENTRY*/glGetPixelMapusv (GLenum map, GLushort *values);
+-extern(Windows) void /*APIENTRY*/glGetPointerv (GLenum pname, GLvoid* *params);
+-extern(Windows) void /*APIENTRY*/glGetPolygonStipple (GLubyte *mask);
+-extern(Windows) GLubyte * /*APIENTRY*/glGetString (GLenum name);
+-extern(Windows) void /*APIENTRY*/glGetTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexEnviv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetTexGendv (GLenum coord, GLenum pname, GLdouble *params);
+-extern(Windows) void /*APIENTRY*/glGetTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexGeniv (GLenum coord, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetTexImage (GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glGetTexLevelParameterfv (GLenum target, GLint level, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexLevelParameteriv (GLenum target, GLint level, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glGetTexParameteriv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glHint (GLenum target, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glIndexMask (GLuint mask);
+-extern(Windows) void /*APIENTRY*/glIndexPointer (GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glIndexd (GLdouble c);
+-extern(Windows) void /*APIENTRY*/glIndexdv (GLdouble *c);
+-extern(Windows) void /*APIENTRY*/glIndexf (GLfloat c);
+-extern(Windows) void /*APIENTRY*/glIndexfv (GLfloat *c);
+-extern(Windows) void /*APIENTRY*/glIndexi (GLint c);
+-extern(Windows) void /*APIENTRY*/glIndexiv (GLint *c);
+-extern(Windows) void /*APIENTRY*/glIndexs (GLshort c);
+-extern(Windows) void /*APIENTRY*/glIndexsv (GLshort *c);
+-extern(Windows) void /*APIENTRY*/glIndexub (GLubyte c);
+-extern(Windows) void /*APIENTRY*/glIndexubv (GLubyte *c);
+-extern(Windows) void /*APIENTRY*/glInitNames ();
+-extern(Windows) void /*APIENTRY*/glInterleavedArrays (GLenum format, GLsizei stride, GLvoid *pointer);
+-extern(Windows) GLboolean /*APIENTRY*/glIsEnabled (GLenum cap);
+-extern(Windows) GLboolean /*APIENTRY*/glIsList (GLuint list);
+-extern(Windows) GLboolean /*APIENTRY*/glIsTexture (GLuint texture);
+-extern(Windows) void /*APIENTRY*/glLightModelf (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glLightModelfv (GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glLightModeli (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glLightModeliv (GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glLightf (GLenum light, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glLightfv (GLenum light, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glLighti (GLenum light, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glLightiv (GLenum light, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glLineStipple (GLint factor, GLushort pattern);
+-extern(Windows) void /*APIENTRY*/glLineWidth (GLfloat width);
+-extern(Windows) void /*APIENTRY*/glListBase (GLuint base);
+-extern(Windows) void /*APIENTRY*/glLoadIdentity ();
+-extern(Windows) void /*APIENTRY*/glLoadMatrixd (GLdouble *m);
+-extern(Windows) void /*APIENTRY*/glLoadMatrixf (GLfloat *m);
+-extern(Windows) void /*APIENTRY*/glLoadName (GLuint name);
+-extern(Windows) void /*APIENTRY*/glLogicOp (GLenum opcode);
+-extern(Windows) void /*APIENTRY*/glMap1d (GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, GLdouble *points);
+-extern(Windows) void /*APIENTRY*/glMap1f (GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, GLfloat *points);
+-extern(Windows) void /*APIENTRY*/glMap2d (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble *points);
+-extern(Windows) void /*APIENTRY*/glMap2f (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat *points);
+-extern(Windows) void /*APIENTRY*/glMapGrid1d (GLint un, GLdouble u1, GLdouble u2);
+-extern(Windows) void /*APIENTRY*/glMapGrid1f (GLint un, GLfloat u1, GLfloat u2);
+-extern(Windows) void /*APIENTRY*/glMapGrid2d (GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
+-extern(Windows) void /*APIENTRY*/glMapGrid2f (GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
+-extern(Windows) void /*APIENTRY*/glMaterialf (GLenum face, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glMaterialfv (GLenum face, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glMateriali (GLenum face, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glMaterialiv (GLenum face, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glMatrixMode (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glMultMatrixd (GLdouble *m);
+-extern(Windows) void /*APIENTRY*/glMultMatrixf (GLfloat *m);
+-extern(Windows) void /*APIENTRY*/glNewList (GLuint list, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glNormal3b (GLbyte nx, GLbyte ny, GLbyte nz);
+-extern(Windows) void /*APIENTRY*/glNormal3bv (GLbyte *v);
+-extern(Windows) void /*APIENTRY*/glNormal3d (GLdouble nx, GLdouble ny, GLdouble nz);
+-extern(Windows) void /*APIENTRY*/glNormal3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glNormal3f (GLfloat nx, GLfloat ny, GLfloat nz);
+-extern(Windows) void /*APIENTRY*/glNormal3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glNormal3i (GLint nx, GLint ny, GLint nz);
+-extern(Windows) void /*APIENTRY*/glNormal3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glNormal3s (GLshort nx, GLshort ny, GLshort nz);
+-extern(Windows) void /*APIENTRY*/glNormal3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glNormalPointer (GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glOrtho (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
+-extern(Windows) void /*APIENTRY*/glPassThrough (GLfloat token);
+-extern(Windows) void /*APIENTRY*/glPixelMapfv (GLenum map, GLsizei mapsize, GLfloat *values);
+-extern(Windows) void /*APIENTRY*/glPixelMapuiv (GLenum map, GLsizei mapsize, GLuint *values);
+-extern(Windows) void /*APIENTRY*/glPixelMapusv (GLenum map, GLsizei mapsize, GLushort *values);
+-extern(Windows) void /*APIENTRY*/glPixelStoref (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glPixelStorei (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glPixelTransferf (GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glPixelTransferi (GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glPixelZoom (GLfloat xfactor, GLfloat yfactor);
+-extern(Windows) void /*APIENTRY*/glPointSize (GLfloat size);
+-extern(Windows) void /*APIENTRY*/glPolygonMode (GLenum face, GLenum mode);
+-extern(Windows) void /*APIENTRY*/glPolygonOffset (GLfloat factor, GLfloat units);
+-extern(Windows) void /*APIENTRY*/glPolygonStipple (GLubyte *mask);
+-extern(Windows) void /*APIENTRY*/glPopAttrib ();
+-extern(Windows) void /*APIENTRY*/glPopClientAttrib ();
+-extern(Windows) void /*APIENTRY*/glPopMatrix ();
+-extern(Windows) void /*APIENTRY*/glPopName ();
+-extern(Windows) void /*APIENTRY*/glPrioritizeTextures (GLsizei n, GLuint *textures, GLclampf *priorities);
+-extern(Windows) void /*APIENTRY*/glPushAttrib (GLbitfield mask);
+-extern(Windows) void /*APIENTRY*/glPushClientAttrib (GLbitfield mask);
+-extern(Windows) void /*APIENTRY*/glPushMatrix ();
+-extern(Windows) void /*APIENTRY*/glPushName (GLuint name);
+-extern(Windows) void /*APIENTRY*/glRasterPos2d (GLdouble x, GLdouble y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos2f (GLfloat x, GLfloat y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos2i (GLint x, GLint y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos2s (GLshort x, GLshort y);
+-extern(Windows) void /*APIENTRY*/glRasterPos2sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3d (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3f (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3i (GLint x, GLint y, GLint z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos3s (GLshort x, GLshort y, GLshort z);
+-extern(Windows) void /*APIENTRY*/glRasterPos3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4i (GLint x, GLint y, GLint z, GLint w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glRasterPos4s (GLshort x, GLshort y, GLshort z, GLshort w);
+-extern(Windows) void /*APIENTRY*/glRasterPos4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glReadBuffer (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glRectd (GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
+-extern(Windows) void /*APIENTRY*/glRectdv (GLdouble *v1, GLdouble *v2);
+-extern(Windows) void /*APIENTRY*/glRectf (GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
+-extern(Windows) void /*APIENTRY*/glRectfv (GLfloat *v1, GLfloat *v2);
+-extern(Windows) void /*APIENTRY*/glRecti (GLint x1, GLint y1, GLint x2, GLint y2);
+-extern(Windows) void /*APIENTRY*/glRectiv (GLint *v1, GLint *v2);
+-extern(Windows) void /*APIENTRY*/glRects (GLshort x1, GLshort y1, GLshort x2, GLshort y2);
+-extern(Windows) void /*APIENTRY*/glRectsv (GLshort *v1, GLshort *v2);
+-extern(Windows) GLint /*APIENTRY*/glRenderMode (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glRotated (GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glRotatef (GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glScaled (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glScalef (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+-extern(Windows) void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+-extern(Windows) void /*APIENTRY*/glShadeModel (GLenum mode);
+-extern(Windows) void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
+-extern(Windows) void /*APIENTRY*/glStencilMask (GLuint mask);
+-extern(Windows) void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+-extern(Windows) void /*APIENTRY*/glTexCoord1d (GLdouble s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord1f (GLfloat s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord1i (GLint s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord1s (GLshort s);
+-extern(Windows) void /*APIENTRY*/glTexCoord1sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2d (GLdouble s, GLdouble t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2f (GLfloat s, GLfloat t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2i (GLint s, GLint t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord2s (GLshort s, GLshort t);
+-extern(Windows) void /*APIENTRY*/glTexCoord2sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3d (GLdouble s, GLdouble t, GLdouble r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3f (GLfloat s, GLfloat t, GLfloat r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3i (GLint s, GLint t, GLint r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord3s (GLshort s, GLshort t, GLshort r);
+-extern(Windows) void /*APIENTRY*/glTexCoord3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4d (GLdouble s, GLdouble t, GLdouble r, GLdouble q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4f (GLfloat s, GLfloat t, GLfloat r, GLfloat q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4i (GLint s, GLint t, GLint r, GLint q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glTexCoord4s (GLshort s, GLshort t, GLshort r, GLshort q);
+-extern(Windows) void /*APIENTRY*/glTexCoord4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glTexCoordPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glTexEnvf (GLenum target, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glTexEnvi (GLenum target, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glTexEnviv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glTexGend (GLenum coord, GLenum pname, GLdouble param);
+-extern(Windows) void /*APIENTRY*/glTexGendv (GLenum coord, GLenum pname, GLdouble *params);
+-extern(Windows) void /*APIENTRY*/glTexGenf (GLenum coord, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glTexGeni (GLenum coord, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glTexGeniv (GLenum coord, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glTexImage1D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTexParameterf (GLenum target, GLenum pname, GLfloat param);
+-extern(Windows) void /*APIENTRY*/glTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
+-extern(Windows) void /*APIENTRY*/glTexParameteri (GLenum target, GLenum pname, GLint param);
+-extern(Windows) void /*APIENTRY*/glTexParameteriv (GLenum target, GLenum pname, GLint *params);
+-extern(Windows) void /*APIENTRY*/glTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
+-extern(Windows) void /*APIENTRY*/glTranslated (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glTranslatef (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glVertex2d (GLdouble x, GLdouble y);
+-extern(Windows) void /*APIENTRY*/glVertex2dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glVertex2f (GLfloat x, GLfloat y);
+-extern(Windows) void /*APIENTRY*/glVertex2fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glVertex2i (GLint x, GLint y);
+-extern(Windows) void /*APIENTRY*/glVertex2iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glVertex2s (GLshort x, GLshort y);
+-extern(Windows) void /*APIENTRY*/glVertex2sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glVertex3d (GLdouble x, GLdouble y, GLdouble z);
+-extern(Windows) void /*APIENTRY*/glVertex3dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glVertex3f (GLfloat x, GLfloat y, GLfloat z);
+-extern(Windows) void /*APIENTRY*/glVertex3fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glVertex3i (GLint x, GLint y, GLint z);
+-extern(Windows) void /*APIENTRY*/glVertex3iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glVertex3s (GLshort x, GLshort y, GLshort z);
+-extern(Windows) void /*APIENTRY*/glVertex3sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glVertex4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
+-extern(Windows) void /*APIENTRY*/glVertex4dv (GLdouble *v);
+-extern(Windows) void /*APIENTRY*/glVertex4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
+-extern(Windows) void /*APIENTRY*/glVertex4fv (GLfloat *v);
+-extern(Windows) void /*APIENTRY*/glVertex4i (GLint x, GLint y, GLint z, GLint w);
+-extern(Windows) void /*APIENTRY*/glVertex4iv (GLint *v);
+-extern(Windows) void /*APIENTRY*/glVertex4s (GLshort x, GLshort y, GLshort z, GLshort w);
+-extern(Windows) void /*APIENTRY*/glVertex4sv (GLshort *v);
+-extern(Windows) void /*APIENTRY*/glVertexPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
+-extern(Windows) void /*APIENTRY*/glViewport (GLint x, GLint y, GLsizei width, GLsizei height);
+-
++void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
++GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
++void /*APIENTRY*/glArrayElement (GLint i);
++void /*APIENTRY*/glBegin (GLenum mode);
++void /*APIENTRY*/glBindTexture (GLenum target, GLuint texture);
++void /*APIENTRY*/glBitmap (GLsizei width, GLsizei height, GLfloat xorig, GLfloat yorig, GLfloat xmove, GLfloat ymove, GLubyte *bitmap);
++void /*APIENTRY*/glBlendFunc (GLenum sfactor, GLenum dfactor);
++void /*APIENTRY*/glCallList (GLuint list);
++void /*APIENTRY*/glCallLists (GLsizei n, GLenum type, GLvoid *lists);
++void /*APIENTRY*/glClear (GLbitfield mask);
++void /*APIENTRY*/glClearAccum (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
++void /*APIENTRY*/glClearColor (GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha);
++void /*APIENTRY*/glClearDepth (GLclampd depth);
++void /*APIENTRY*/glClearIndex (GLfloat c);
++void /*APIENTRY*/glClearStencil (GLint s);
++void /*APIENTRY*/glClipPlane (GLenum plane, GLdouble *equation);
++void /*APIENTRY*/glColor3b (GLbyte red, GLbyte green, GLbyte blue);
++void /*APIENTRY*/glColor3bv (GLbyte *v);
++void /*APIENTRY*/glColor3d (GLdouble red, GLdouble green, GLdouble blue);
++void /*APIENTRY*/glColor3dv (GLdouble *v);
++void /*APIENTRY*/glColor3f (GLfloat red, GLfloat green, GLfloat blue);
++void /*APIENTRY*/glColor3fv (GLfloat *v);
++void /*APIENTRY*/glColor3i (GLint red, GLint green, GLint blue);
++void /*APIENTRY*/glColor3iv (GLint *v);
++void /*APIENTRY*/glColor3s (GLshort red, GLshort green, GLshort blue);
++void /*APIENTRY*/glColor3sv (GLshort *v);
++void /*APIENTRY*/glColor3ub (GLubyte red, GLubyte green, GLubyte blue);
++void /*APIENTRY*/glColor3ubv (GLubyte *v);
++void /*APIENTRY*/glColor3ui (GLuint red, GLuint green, GLuint blue);
++void /*APIENTRY*/glColor3uiv (GLuint *v);
++void /*APIENTRY*/glColor3us (GLushort red, GLushort green, GLushort blue);
++void /*APIENTRY*/glColor3usv (GLushort *v);
++void /*APIENTRY*/glColor4b (GLbyte red, GLbyte green, GLbyte blue, GLbyte alpha);
++void /*APIENTRY*/glColor4bv (GLbyte *v);
++void /*APIENTRY*/glColor4d (GLdouble red, GLdouble green, GLdouble blue, GLdouble alpha);
++void /*APIENTRY*/glColor4dv (GLdouble *v);
++void /*APIENTRY*/glColor4f (GLfloat red, GLfloat green, GLfloat blue, GLfloat alpha);
++void /*APIENTRY*/glColor4fv (GLfloat *v);
++void /*APIENTRY*/glColor4i (GLint red, GLint green, GLint blue, GLint alpha);
++void /*APIENTRY*/glColor4iv (GLint *v);
++void /*APIENTRY*/glColor4s (GLshort red, GLshort green, GLshort blue, GLshort alpha);
++void /*APIENTRY*/glColor4sv (GLshort *v);
++void /*APIENTRY*/glColor4ub (GLubyte red, GLubyte green, GLubyte blue, GLubyte alpha);
++void /*APIENTRY*/glColor4ubv (GLubyte *v);
++void /*APIENTRY*/glColor4ui (GLuint red, GLuint green, GLuint blue, GLuint alpha);
++void /*APIENTRY*/glColor4uiv (GLuint *v);
++void /*APIENTRY*/glColor4us (GLushort red, GLushort green, GLushort blue, GLushort alpha);
++void /*APIENTRY*/glColor4usv (GLushort *v);
++void /*APIENTRY*/glColorMask (GLboolean red, GLboolean green, GLboolean blue, GLboolean alpha);
++void /*APIENTRY*/glColorMaterial (GLenum face, GLenum mode);
++void /*APIENTRY*/glColorPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glCopyPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum type);
++void /*APIENTRY*/glCopyTexImage1D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLint border);
++void /*APIENTRY*/glCopyTexImage2D (GLenum target, GLint level, GLenum internalFormat, GLint x, GLint y, GLsizei width, GLsizei height, GLint border);
++void /*APIENTRY*/glCopyTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLint x, GLint y, GLsizei width);
++void /*APIENTRY*/glCopyTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLint x, GLint y, GLsizei width, GLsizei height);
++void /*APIENTRY*/glCullFace (GLenum mode);
++void /*APIENTRY*/glDeleteLists (GLuint list, GLsizei range);
++void /*APIENTRY*/glDeleteTextures (GLsizei n, GLuint *textures);
++void /*APIENTRY*/glDepthFunc (GLenum func);
++void /*APIENTRY*/glDepthMask (GLboolean flag);
++void /*APIENTRY*/glDepthRange (GLclampd zNear, GLclampd zFar);
++void /*APIENTRY*/glDisable (GLenum cap);
++void /*APIENTRY*/glDisableClientState (GLenum array);
++void /*APIENTRY*/glDrawArrays (GLenum mode, GLint first, GLsizei count);
++void /*APIENTRY*/glDrawBuffer (GLenum mode);
++void /*APIENTRY*/glDrawElements (GLenum mode, GLsizei count, GLenum type, GLvoid *indices);
++void /*APIENTRY*/glDrawPixels (GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glEdgeFlag (GLboolean flag);
++void /*APIENTRY*/glEdgeFlagPointer (GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glEdgeFlagv (GLboolean *flag);
++void /*APIENTRY*/glEnable (GLenum cap);
++void /*APIENTRY*/glEnableClientState (GLenum array);
++void /*APIENTRY*/glEnd ();
++void /*APIENTRY*/glEndList ();
++void /*APIENTRY*/glEvalCoord1d (GLdouble u);
++void /*APIENTRY*/glEvalCoord1dv (GLdouble *u);
++void /*APIENTRY*/glEvalCoord1f (GLfloat u);
++void /*APIENTRY*/glEvalCoord1fv (GLfloat *u);
++void /*APIENTRY*/glEvalCoord2d (GLdouble u, GLdouble v);
++void /*APIENTRY*/glEvalCoord2dv (GLdouble *u);
++void /*APIENTRY*/glEvalCoord2f (GLfloat u, GLfloat v);
++void /*APIENTRY*/glEvalCoord2fv (GLfloat *u);
++void /*APIENTRY*/glEvalMesh1 (GLenum mode, GLint i1, GLint i2);
++void /*APIENTRY*/glEvalMesh2 (GLenum mode, GLint i1, GLint i2, GLint j1, GLint j2);
++void /*APIENTRY*/glEvalPoint1 (GLint i);
++void /*APIENTRY*/glEvalPoint2 (GLint i, GLint j);
++void /*APIENTRY*/glFeedbackBuffer (GLsizei size, GLenum type, GLfloat *buffer);
++void /*APIENTRY*/glFinish ();
++void /*APIENTRY*/glFlush ();
++void /*APIENTRY*/glFogf (GLenum pname, GLfloat param);
++void /*APIENTRY*/glFogfv (GLenum pname, GLfloat *params);
++void /*APIENTRY*/glFogi (GLenum pname, GLint param);
++void /*APIENTRY*/glFogiv (GLenum pname, GLint *params);
++void /*APIENTRY*/glFrontFace (GLenum mode);
++void /*APIENTRY*/glFrustum (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
++GLuint /*APIENTRY*/glGenLists (GLsizei range);
++void /*APIENTRY*/glGenTextures (GLsizei n, GLuint *textures);
++void /*APIENTRY*/glGetBooleanv (GLenum pname, GLboolean *params);
++void /*APIENTRY*/glGetClipPlane (GLenum plane, GLdouble *equation);
++void /*APIENTRY*/glGetDoublev (GLenum pname, GLdouble *params);
++GLenum /*APIENTRY*/glGetError ();
++void /*APIENTRY*/glGetFloatv (GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetIntegerv (GLenum pname, GLint *params);
++void /*APIENTRY*/glGetLightfv (GLenum light, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetLightiv (GLenum light, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetMapdv (GLenum target, GLenum query, GLdouble *v);
++void /*APIENTRY*/glGetMapfv (GLenum target, GLenum query, GLfloat *v);
++void /*APIENTRY*/glGetMapiv (GLenum target, GLenum query, GLint *v);
++void /*APIENTRY*/glGetMaterialfv (GLenum face, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetMaterialiv (GLenum face, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetPixelMapfv (GLenum map, GLfloat *values);
++void /*APIENTRY*/glGetPixelMapuiv (GLenum map, GLuint *values);
++void /*APIENTRY*/glGetPixelMapusv (GLenum map, GLushort *values);
++void /*APIENTRY*/glGetPointerv (GLenum pname, GLvoid* *params);
++void /*APIENTRY*/glGetPolygonStipple (GLubyte *mask);
++GLubyte * /*APIENTRY*/glGetString (GLenum name);
++void /*APIENTRY*/glGetTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexEnviv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetTexGendv (GLenum coord, GLenum pname, GLdouble *params);
++void /*APIENTRY*/glGetTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexGeniv (GLenum coord, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetTexImage (GLenum target, GLint level, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glGetTexLevelParameterfv (GLenum target, GLint level, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexLevelParameteriv (GLenum target, GLint level, GLenum pname, GLint *params);
++void /*APIENTRY*/glGetTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glGetTexParameteriv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glHint (GLenum target, GLenum mode);
++void /*APIENTRY*/glIndexMask (GLuint mask);
++void /*APIENTRY*/glIndexPointer (GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glIndexd (GLdouble c);
++void /*APIENTRY*/glIndexdv (GLdouble *c);
++void /*APIENTRY*/glIndexf (GLfloat c);
++void /*APIENTRY*/glIndexfv (GLfloat *c);
++void /*APIENTRY*/glIndexi (GLint c);
++void /*APIENTRY*/glIndexiv (GLint *c);
++void /*APIENTRY*/glIndexs (GLshort c);
++void /*APIENTRY*/glIndexsv (GLshort *c);
++void /*APIENTRY*/glIndexub (GLubyte c);
++void /*APIENTRY*/glIndexubv (GLubyte *c);
++void /*APIENTRY*/glInitNames ();
++void /*APIENTRY*/glInterleavedArrays (GLenum format, GLsizei stride, GLvoid *pointer);
++GLboolean /*APIENTRY*/glIsEnabled (GLenum cap);
++GLboolean /*APIENTRY*/glIsList (GLuint list);
++GLboolean /*APIENTRY*/glIsTexture (GLuint texture);
++void /*APIENTRY*/glLightModelf (GLenum pname, GLfloat param);
++void /*APIENTRY*/glLightModelfv (GLenum pname, GLfloat *params);
++void /*APIENTRY*/glLightModeli (GLenum pname, GLint param);
++void /*APIENTRY*/glLightModeliv (GLenum pname, GLint *params);
++void /*APIENTRY*/glLightf (GLenum light, GLenum pname, GLfloat param);
++void /*APIENTRY*/glLightfv (GLenum light, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glLighti (GLenum light, GLenum pname, GLint param);
++void /*APIENTRY*/glLightiv (GLenum light, GLenum pname, GLint *params);
++void /*APIENTRY*/glLineStipple (GLint factor, GLushort pattern);
++void /*APIENTRY*/glLineWidth (GLfloat width);
++void /*APIENTRY*/glListBase (GLuint base);
++void /*APIENTRY*/glLoadIdentity ();
++void /*APIENTRY*/glLoadMatrixd (GLdouble *m);
++void /*APIENTRY*/glLoadMatrixf (GLfloat *m);
++void /*APIENTRY*/glLoadName (GLuint name);
++void /*APIENTRY*/glLogicOp (GLenum opcode);
++void /*APIENTRY*/glMap1d (GLenum target, GLdouble u1, GLdouble u2, GLint stride, GLint order, GLdouble *points);
++void /*APIENTRY*/glMap1f (GLenum target, GLfloat u1, GLfloat u2, GLint stride, GLint order, GLfloat *points);
++void /*APIENTRY*/glMap2d (GLenum target, GLdouble u1, GLdouble u2, GLint ustride, GLint uorder, GLdouble v1, GLdouble v2, GLint vstride, GLint vorder, GLdouble *points);
++void /*APIENTRY*/glMap2f (GLenum target, GLfloat u1, GLfloat u2, GLint ustride, GLint uorder, GLfloat v1, GLfloat v2, GLint vstride, GLint vorder, GLfloat *points);
++void /*APIENTRY*/glMapGrid1d (GLint un, GLdouble u1, GLdouble u2);
++void /*APIENTRY*/glMapGrid1f (GLint un, GLfloat u1, GLfloat u2);
++void /*APIENTRY*/glMapGrid2d (GLint un, GLdouble u1, GLdouble u2, GLint vn, GLdouble v1, GLdouble v2);
++void /*APIENTRY*/glMapGrid2f (GLint un, GLfloat u1, GLfloat u2, GLint vn, GLfloat v1, GLfloat v2);
++void /*APIENTRY*/glMaterialf (GLenum face, GLenum pname, GLfloat param);
++void /*APIENTRY*/glMaterialfv (GLenum face, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glMateriali (GLenum face, GLenum pname, GLint param);
++void /*APIENTRY*/glMaterialiv (GLenum face, GLenum pname, GLint *params);
++void /*APIENTRY*/glMatrixMode (GLenum mode);
++void /*APIENTRY*/glMultMatrixd (GLdouble *m);
++void /*APIENTRY*/glMultMatrixf (GLfloat *m);
++void /*APIENTRY*/glNewList (GLuint list, GLenum mode);
++void /*APIENTRY*/glNormal3b (GLbyte nx, GLbyte ny, GLbyte nz);
++void /*APIENTRY*/glNormal3bv (GLbyte *v);
++void /*APIENTRY*/glNormal3d (GLdouble nx, GLdouble ny, GLdouble nz);
++void /*APIENTRY*/glNormal3dv (GLdouble *v);
++void /*APIENTRY*/glNormal3f (GLfloat nx, GLfloat ny, GLfloat nz);
++void /*APIENTRY*/glNormal3fv (GLfloat *v);
++void /*APIENTRY*/glNormal3i (GLint nx, GLint ny, GLint nz);
++void /*APIENTRY*/glNormal3iv (GLint *v);
++void /*APIENTRY*/glNormal3s (GLshort nx, GLshort ny, GLshort nz);
++void /*APIENTRY*/glNormal3sv (GLshort *v);
++void /*APIENTRY*/glNormalPointer (GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glOrtho (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top, GLdouble zNear, GLdouble zFar);
++void /*APIENTRY*/glPassThrough (GLfloat token);
++void /*APIENTRY*/glPixelMapfv (GLenum map, GLsizei mapsize, GLfloat *values);
++void /*APIENTRY*/glPixelMapuiv (GLenum map, GLsizei mapsize, GLuint *values);
++void /*APIENTRY*/glPixelMapusv (GLenum map, GLsizei mapsize, GLushort *values);
++void /*APIENTRY*/glPixelStoref (GLenum pname, GLfloat param);
++void /*APIENTRY*/glPixelStorei (GLenum pname, GLint param);
++void /*APIENTRY*/glPixelTransferf (GLenum pname, GLfloat param);
++void /*APIENTRY*/glPixelTransferi (GLenum pname, GLint param);
++void /*APIENTRY*/glPixelZoom (GLfloat xfactor, GLfloat yfactor);
++void /*APIENTRY*/glPointSize (GLfloat size);
++void /*APIENTRY*/glPolygonMode (GLenum face, GLenum mode);
++void /*APIENTRY*/glPolygonOffset (GLfloat factor, GLfloat units);
++void /*APIENTRY*/glPolygonStipple (GLubyte *mask);
++void /*APIENTRY*/glPopAttrib ();
++void /*APIENTRY*/glPopClientAttrib ();
++void /*APIENTRY*/glPopMatrix ();
++void /*APIENTRY*/glPopName ();
++void /*APIENTRY*/glPrioritizeTextures (GLsizei n, GLuint *textures, GLclampf *priorities);
++void /*APIENTRY*/glPushAttrib (GLbitfield mask);
++void /*APIENTRY*/glPushClientAttrib (GLbitfield mask);
++void /*APIENTRY*/glPushMatrix ();
++void /*APIENTRY*/glPushName (GLuint name);
++void /*APIENTRY*/glRasterPos2d (GLdouble x, GLdouble y);
++void /*APIENTRY*/glRasterPos2dv (GLdouble *v);
++void /*APIENTRY*/glRasterPos2f (GLfloat x, GLfloat y);
++void /*APIENTRY*/glRasterPos2fv (GLfloat *v);
++void /*APIENTRY*/glRasterPos2i (GLint x, GLint y);
++void /*APIENTRY*/glRasterPos2iv (GLint *v);
++void /*APIENTRY*/glRasterPos2s (GLshort x, GLshort y);
++void /*APIENTRY*/glRasterPos2sv (GLshort *v);
++void /*APIENTRY*/glRasterPos3d (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glRasterPos3dv (GLdouble *v);
++void /*APIENTRY*/glRasterPos3f (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glRasterPos3fv (GLfloat *v);
++void /*APIENTRY*/glRasterPos3i (GLint x, GLint y, GLint z);
++void /*APIENTRY*/glRasterPos3iv (GLint *v);
++void /*APIENTRY*/glRasterPos3s (GLshort x, GLshort y, GLshort z);
++void /*APIENTRY*/glRasterPos3sv (GLshort *v);
++void /*APIENTRY*/glRasterPos4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
++void /*APIENTRY*/glRasterPos4dv (GLdouble *v);
++void /*APIENTRY*/glRasterPos4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
++void /*APIENTRY*/glRasterPos4fv (GLfloat *v);
++void /*APIENTRY*/glRasterPos4i (GLint x, GLint y, GLint z, GLint w);
++void /*APIENTRY*/glRasterPos4iv (GLint *v);
++void /*APIENTRY*/glRasterPos4s (GLshort x, GLshort y, GLshort z, GLshort w);
++void /*APIENTRY*/glRasterPos4sv (GLshort *v);
++void /*APIENTRY*/glReadBuffer (GLenum mode);
++void /*APIENTRY*/glReadPixels (GLint x, GLint y, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glRectd (GLdouble x1, GLdouble y1, GLdouble x2, GLdouble y2);
++void /*APIENTRY*/glRectdv (GLdouble *v1, GLdouble *v2);
++void /*APIENTRY*/glRectf (GLfloat x1, GLfloat y1, GLfloat x2, GLfloat y2);
++void /*APIENTRY*/glRectfv (GLfloat *v1, GLfloat *v2);
++void /*APIENTRY*/glRecti (GLint x1, GLint y1, GLint x2, GLint y2);
++void /*APIENTRY*/glRectiv (GLint *v1, GLint *v2);
++void /*APIENTRY*/glRects (GLshort x1, GLshort y1, GLshort x2, GLshort y2);
++void /*APIENTRY*/glRectsv (GLshort *v1, GLshort *v2);
++GLint /*APIENTRY*/glRenderMode (GLenum mode);
++void /*APIENTRY*/glRotated (GLdouble angle, GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glRotatef (GLfloat angle, GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glScaled (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glScalef (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
++void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
++void /*APIENTRY*/glShadeModel (GLenum mode);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
++void /*APIENTRY*/glStencilMask (GLuint mask);
++void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
++void /*APIENTRY*/glTexCoord1d (GLdouble s);
++void /*APIENTRY*/glTexCoord1dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord1f (GLfloat s);
++void /*APIENTRY*/glTexCoord1fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord1i (GLint s);
++void /*APIENTRY*/glTexCoord1iv (GLint *v);
++void /*APIENTRY*/glTexCoord1s (GLshort s);
++void /*APIENTRY*/glTexCoord1sv (GLshort *v);
++void /*APIENTRY*/glTexCoord2d (GLdouble s, GLdouble t);
++void /*APIENTRY*/glTexCoord2dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord2f (GLfloat s, GLfloat t);
++void /*APIENTRY*/glTexCoord2fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord2i (GLint s, GLint t);
++void /*APIENTRY*/glTexCoord2iv (GLint *v);
++void /*APIENTRY*/glTexCoord2s (GLshort s, GLshort t);
++void /*APIENTRY*/glTexCoord2sv (GLshort *v);
++void /*APIENTRY*/glTexCoord3d (GLdouble s, GLdouble t, GLdouble r);
++void /*APIENTRY*/glTexCoord3dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord3f (GLfloat s, GLfloat t, GLfloat r);
++void /*APIENTRY*/glTexCoord3fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord3i (GLint s, GLint t, GLint r);
++void /*APIENTRY*/glTexCoord3iv (GLint *v);
++void /*APIENTRY*/glTexCoord3s (GLshort s, GLshort t, GLshort r);
++void /*APIENTRY*/glTexCoord3sv (GLshort *v);
++void /*APIENTRY*/glTexCoord4d (GLdouble s, GLdouble t, GLdouble r, GLdouble q);
++void /*APIENTRY*/glTexCoord4dv (GLdouble *v);
++void /*APIENTRY*/glTexCoord4f (GLfloat s, GLfloat t, GLfloat r, GLfloat q);
++void /*APIENTRY*/glTexCoord4fv (GLfloat *v);
++void /*APIENTRY*/glTexCoord4i (GLint s, GLint t, GLint r, GLint q);
++void /*APIENTRY*/glTexCoord4iv (GLint *v);
++void /*APIENTRY*/glTexCoord4s (GLshort s, GLshort t, GLshort r, GLshort q);
++void /*APIENTRY*/glTexCoord4sv (GLshort *v);
++void /*APIENTRY*/glTexCoordPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glTexEnvf (GLenum target, GLenum pname, GLfloat param);
++void /*APIENTRY*/glTexEnvfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glTexEnvi (GLenum target, GLenum pname, GLint param);
++void /*APIENTRY*/glTexEnviv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glTexGend (GLenum coord, GLenum pname, GLdouble param);
++void /*APIENTRY*/glTexGendv (GLenum coord, GLenum pname, GLdouble *params);
++void /*APIENTRY*/glTexGenf (GLenum coord, GLenum pname, GLfloat param);
++void /*APIENTRY*/glTexGenfv (GLenum coord, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glTexGeni (GLenum coord, GLenum pname, GLint param);
++void /*APIENTRY*/glTexGeniv (GLenum coord, GLenum pname, GLint *params);
++void /*APIENTRY*/glTexImage1D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLint border, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTexImage2D (GLenum target, GLint level, GLint internalformat, GLsizei width, GLsizei height, GLint border, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTexParameterf (GLenum target, GLenum pname, GLfloat param);
++void /*APIENTRY*/glTexParameterfv (GLenum target, GLenum pname, GLfloat *params);
++void /*APIENTRY*/glTexParameteri (GLenum target, GLenum pname, GLint param);
++void /*APIENTRY*/glTexParameteriv (GLenum target, GLenum pname, GLint *params);
++void /*APIENTRY*/glTexSubImage1D (GLenum target, GLint level, GLint xoffset, GLsizei width, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTexSubImage2D (GLenum target, GLint level, GLint xoffset, GLint yoffset, GLsizei width, GLsizei height, GLenum format, GLenum type, GLvoid *pixels);
++void /*APIENTRY*/glTranslated (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glTranslatef (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glVertex2d (GLdouble x, GLdouble y);
++void /*APIENTRY*/glVertex2dv (GLdouble *v);
++void /*APIENTRY*/glVertex2f (GLfloat x, GLfloat y);
++void /*APIENTRY*/glVertex2fv (GLfloat *v);
++void /*APIENTRY*/glVertex2i (GLint x, GLint y);
++void /*APIENTRY*/glVertex2iv (GLint *v);
++void /*APIENTRY*/glVertex2s (GLshort x, GLshort y);
++void /*APIENTRY*/glVertex2sv (GLshort *v);
++void /*APIENTRY*/glVertex3d (GLdouble x, GLdouble y, GLdouble z);
++void /*APIENTRY*/glVertex3dv (GLdouble *v);
++void /*APIENTRY*/glVertex3f (GLfloat x, GLfloat y, GLfloat z);
++void /*APIENTRY*/glVertex3fv (GLfloat *v);
++void /*APIENTRY*/glVertex3i (GLint x, GLint y, GLint z);
++void /*APIENTRY*/glVertex3iv (GLint *v);
++void /*APIENTRY*/glVertex3s (GLshort x, GLshort y, GLshort z);
++void /*APIENTRY*/glVertex3sv (GLshort *v);
++void /*APIENTRY*/glVertex4d (GLdouble x, GLdouble y, GLdouble z, GLdouble w);
++void /*APIENTRY*/glVertex4dv (GLdouble *v);
++void /*APIENTRY*/glVertex4f (GLfloat x, GLfloat y, GLfloat z, GLfloat w);
++void /*APIENTRY*/glVertex4fv (GLfloat *v);
++void /*APIENTRY*/glVertex4i (GLint x, GLint y, GLint z, GLint w);
++void /*APIENTRY*/glVertex4iv (GLint *v);
++void /*APIENTRY*/glVertex4s (GLshort x, GLshort y, GLshort z, GLshort w);
++void /*APIENTRY*/glVertex4sv (GLshort *v);
++void /*APIENTRY*/glVertexPointer (GLint size, GLenum type, GLsizei stride, GLvoid *pointer);
++void /*APIENTRY*/glViewport (GLint x, GLint y, GLsizei width, GLsizei height);
+
+-extern(Windows):
+
+ /* EXT_vertex_array */
+ typedef void (* PFNGLARRAYELEMENTEXTPROC) (GLint i);
+@@ -1483,4 +1479,4 @@
+ typedef void (* PFNGLGETCOLORTABLEPARAMETERFVEXTPROC)
+ (GLenum target, GLenum pname, GLfloat *params);
+
+-import openglu;
++//import openglu;
+diff -Naur p47/import/openglu.d p47-gentoo/import/openglu.d
+--- p47/import/openglu.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/openglu.d 2007-09-20 08:25:38.000000000 +0200
+@@ -1,6 +1,6 @@
+ import opengl;
+
+-extern(Windows):
++ extern(C):
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+@@ -357,7 +357,6 @@
+
+ /**** Tesselation constants ****/
+
+-//const extended GLU_TESS_MAX_COORD = 1.0e150;
+ const real GLU_TESS_MAX_COORD = 1.0e150;
+
+ /* TessProperty */
+diff -Naur p47/import/SDL.d p47-gentoo/import/SDL.d
+--- p47/import/SDL.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL.d 2007-09-20 08:24:15.000000000 +0200
+@@ -31,7 +31,7 @@
+ import SDL_events;
+ import SDL_video;
+ import SDL_byteorder;
+-import SDL_version;
++import SDL_Version;
+
+ extern(C):
+
+@@ -73,6 +73,7 @@
+ */
+ void SDL_Quit();
+
++/+
+ void SDL_SetModuleHandle(void *hInst);
+ extern(Windows) void* GetModuleHandle(char*);
+
+@@ -87,4 +88,5 @@
+ static ~this()
+ {
+ SDL_Quit();
+-}
+\ Kein Zeilenumbruch am Dateiende.
++}
+++/
+diff -Naur p47/import/SDL_endian.d p47-gentoo/import/SDL_endian.d
+--- p47/import/SDL_endian.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_endian.d 2007-09-20 08:24:15.000000000 +0200
+@@ -57,9 +57,9 @@
+ Uint64 SDL_Swap64(Uint64 val) {
+ Uint32 hi, lo;
+ /* Separate into high and low 32-bit values and swap them */
+- lo = (Uint32)(val&0xFFFFFFFF);
++ lo = cast(Uint32)(val&0xFFFFFFFF);
+ val >>= 32;
+- hi = (Uint32)(val&0xFFFFFFFF);
++ hi = cast(Uint32)(val&0xFFFFFFFF);
+ val = SDL_Swap32(lo);
+ val <<= 32;
+ val |= SDL_Swap32(hi);
+diff -Naur p47/import/SDL_events.d p47-gentoo/import/SDL_events.d
+--- p47/import/SDL_events.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_events.d 2007-09-20 08:24:15.000000000 +0200
+@@ -304,7 +304,7 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() will return the
+ current processing state of the specified event.
+ */
+-const uint SDL_QUERY = -1;
++const uint SDL_QUERY = cast(uint) -1;
+ const uint SDL_IGNORE = 0;
+ const uint SDL_DISABLE = 0;
+ const uint SDL_ENABLE = 1;
+diff -Naur p47/import/SDL_getenv.d p47-gentoo/import/SDL_getenv.d
+--- p47/import/SDL_getenv.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_getenv.d 2007-09-20 08:24:15.000000000 +0200
+@@ -2,6 +2,7 @@
+
+ extern(C):
+
++/+
+ /* Put a variable of the form "name=value" into the environment */
+ int SDL_putenv(char *variable);
+ int putenv(char* X) { return SDL_putenv(X); }
+@@ -9,3 +10,4 @@
+ /* Retrieve a variable named "name" from the environment */
+ char *SDL_getenv(char *name);
+ char *getenv(char* X) { return SDL_getenv(X); }
+++/
+diff -Naur p47/import/SDL_Keysym.d p47-gentoo/import/SDL_Keysym.d
+--- p47/import/SDL_Keysym.d 1970-01-01 01:00:00.000000000 +0100
++++ p47-gentoo/import/SDL_Keysym.d 2007-09-20 08:24:15.000000000 +0200
+@@ -0,0 +1,308 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* What we really want is a mapping of every raw key on the keyboard.
++ To support international keyboards, we use the range 0xA1 - 0xFF
++ as international virtual keycodes. We'll follow in the footsteps of X11...
++ The names of the keys
++ */
++
++alias int SDLKey;
++enum {
++ /* The keyboard syms have been cleverly chosen to map to ASCII */
++ SDLK_UNKNOWN = 0,
++ SDLK_FIRST = 0,
++ SDLK_BACKSPACE = 8,
++ SDLK_TAB = 9,
++ SDLK_CLEAR = 12,
++ SDLK_RETURN = 13,
++ SDLK_PAUSE = 19,
++ SDLK_ESCAPE = 27,
++ SDLK_SPACE = 32,
++ SDLK_EXCLAIM = 33,
++ SDLK_QUOTEDBL = 34,
++ SDLK_HASH = 35,
++ SDLK_DOLLAR = 36,
++ SDLK_AMPERSAND = 38,
++ SDLK_QUOTE = 39,
++ SDLK_LEFTPAREN = 40,
++ SDLK_RIGHTPAREN = 41,
++ SDLK_ASTERISK = 42,
++ SDLK_PLUS = 43,
++ SDLK_COMMA = 44,
++ SDLK_MINUS = 45,
++ SDLK_PERIOD = 46,
++ SDLK_SLASH = 47,
++ SDLK_0 = 48,
++ SDLK_1 = 49,
++ SDLK_2 = 50,
++ SDLK_3 = 51,
++ SDLK_4 = 52,
++ SDLK_5 = 53,
++ SDLK_6 = 54,
++ SDLK_7 = 55,
++ SDLK_8 = 56,
++ SDLK_9 = 57,
++ SDLK_COLON = 58,
++ SDLK_SEMICOLON = 59,
++ SDLK_LESS = 60,
++ SDLK_EQUALS = 61,
++ SDLK_GREATER = 62,
++ SDLK_QUESTION = 63,
++ SDLK_AT = 64,
++ /*
++ Skip uppercase letters
++ */
++ SDLK_LEFTBRACKET = 91,
++ SDLK_BACKSLASH = 92,
++ SDLK_RIGHTBRACKET = 93,
++ SDLK_CARET = 94,
++ SDLK_UNDERSCORE = 95,
++ SDLK_BACKQUOTE = 96,
++ SDLK_a = 97,
++ SDLK_b = 98,
++ SDLK_c = 99,
++ SDLK_d = 100,
++ SDLK_e = 101,
++ SDLK_f = 102,
++ SDLK_g = 103,
++ SDLK_h = 104,
++ SDLK_i = 105,
++ SDLK_j = 106,
++ SDLK_k = 107,
++ SDLK_l = 108,
++ SDLK_m = 109,
++ SDLK_n = 110,
++ SDLK_o = 111,
++ SDLK_p = 112,
++ SDLK_q = 113,
++ SDLK_r = 114,
++ SDLK_s = 115,
++ SDLK_t = 116,
++ SDLK_u = 117,
++ SDLK_v = 118,
++ SDLK_w = 119,
++ SDLK_x = 120,
++ SDLK_y = 121,
++ SDLK_z = 122,
++ SDLK_DELETE = 127,
++ /* End of ASCII mapped keysyms */
++
++ /* International keyboard syms */
++ SDLK_WORLD_0 = 160, /* 0xA0 */
++ SDLK_WORLD_1 = 161,
++ SDLK_WORLD_2 = 162,
++ SDLK_WORLD_3 = 163,
++ SDLK_WORLD_4 = 164,
++ SDLK_WORLD_5 = 165,
++ SDLK_WORLD_6 = 166,
++ SDLK_WORLD_7 = 167,
++ SDLK_WORLD_8 = 168,
++ SDLK_WORLD_9 = 169,
++ SDLK_WORLD_10 = 170,
++ SDLK_WORLD_11 = 171,
++ SDLK_WORLD_12 = 172,
++ SDLK_WORLD_13 = 173,
++ SDLK_WORLD_14 = 174,
++ SDLK_WORLD_15 = 175,
++ SDLK_WORLD_16 = 176,
++ SDLK_WORLD_17 = 177,
++ SDLK_WORLD_18 = 178,
++ SDLK_WORLD_19 = 179,
++ SDLK_WORLD_20 = 180,
++ SDLK_WORLD_21 = 181,
++ SDLK_WORLD_22 = 182,
++ SDLK_WORLD_23 = 183,
++ SDLK_WORLD_24 = 184,
++ SDLK_WORLD_25 = 185,
++ SDLK_WORLD_26 = 186,
++ SDLK_WORLD_27 = 187,
++ SDLK_WORLD_28 = 188,
++ SDLK_WORLD_29 = 189,
++ SDLK_WORLD_30 = 190,
++ SDLK_WORLD_31 = 191,
++ SDLK_WORLD_32 = 192,
++ SDLK_WORLD_33 = 193,
++ SDLK_WORLD_34 = 194,
++ SDLK_WORLD_35 = 195,
++ SDLK_WORLD_36 = 196,
++ SDLK_WORLD_37 = 197,
++ SDLK_WORLD_38 = 198,
++ SDLK_WORLD_39 = 199,
++ SDLK_WORLD_40 = 200,
++ SDLK_WORLD_41 = 201,
++ SDLK_WORLD_42 = 202,
++ SDLK_WORLD_43 = 203,
++ SDLK_WORLD_44 = 204,
++ SDLK_WORLD_45 = 205,
++ SDLK_WORLD_46 = 206,
++ SDLK_WORLD_47 = 207,
++ SDLK_WORLD_48 = 208,
++ SDLK_WORLD_49 = 209,
++ SDLK_WORLD_50 = 210,
++ SDLK_WORLD_51 = 211,
++ SDLK_WORLD_52 = 212,
++ SDLK_WORLD_53 = 213,
++ SDLK_WORLD_54 = 214,
++ SDLK_WORLD_55 = 215,
++ SDLK_WORLD_56 = 216,
++ SDLK_WORLD_57 = 217,
++ SDLK_WORLD_58 = 218,
++ SDLK_WORLD_59 = 219,
++ SDLK_WORLD_60 = 220,
++ SDLK_WORLD_61 = 221,
++ SDLK_WORLD_62 = 222,
++ SDLK_WORLD_63 = 223,
++ SDLK_WORLD_64 = 224,
++ SDLK_WORLD_65 = 225,
++ SDLK_WORLD_66 = 226,
++ SDLK_WORLD_67 = 227,
++ SDLK_WORLD_68 = 228,
++ SDLK_WORLD_69 = 229,
++ SDLK_WORLD_70 = 230,
++ SDLK_WORLD_71 = 231,
++ SDLK_WORLD_72 = 232,
++ SDLK_WORLD_73 = 233,
++ SDLK_WORLD_74 = 234,
++ SDLK_WORLD_75 = 235,
++ SDLK_WORLD_76 = 236,
++ SDLK_WORLD_77 = 237,
++ SDLK_WORLD_78 = 238,
++ SDLK_WORLD_79 = 239,
++ SDLK_WORLD_80 = 240,
++ SDLK_WORLD_81 = 241,
++ SDLK_WORLD_82 = 242,
++ SDLK_WORLD_83 = 243,
++ SDLK_WORLD_84 = 244,
++ SDLK_WORLD_85 = 245,
++ SDLK_WORLD_86 = 246,
++ SDLK_WORLD_87 = 247,
++ SDLK_WORLD_88 = 248,
++ SDLK_WORLD_89 = 249,
++ SDLK_WORLD_90 = 250,
++ SDLK_WORLD_91 = 251,
++ SDLK_WORLD_92 = 252,
++ SDLK_WORLD_93 = 253,
++ SDLK_WORLD_94 = 254,
++ SDLK_WORLD_95 = 255, /* 0xFF */
++
++ /* Numeric keypad */
++ SDLK_KP0 = 256,
++ SDLK_KP1 = 257,
++ SDLK_KP2 = 258,
++ SDLK_KP3 = 259,
++ SDLK_KP4 = 260,
++ SDLK_KP5 = 261,
++ SDLK_KP6 = 262,
++ SDLK_KP7 = 263,
++ SDLK_KP8 = 264,
++ SDLK_KP9 = 265,
++ SDLK_KP_PERIOD = 266,
++ SDLK_KP_DIVIDE = 267,
++ SDLK_KP_MULTIPLY = 268,
++ SDLK_KP_MINUS = 269,
++ SDLK_KP_PLUS = 270,
++ SDLK_KP_ENTER = 271,
++ SDLK_KP_EQUALS = 272,
++
++ /* Arrows + Home/End pad */
++ SDLK_UP = 273,
++ SDLK_DOWN = 274,
++ SDLK_RIGHT = 275,
++ SDLK_LEFT = 276,
++ SDLK_INSERT = 277,
++ SDLK_HOME = 278,
++ SDLK_END = 279,
++ SDLK_PAGEUP = 280,
++ SDLK_PAGEDOWN = 281,
++
++ /* Function keys */
++ SDLK_F1 = 282,
++ SDLK_F2 = 283,
++ SDLK_F3 = 284,
++ SDLK_F4 = 285,
++ SDLK_F5 = 286,
++ SDLK_F6 = 287,
++ SDLK_F7 = 288,
++ SDLK_F8 = 289,
++ SDLK_F9 = 290,
++ SDLK_F10 = 291,
++ SDLK_F11 = 292,
++ SDLK_F12 = 293,
++ SDLK_F13 = 294,
++ SDLK_F14 = 295,
++ SDLK_F15 = 296,
++
++ /* Key state modifier keys */
++ SDLK_NUMLOCK = 300,
++ SDLK_CAPSLOCK = 301,
++ SDLK_SCROLLOCK = 302,
++ SDLK_RSHIFT = 303,
++ SDLK_LSHIFT = 304,
++ SDLK_RCTRL = 305,
++ SDLK_LCTRL = 306,
++ SDLK_RALT = 307,
++ SDLK_LALT = 308,
++ SDLK_RMETA = 309,
++ SDLK_LMETA = 310,
++ SDLK_LSUPER = 311, /* Left "Windows" key */
++ SDLK_RSUPER = 312, /* Right "Windows" key */
++ SDLK_MODE = 313, /* "Alt Gr" key */
++ SDLK_COMPOSE = 314, /* Multi-key compose key */
++
++ /* Miscellaneous function keys */
++ SDLK_HELP = 315,
++ SDLK_PRINT = 316,
++ SDLK_SYSREQ = 317,
++ SDLK_BREAK = 318,
++ SDLK_MENU = 319,
++ SDLK_POWER = 320, /* Power Macintosh power key */
++ SDLK_EURO = 321, /* Some european keyboards */
++ SDLK_UNDO = 322, /* Atari keyboard has Undo */
++
++ /* Add any other keys here */
++
++ SDLK_LAST
++}
++
++/* Enumeration of valid key mods (possibly OR'd together) */
++alias int SDLMod;
++enum {
++ KMOD_NONE = 0x0000,
++ KMOD_LSHIFT= 0x0001,
++ KMOD_RSHIFT= 0x0002,
++ KMOD_LCTRL = 0x0040,
++ KMOD_RCTRL = 0x0080,
++ KMOD_LALT = 0x0100,
++ KMOD_RALT = 0x0200,
++ KMOD_LMETA = 0x0400,
++ KMOD_RMETA = 0x0800,
++ KMOD_NUM = 0x1000,
++ KMOD_CAPS = 0x2000,
++ KMOD_MODE = 0x4000,
++ KMOD_RESERVED = 0x8000
++}
++
++const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
++const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
++const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
++const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur p47/import/SDL_mixer.d p47-gentoo/import/SDL_mixer.d
+--- p47/import/SDL_mixer.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_mixer.d 2007-09-20 08:24:15.000000000 +0200
+@@ -22,9 +22,32 @@
+
+ // convert to D by shinichiro.h
+
+-/* $Id: SDL_mixer.d,v 1.1.1.1 2003/11/28 17:26:28 kenta Exp $ */
++/* $Id: SDL_mixer.d,v 1.1.1.1 2005/06/18 00:46:00 kenta Exp $ */
+
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+
+ extern (C) {
+
+diff -Naur p47/import/SDL_mouse.d p47-gentoo/import/SDL_mouse.d
+--- p47/import/SDL_mouse.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_mouse.d 2007-09-20 08:24:15.000000000 +0200
+@@ -109,6 +109,8 @@
+ const uint SDL_BUTTON_LEFT = 1;
+ const uint SDL_BUTTON_MIDDLE = 2;
+ const uint SDL_BUTTON_RIGHT = 3;
++const uint SDL_BUTTON_WHEELUP = 4;
++const uint SDL_BUTTON_WHEELDOWN = 5;
+ const uint SDL_BUTTON_LMASK = SDL_PRESSED << (SDL_BUTTON_LEFT - 1);
+ const uint SDL_BUTTON_MMASK = SDL_PRESSED << (SDL_BUTTON_MIDDLE - 1);
+ const uint SDL_BUTTON_RMASK = SDL_PRESSED << (SDL_BUTTON_RIGHT - 1);
+diff -Naur p47/import/SDL_quit.d p47-gentoo/import/SDL_quit.d
+--- p47/import/SDL_quit.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_quit.d 2007-09-20 08:24:15.000000000 +0200
+@@ -43,5 +43,5 @@
+ bit SDL_QuitRequested()
+ {
+ SDL_PumpEvents();
+- return SDL_PeepEvents(null, 0, SDL_PEEKEVENT, SDL_QUITMASK);
++ return cast(bit)SDL_PeepEvents(null, 0, SDL_PEEKEVENT, SDL_QUITMASK);
+ }
+diff -Naur p47/import/SDL_rwops.d p47-gentoo/import/SDL_rwops.d
+--- p47/import/SDL_rwops.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_rwops.d 2007-09-20 08:24:15.000000000 +0200
+@@ -28,6 +28,11 @@
+
+ extern(C):
+
++typedef int (*_seek_func_t)(SDL_RWops *context, int offset, int whence);
++typedef int (*_read_func_t)(SDL_RWops *context, void *ptr, int size, int maxnum);
++typedef int (*_write_func_t)(SDL_RWops *context, void *ptr, int size, int num);
++typedef int (*_close_func_t)(SDL_RWops *context);
++
+ /* This is the read/write operation structure -- very basic */
+
+ struct SDL_RWops {
+@@ -35,22 +40,26 @@
+ SEEK_SET, SEEK_CUR, SEEK_END
+ Returns the final offset in the data source.
+ */
+- int (*seek)(SDL_RWops *context, int offset, int whence);
++ _seek_func_t seek;
++// int (*seek)(SDL_RWops *context, int offset, int whence);
+
+ /* Read up to 'num' objects each of size 'objsize' from the data
+ source to the area pointed at by 'ptr'.
+ Returns the number of objects read, or -1 if the read failed.
+ */
+- int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
++ _read_func_t read;
++// int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
+
+ /* Write exactly 'num' objects each of size 'objsize' from the area
+ pointed at by 'ptr' to data source.
+ Returns 'num', or -1 if the write failed.
+ */
+- int (*write)(SDL_RWops *context, void *ptr, int size, int num);
++ _write_func_t write;
++// int (*write)(SDL_RWops *context, void *ptr, int size, int num);
+
+ /* Close and free an allocated SDL_FSops structure */
+- int (*close)(SDL_RWops *context);
++ _close_func_t close;
++// int (*close)(SDL_RWops *context);
+
+ Uint32 type;
+ union {
+@@ -84,35 +93,40 @@
+ /* Macros to easily read and write from an SDL_RWops structure */
+ int SDL_RWseek(SDL_RWops *ctx, int offset, int whence)
+ {
+- int (*seek)(SDL_RWops *context, int offset, int whence);
++ _seek_func_t seek;
++// int (*seek)(SDL_RWops *context, int offset, int whence);
+ seek = ctx.seek;
+ return (*seek)(ctx, offset, whence);
+ }
+
+ int SDL_RWtell(SDL_RWops *ctx)
+ {
+- int (*seek)(SDL_RWops *context, int offset, int whence);
++ _seek_func_t seek;
++// int (*seek)(SDL_RWops *context, int offset, int whence);
+ seek = ctx.seek;
+ return (*seek)(ctx, 0, 1);
+ }
+
+ int SDL_RWread(SDL_RWops *ctx, void* ptr, int size, int n)
+ {
+- int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
++ _read_func_t read;
++// int (*read)(SDL_RWops *context, void *ptr, int size, int maxnum);
+ read = ctx.read;
+ return (*read)(ctx, ptr, size, n);
+ }
+
+ int SDL_RWwrite(SDL_RWops *ctx, void* ptr, int size, int n)
+ {
+- int (*write)(SDL_RWops *context, void *ptr, int size, int num);
++ _write_func_t write;
++// int (*write)(SDL_RWops *context, void *ptr, int size, int num);
+ write = ctx.write;
+ return (*write)(ctx, ptr, size, n);
+ }
+
+ int SDL_RWclose(SDL_RWops *ctx)
+ {
+- int (*close)(SDL_RWops *context);
++ _close_func_t close;
++// int (*close)(SDL_RWops *context);
+ close = ctx.close;
+ return (*close)(ctx);
+ }
+diff -Naur p47/import/SDL_syswm.d p47-gentoo/import/SDL_syswm.d
+--- p47/import/SDL_syswm.d 2003-11-29 02:26:28.000000000 +0100
++++ p47-gentoo/import/SDL_syswm.d 2007-09-20 08:24:15.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-import SDL_version;
++import SDL_Version;
+
+ extern(C):
+
+diff -Naur p47/import/SDL_Version.d p47-gentoo/import/SDL_Version.d
+--- p47/import/SDL_Version.d 1970-01-01 01:00:00.000000000 +0100
++++ p47-gentoo/import/SDL_Version.d 2007-09-20 08:24:15.000000000 +0200
+@@ -0,0 +1,75 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* This header defines the current SDL version */
++
++import SDL_types;
++
++extern(C):
++
++/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
++*/
++const uint SDL_MAJOR_VERSION = 1;
++const uint SDL_MINOR_VERSION = 2;
++const uint SDL_PATCHLEVEL = 6;
++
++struct SDL_version {
++ Uint8 major;
++ Uint8 minor;
++ Uint8 patch;
++}
++
++/* This macro can be used to fill a version structure with the compile-time
++ * version of the SDL library.
++ */
++void SDL_VERSION(SDL_version* X)
++{
++ X.major = SDL_MAJOR_VERSION;
++ X.minor = SDL_MINOR_VERSION;
++ X.patch = SDL_PATCHLEVEL;
++}
++
++/* This macro turns the version numbers into a numeric value:
++ (1,2,3) -> (1203)
++ This assumes that there will never be more than 100 patchlevels
++*/
++uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return X * 1000 + Y * 100 + Z;
++}
++
++/* This is the version number macro for the current SDL version */
++const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
++ SDL_MINOR_VERSION * 100 +
++ SDL_PATCHLEVEL;
++
++/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
++bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
++}
++
++/* This function gets the version of the dynamically linked SDL library.
++ it should NOT be used to fill a version structure, instead you should
++ use the SDL_Version() macro.
++ */
++SDL_version * SDL_Linked_Version();
+diff -Naur p47/Makefile p47-gentoo/Makefile
+--- p47/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ p47-gentoo/Makefile 2007-09-20 08:24:15.000000000 +0200
+@@ -0,0 +1,29 @@
++DSRC=$(shell find src -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++CFLAGS=
++DFLAGS=-O -release -Iimport -Isrc -I/usr/X11R6/include/
++EXE=parsec47
++COBJS=src/dirent_d.o
++
++all: $(EXE)
++
++$(EXE): import/SDL_Keysym.d $(OBJS) $(COBJS)
++ gcc $(CFLAGS) -o $@ $(OBJS) $(COBJS) -lbulletml_d -L/usr/local/lib -L/usr/lib -lgphobos -lpthread -lGLU -lGL -lglut -lm -lstdc++ -lSDL -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ gdmd -d -c -of$@ $(DFLAGS) $<
++
++src/dirent_d.o: src/dirent_d.c
++ gcc -c $< -o $@
++
++import/SDL_Keysym.d:
++ mv import/SDL_keysym.d import/SDL_Keysym.d
++
++
++clean: rm src/*.o
++ rm src/abagames/p47/*.o
++ rm src/abagames/util/*.o
++ rm src/abagames/util/sdl/*.o
++ rm src/abagames/util/bulletml/*.o
++ rm import/*.o
+diff -Naur p47/src/abagames/p47/Bonus.d p47-gentoo/src/abagames/p47/Bonus.d
+--- p47/src/abagames/p47/Bonus.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Bonus.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.Bonus;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import abagames.util.Vector;
+@@ -63,7 +63,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- BonusInitializer bi = (BonusInitializer) ini;
++ BonusInitializer bi = cast(BonusInitializer) ini;
+ field = bi.field;
+ ship = bi.ship;
+ manager = bi.manager;
+@@ -126,13 +126,13 @@
+ missBonus();
+ isExist = false;
+ return;
+- }
++ }
+ }
+ cnt++;
+ if (cnt < RETRO_CNT)
+ return;
+ float d = pos.dist(ship.pos);
+- if (d < ACQUIRE_WIDTH * (1 + (float) inhaleCnt * 0.2) && ship.cnt >= -Ship.INVINCIBLE_CNT) {
++ if (d < ACQUIRE_WIDTH * (1 + cast(float) inhaleCnt * 0.2) && ship.cnt >= -Ship.INVINCIBLE_CNT) {
+ getBonus();
+ isExist = false;
+ return;
+@@ -157,8 +157,8 @@
+ public override void draw() {
+ float retro;
+ if (cnt < RETRO_CNT)
+- retro = 1 - (float) cnt / RETRO_CNT;
+- else
++ retro = 1 - cast(float) cnt / RETRO_CNT;
++ else
+ retro = 0;
+ float d = cnt * 0.1;
+ float ox = sin(d) * 0.3;
+@@ -176,9 +176,9 @@
+ Screen3D.setColor(0.4, 0.9, 0.6, 0.7);
+ else
+ Screen3D.setColor(0.8, 0.9, 0.5, 0.7);
+- P47Screen.drawBoxLine(pos.x - ox - BOX_SIZE / 2, pos.y - oy - BOX_SIZE / 2,
++ P47Screen.drawBoxLine(pos.x - ox - BOX_SIZE / 2, pos.y - oy - BOX_SIZE / 2,
+ BOX_SIZE, BOX_SIZE);
+- P47Screen.drawBoxLine(pos.x + ox - BOX_SIZE / 2, pos.y + oy - BOX_SIZE / 2,
++ P47Screen.drawBoxLine(pos.x + ox - BOX_SIZE / 2, pos.y + oy - BOX_SIZE / 2,
+ BOX_SIZE, BOX_SIZE);
+ P47Screen.drawBoxLine(pos.x - oy - BOX_SIZE / 2, pos.y + ox - BOX_SIZE / 2,
+ BOX_SIZE, BOX_SIZE);
+diff -Naur p47/src/abagames/p47/BulletActor.d p47-gentoo/src/abagames/p47/BulletActor.d
+--- p47/src/abagames/p47/BulletActor.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/BulletActor.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.BulletActor;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import bulletml;
+@@ -59,7 +59,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- BulletActorInitializer bi = (BulletActorInitializer) ini;
++ BulletActorInitializer bi = cast(BulletActorInitializer) ini;
+ field = bi.field;
+ ship = bi.ship;
+ bullet = new P47Bullet(nextId);
+@@ -80,8 +80,8 @@
+ backToRetro = false;
+ }
+
+- public void set(BulletMLRunner* runner,
+- float x, float y, float deg, float speed, float rank,
++ public void set(BulletMLRunner* runner,
++ float x, float y, float deg, float speed, float rank,
+ float speedRank, int shape, int color, float size, float xReverse) {
+ bullet.set(runner, x, y, deg, speed, rank);
+ bullet.isMorph = false;
+@@ -89,8 +89,8 @@
+ start(speedRank, shape, color, size, xReverse);
+ }
+
+- public void set(BulletMLRunner* runner,
+- float x, float y, float deg, float speed, float rank,
++ public void set(BulletMLRunner* runner,
++ float x, float y, float deg, float speed, float rank,
+ float speedRank, int shape, int color, float size, float xReverse,
+ BulletMLParser *morph[], int morphNum, int morphIdx, int morphCnt) {
+ bullet.set(runner, x, y, deg, speed, rank);
+@@ -163,8 +163,8 @@
+ if (hd >= 0 && hd <= SHIP_HIT_WIDTH) {
+ ship.destroyed();
+ }
+- }
+- }
++ }
++ }
+ }
+
+ public override void move() {
+@@ -200,9 +200,9 @@
+ if (cnt > BULLET_DISAPPEAR_CNT)
+ toRetro();
+ }
+- bullet.pos.x +=
++ bullet.pos.x +=
+ (sin(bullet.deg) * bullet.speed + bullet.acc.x) * sr * bullet.xReverse;
+- bullet.pos.y +=
++ bullet.pos.y +=
+ (cos(bullet.deg) * bullet.speed - bullet.acc.y) * sr;
+ if (isVisible) {
+ totalBulletsSpeed += bullet.speed * sr;
+@@ -231,8 +231,8 @@
+ private void drawRetro(float d) {
+ float rt = 1 - rtCnt / RETRO_CNT;
+ P47Screen.setRetroParam(rt, 0.4 * bullet.bulletSize);
+- P47Screen.setRetroColor(bulletColor[bullet.color][0],
+- bulletColor[bullet.color][1],
++ P47Screen.setRetroColor(bulletColor[bullet.color][0],
++ bulletColor[bullet.color][1],
+ bulletColor[bullet.color][2], 1);
+ float x, y, tx, px, py, fx, fy;
+ for (int i = 0; i < shapePos[bullet.shape].length; i++) {
+@@ -291,9 +291,9 @@
+ private static const float SHAPE_BASE_COLOR_R = 1;
+ private static const float SHAPE_BASE_COLOR_G = 0.9;
+ private static const float SHAPE_BASE_COLOR_B = 0.7;
+- private static const float bulletColor[BULLET_COLOR_NUM][3] =
++ private static const float bulletColor[BULLET_COLOR_NUM][3] =
+ [
+- [1, 0, 0], [0.2, 1, 0.4], [0.3, 0.3, 1], [1, 1, 0],
++ [1, 0, 0], [0.2, 1, 0.4], [0.3, 0.3, 1], [1, 1, 0],
+ ];
+
+ public static void createDisplayLists() {
+diff -Naur p47/src/abagames/p47/BulletActorPool.d p47-gentoo/src/abagames/p47/BulletActorPool.d
+--- p47/src/abagames/p47/BulletActorPool.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/BulletActorPool.d 2007-09-20 08:24:15.000000000 +0200
+@@ -32,10 +32,10 @@
+ }
+
+ public void addBullet(float deg, float speed) {
+- BulletActor ba = (BulletActor) getInstance();
++ BulletActor ba = cast(BulletActor) getInstance();
+ if (!ba)
+ return;
+- P47Bullet rb = (P47Bullet) Bullet.now;
++ P47Bullet rb = cast(P47Bullet) Bullet.now;
+ if (rb.isMorph) {
+ BulletMLRunner *runner = BulletMLRunner_new_parser(rb.morphParser[rb.morphIdx]);
+ BulletActorPool.registFunctions(runner);
+@@ -51,12 +51,12 @@
+ }
+
+ public void addBullet(BulletMLState *state, float deg, float speed) {
+- BulletActor ba = (BulletActor) getInstance();
++ BulletActor ba = cast(BulletActor) getInstance();
+ if (!ba)
+ return;
+ BulletMLRunner* runner = BulletMLRunner_new_state(state);
+ registFunctions(runner);
+- P47Bullet rb = (P47Bullet) Bullet.now;
++ P47Bullet rb = cast(P47Bullet) Bullet.now;
+ if (rb.isMorph)
+ ba.set(runner, Bullet.now.pos.x, Bullet.now.pos.y, deg, speed,
+ Bullet.now.rank,
+@@ -72,7 +72,7 @@
+ float x, float y, float deg, float speed,
+ float rank,
+ float speedRank, int shape, int color, float size, float xReverse) {
+- BulletActor ba = (BulletActor) getInstance();
++ BulletActor ba = cast(BulletActor) getInstance();
+ if (!ba)
+ return null;
+ ba.set(runner, x, y, deg, speed, rank, speedRank, shape, color, size, xReverse);
+@@ -99,7 +99,7 @@
+ float rank,
+ float speedRank, int shape, int color, float size, float xReverse,
+ BulletMLParser *morph[], int morphNum, int morphCnt) {
+- BulletActor ba = (BulletActor) getInstance();
++ BulletActor ba = cast(BulletActor) getInstance();
+ if (!ba)
+ return null;
+ ba.set(runner, x, y, deg, speed, rank,
+@@ -119,14 +119,14 @@
+ }
+
+ public void killMe(Bullet bullet) {
+- assert(((BulletActor) actor[bullet.id]).bullet.id == bullet.id);
+- ((BulletActor) actor[bullet.id]).remove();
++ assert((cast(BulletActor) actor[bullet.id]).bullet.id == bullet.id);
++ (cast(BulletActor) actor[bullet.id]).remove();
+ }
+
+ public override void clear() {
+ for (int i = 0; i < actor.length; i++) {
+ if (actor[i].isExist)
+- ((BulletActor) actor[i]).remove();
++ (cast(BulletActor) actor[i]).remove();
+ }
+ }
+
+@@ -155,7 +155,7 @@
+ double getAimDirectionWithXRev_(BulletMLRunner* r) {
+ Vector b = Bullet.now.pos;
+ Vector t = Bullet.target;
+- float xrev = ((P47Bullet) Bullet.now).xReverse;
++ float xrev = (cast(P47Bullet) Bullet.now).xReverse;
+ return rtod(std.math.atan2(t.x - b.x, t.y - b.y) * xrev);
+ }
+ }
+diff -Naur p47/src/abagames/p47/Enemy.d p47-gentoo/src/abagames/p47/Enemy.d
+--- p47/src/abagames/p47/Enemy.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Enemy.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.Enemy;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import bulletml;
+@@ -78,7 +78,7 @@
+ int velCnt;
+ bool damaged;
+ int bossTimer;
+-
++
+ public static this() {
+ rand = new Rand;
+ }
+@@ -88,7 +88,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- EnemyInitializer ei = (EnemyInitializer) ini;
++ EnemyInitializer ei = cast(EnemyInitializer) ini;
+ field = ei.field;
+ bullets = ei.bullets;
+ shots = ei.shots;
+@@ -107,13 +107,13 @@
+ }
+
+ public void set(Vector p, float d, EnemyType type, BulletMLParser *moveParser) {
+- pos.x = p.x;
++ pos.x = p.x;
+ pos.y = p.y;
+ this.type = type;
+ BulletMLRunner *moveRunner = BulletMLRunner_new_parser(moveParser);
+ BulletActorPool.registFunctions(moveRunner);
+ moveBullet = bullets.addBullet(moveRunner,
+- pos.x, pos.y, d, 0, 0.5,
++ pos.x, pos.y, d, 0, 0.5,
+ 1, 0, 0, 1, 1);
+ if (!moveBullet)
+ return;
+@@ -131,7 +131,7 @@
+ }
+
+ public void setBoss(Vector p, float d, EnemyType type) {
+- pos.x = p.x;
++ pos.x = p.x;
+ pos.y = p.y;
+ this.type = type;
+ moveBullet = null;
+@@ -154,7 +154,7 @@
+ int idx1 = rand.nextInt(movePointNum);
+ int idx2 = rand.nextInt(movePointNum);
+ if (idx1 == idx2) {
+- idx2++;
++ idx2++;
+ if (idx2 >= movePointNum) idx2 = 0;
+ }
+ Vector mp = movePoint[idx1];
+@@ -198,8 +198,8 @@
+ if (br.morphCnt > 0)
+ ba = bullets.addBullet
+ (br.parser, runner,
+- bx, by, baseDeg, 0, br.rank,
+- br.speedRank,
++ bx, by, baseDeg, 0, br.rank,
++ br.speedRank,
+ br.shape, br.color, br.bulletSize,
+ br.xReverse * xr,
+ br.morphParser, br.morphNum, br.morphCnt);
+@@ -207,7 +207,7 @@
+ ba = bullets.addBullet
+ (br.parser, runner,
+ bx, by, baseDeg, 0, br.rank,
+- br.speedRank,
++ br.speedRank,
+ br.shape, br.color, br.bulletSize,
+ br.xReverse * xr);
+ return ba;
+@@ -234,7 +234,7 @@
+ }
+
+ private void addBonuses(Vector p, int sl) {
+- int bn = (float) sl * 3 / (((float) cnt / 30) + 1) * Bonus.rate + 0.9;
++ int bn = cast(int)(cast(float) sl * 3 / ((cast(float) cnt / 30) + 1) * Bonus.rate + 0.9);
+ manager.addBonus(pos, p, bn);
+ }
+
+@@ -277,7 +277,7 @@
+ private static int LOCK_DAMAGE = 7;
+ private static const int ENEMY_TYPE_SCORE[] = [100, 500, 1000, 5000, 10000];
+ private static const int ENEMY_WING_SCORE = 1000;
+-
++
+ private void addDamage(int dmg) {
+ shield -= dmg;
+ if (shield <= 0) {
+@@ -342,7 +342,7 @@
+
+ // Check shots and rolls hit the enemy.
+ private int checkHit(Vector p, float xofs, float yofs) {
+- if (fabs(p.x - pos.x) < type.collisionSize.x + xofs &&
++ if (fabs(p.x - pos.x) < type.collisionSize.x + xofs &&
+ fabs(p.y - pos.y) < type.collisionSize.y + yofs)
+ return HIT;
+ if (type.wingCollision) {
+@@ -350,7 +350,7 @@
+ if (battery[i].shield <= 0)
+ continue;
+ BatteryType bt = type.batteryType[i];
+- if (fabs(p.x - pos.x - bt.collisionPos.x) < bt.collisionSize.x + xofs &&
++ if (fabs(p.x - pos.x - bt.collisionPos.x) < bt.collisionSize.x + xofs &&
+ fabs(p.y - pos.y - bt.collisionPos.y) < bt.collisionSize.y + yofs)
+ return i;
+ }
+@@ -371,7 +371,7 @@
+ continue;
+ BatteryType bt = type.batteryType[i];
+ float by = pos.y + bt.collisionPos.y;
+- if (fabs(p.x - pos.x - bt.collisionPos.x) < bt.collisionSize.x + xofs &&
++ if (fabs(p.x - pos.x - bt.collisionPos.x) < bt.collisionSize.x + xofs &&
+ by < lock.lockMinY && by > p.y) {
+ lock.lockMinY = by;
+ lp = i;
+@@ -389,7 +389,7 @@
+ for (int i = 0; i < shots.actor.length; i++) {
+ if (!shots.actor[i].isExist)
+ continue;
+- Vector sp = ((Shot) shots.actor[i]).pos;
++ Vector sp = (cast(Shot) shots.actor[i]).pos;
+ ch = checkHit(sp, 0.7, 0);
+ if (ch >= HIT) {
+ manager.addParticle(sp, rand.nextSignedFloat(0.3), 0, Shot.SPEED / 4);
+@@ -407,7 +407,7 @@
+ for (int i = 0; i < rolls.actor.length; i++) {
+ if (!rolls.actor[i].isExist)
+ continue;
+- Roll rl = (Roll) rolls.actor[i];
++ Roll rl = cast(Roll) rolls.actor[i];
+ ch = checkHit(rl.pos[0], 1.0, 1.0);
+ if (ch >= HIT) {
+ for (int i = 0; i < 4; i++)
+@@ -420,9 +420,9 @@
+ continue;
+ }
+ if (ch == HIT)
+- addDamage(rd);
++ addDamage(cast(int)rd);
+ else
+- addDamageBattery(ch, rd);
++ addDamageBattery(ch, cast(int)rd);
+ }
+ }
+ } else if (type.type != EnemyType.SMALL) {
+@@ -430,7 +430,7 @@
+ for (int i = 0; i < locks.actor.length; i++) {
+ if (!locks.actor[i].isExist)
+ continue;
+- Lock lk = (Lock) locks.actor[i];
++ Lock lk = cast(Lock) locks.actor[i];
+ if (lk.state == Lock.SEARCH || lk.state == Lock.SEARCHED) {
+ ch = checkLocked(lk.pos[0], 2.5, lk);
+ if (ch >= HIT) {
+@@ -494,7 +494,7 @@
+ float od = d - deg;
+ if (od > std.math.PI)
+ od -= std.math.PI * 2;
+- else if (od < -std.math.PI)
++ else if (od < -std.math.PI)
+ od += std.math.PI * 2;
+ float aod = std.math.fabs(od);
+ if (aod < BOSS_MOVE_DEG) {
+@@ -595,7 +595,7 @@
+ if (z < 0)
+ z -= APPEARANCE_Z / 60;
+ appCnt--;
+- mtr = 1.0 - (float)appCnt / APPEARANCE_CNT;
++ mtr = 1.0 - cast(float)appCnt / APPEARANCE_CNT;
+ } else if (dstCnt > 0) {
+ addFragments(1, z, 0.05, rand.nextSignedFloat(std.math.PI));
+ manager.clearBullets();
+@@ -609,7 +609,7 @@
+ manager.setBossShieldMeter(0, 0, 0, 0, 0, 0);
+ return;
+ }
+- mtr = (float)dstCnt / DESTROYED_CNT;
++ mtr = cast(float)dstCnt / DESTROYED_CNT;
+ } else if (timeoutCnt > 0) {
+ z += DESTROYED_Z / 60;
+ timeoutCnt--;
+@@ -641,16 +641,16 @@
+ if (appCnt > 0) {
+ // Appearance effect of the boss.
+ P47Screen.setRetroZ(z);
+- ap = (float) appCnt / APPEARANCE_CNT;
++ ap = cast(float) appCnt / APPEARANCE_CNT;
+ P47Screen.setRetroParam(1, type.retroSize * (1 + ap * 10));
+ P47Screen.setRetroColor(type.r, type.g, type.b, (1 - ap));
+ } else if (dstCnt > 0) {
+ P47Screen.setRetroZ(z);
+- ap = (float) dstCnt / DESTROYED_CNT / 2 + 0.5;
++ ap = cast(float) dstCnt / DESTROYED_CNT / 2 + 0.5;
+ P47Screen.setRetroColor(type.r, type.g, type.b, ap);
+ } else if (timeoutCnt > 0) {
+ P47Screen.setRetroZ(z);
+- ap = (float) timeoutCnt / TIMEOUT_CNT;
++ ap = cast(float) timeoutCnt / TIMEOUT_CNT;
+ P47Screen.setRetroColor(type.r, type.g, type.b, ap);
+ } else {
+ P47Screen.setRetroParam(1, type.retroSize);
+@@ -728,7 +728,7 @@
+ Ship ship;
+ P47GameManager manager;
+
+- public this(Field field, BulletActorPool bullets, ActorPool shots,
++ public this(Field field, BulletActorPool bullets, ActorPool shots,
+ ActorPool rolls, ActorPool locks, Ship ship, P47GameManager manager) {
+ this.field = field;
+ this.bullets = bullets;
+diff -Naur p47/src/abagames/p47/EnemyType.d p47-gentoo/src/abagames/p47/EnemyType.d
+--- p47/src/abagames/p47/EnemyType.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/EnemyType.d 2007-09-20 08:24:15.000000000 +0200
+@@ -123,7 +123,7 @@
+
+ // To avoid using the same morph pattern.
+ private static bool usedMorphParser[BarrageManager.BARRAGE_MAX];
+-
++
+ private void setBarrageType(Barrage br, int btn, int mode) {
+ br.parser = barrageManager.parser
+ [btn]
+@@ -236,7 +236,7 @@
+ }
+ }
+
+- private static const float[][] enemySize =
++ private static const float[][] enemySize =
+ [
+ [0.3, 0.3, 0.3, 0.1, 0.1, 1.0, 0.4, 0.6, 0.9],
+ [0.4, 0.2, 0.4, 0.1, 0.15, 2.2, 0.2, 1.6, 1.0],
+@@ -244,9 +244,9 @@
+ [0.9, 0.3, 0.7, 0.2, 0.25, 5.0, 0.6, 3.0, 1.5],
+ [1.2, 0.2, 0.9, 0.1, 0.3, 7.0, 0.8, 4.5, 1.5],
+ ];
+- private enum {
+- SMALL, MIDDLE, LARGE, MIDDLEBOSS, LARGEBOSS,
+- }
++// private enum {
++// SMALL, MIDDLE, LARGE, MIDDLEBOSS, LARGEBOSS,
++ //}
+
+ // Set the shepe of the BatteryType.
+ private void setEnemyShapeAndWings(int size) {
+@@ -370,7 +370,7 @@
+ }
+
+ // Set the barrage of the BatteryType.
+- private void setBattery(float rank, int n, int barrageType, int barrageIntense,
++ private void setBattery(float rank, int n, int barrageType, int barrageIntense,
+ int idx, int ptnIdx, float slow, int mode) {
+ BatteryType bt = batteryType[idx];
+ BatteryType bt2 = batteryType[idx + 1];
+@@ -482,12 +482,12 @@
+ shield = 40 + rand.nextInt(10);
+ setBattery(sr, 1, BarrageManager.MIDDLESUB, NORMAL, 0, 0, 1, mode);
+ fireInterval = 100 + rand.nextInt(60);
+- firePeriod = fireInterval / (1.8 + rand.nextFloat(0.7));
++ firePeriod = cast(int)(fireInterval / (1.8 + rand.nextFloat(0.7)));
+ } else {
+ shield = 30 + rand.nextInt(8);
+ setBattery(sr, 1, BarrageManager.MIDDLESUB_LOCK, NORMAL, 0, 0, 1, mode);
+ fireInterval = 72 + rand.nextInt(30);
+- firePeriod = fireInterval / (1.2 + rand.nextFloat(0.2));
++ firePeriod = cast(int)(fireInterval / (1.2 + rand.nextFloat(0.2)));
+ }
+ if (rank < 10)
+ firePeriod /= (2 - rank * 0.1);
+@@ -565,13 +565,13 @@
+ setBattery(sr1, 1, BarrageManager.MIDDLESUB, NORMAL, 0, 0, 1, mode);
+ setBattery(sr2, 1, BarrageManager.MIDDLESUB, NORMAL, 2, 0, 1, mode);
+ fireInterval = 150 + rand.nextInt(60);
+- firePeriod = fireInterval / (1.3 + rand.nextFloat(0.8));
++ firePeriod = cast(int)(fireInterval / (1.3 + rand.nextFloat(0.8)));
+ } else {
+ shield = 45 + rand.nextInt(8);
+ setBattery(sr1, 1, BarrageManager.MIDDLESUB_LOCK, NORMAL, 0, 0, 1, mode);
+ setBattery(sr2, 1, BarrageManager.MIDDLESUB_LOCK, NORMAL, 2, 0, 1, mode);
+ fireInterval = 100 + rand.nextInt(50);
+- firePeriod = fireInterval / (1.2 + rand.nextFloat(0.2));
++ firePeriod = cast(int)(fireInterval / (1.2 + rand.nextFloat(0.2)));
+ }
+ if (rank < 10)
+ firePeriod /= (2 - rank * 0.1);
+@@ -609,7 +609,7 @@
+ }
+ shield = 300 + rand.nextInt(50);
+ fireInterval = 200 + rand.nextInt(40);
+- firePeriod = fireInterval / (1.2 + rand.nextFloat(0.4));
++ firePeriod = cast(int)(fireInterval / (1.2 + rand.nextFloat(0.4)));
+ if (rank < 10)
+ firePeriod /= (2 - rank * 0.1);
+ }
+@@ -650,7 +650,7 @@
+ }
+ shield = 400 + rand.nextInt(50);
+ fireInterval = 220 + rand.nextInt(60);
+- firePeriod = fireInterval / (1.2 + rand.nextFloat(0.3));
++ firePeriod = cast(int)(fireInterval / (1.2 + rand.nextFloat(0.3)));
+ if (rank < 10)
+ firePeriod /= (2 - rank * 0.1);
+ }
+diff -Naur p47/src/abagames/p47/Field.d p47-gentoo/src/abagames/p47/Field.d
+--- p47/src/abagames/p47/Field.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Field.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.Field;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import abagames.util.Vector;
+@@ -97,7 +97,7 @@
+ float d = -RING_NUM * RING_ANGLE_INT / 2 + roll;
+ for (int i = 0; i < RING_NUM; i++) {
+ for (int j = 1; j < 8; j++) {
+- float sc = (float) j / 16 + 0.5;
++ float sc = cast(float) j / 16 + 0.5;
+ glPushMatrix();
+ glTranslatef(0, 0, z);
+ glRotatef(d, 1, 0, 0);
+@@ -118,7 +118,7 @@
+ }
+
+ public bool checkHit(Vector p, float space) {
+- if (p.x < -size.x + space || p.x > size.x - space ||
++ if (p.x < -size.x + space || p.x > size.x - space ||
+ p.y < -size.y + space || p.y > size.y - space)
+ return true;
+ return false;
+@@ -126,7 +126,7 @@
+
+ private static const int RING_POS_NUM = 16;
+ private static Vector ringPos[RING_POS_NUM];
+- private static const float RING_DEG = std.math.PI / 3 / ((float) (RING_POS_NUM / 2) + 0.5);
++ private static const float RING_DEG = std.math.PI / 3 / (cast(float) (RING_POS_NUM / 2) + 0.5);
+ private static const float RING_RADIUS = 10;
+ private static const float RING_SIZE = 0.5;
+
+@@ -134,10 +134,10 @@
+ glBegin(GL_LINE_STRIP);
+ for (int i = 0; i <= RING_POS_NUM / 2 - 2; i++) {
+ glVertex3f(ringPos[i].x, RING_SIZE, ringPos[i].y);
+- }
++ }
+ for (int i = RING_POS_NUM / 2 - 2; i >= 0; i--) {
+ glVertex3f(ringPos[i].x, -RING_SIZE, ringPos[i].y);
+- }
++ }
+ glVertex3f(ringPos[0].x, RING_SIZE, ringPos[0].y);
+ glEnd();
+ glBegin(GL_LINE_STRIP);
+@@ -150,16 +150,16 @@
+ glBegin(GL_LINE_STRIP);
+ for (int i = RING_POS_NUM / 2 + 1; i <= RING_POS_NUM - 1; i++) {
+ glVertex3f(ringPos[i].x, RING_SIZE, ringPos[i].y);
+- }
++ }
+ for (int i = RING_POS_NUM - 1; i >= RING_POS_NUM / 2 + 1; i--) {
+ glVertex3f(ringPos[i].x, -RING_SIZE, ringPos[i].y);
+- }
++ }
+ glVertex3f(ringPos[RING_POS_NUM / 2 + 1].x, RING_SIZE, ringPos[RING_POS_NUM / 2 + 1].y);
+ glEnd();
+ }
+
+ public static void createDisplayLists() {
+- float d = -RING_DEG * ((float) (RING_POS_NUM / 2) - 0.5);
++ float d = -RING_DEG * (cast(float) (RING_POS_NUM / 2) - 0.5);
+ for (int i = 0; i < RING_POS_NUM; i++, d += RING_DEG) {
+ ringPos[i] = new Vector;
+ ringPos[i].x = sin(d) * RING_RADIUS;
+diff -Naur p47/src/abagames/p47/Fragment.d p47-gentoo/src/abagames/p47/Fragment.d
+--- p47/src/abagames/p47/Fragment.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Fragment.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.Fragment;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import abagames.util.Vector;
+@@ -43,7 +43,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- FragmentInitializer fi = (FragmentInitializer) ini;
++ FragmentInitializer fi = cast(FragmentInitializer) ini;
+ for (int i = 0; i < POINT_NUM; i++) {
+ pos[i] = new Vector;
+ vel[i] = new Vector;
+diff -Naur p47/src/abagames/p47/LetterRender.d p47-gentoo/src/abagames/p47/LetterRender.d
+--- p47/src/abagames/p47/LetterRender.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/LetterRender.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.LetterRender;
+
+-private:
++//private:
+ import opengl;
+ import abagames.util.sdl.Screen3D;
+ import abagames.p47.P47Screen;
+@@ -23,7 +23,7 @@
+ WHITE, RED
+ }
+
+- private static void changeColor(int c) {
++ public static void changeColor(int c) {
+ colorIdx = c * LETTER_NUM;
+ }
+
+@@ -177,22 +177,22 @@
+ float x, y, length, size, t;
+ int deg;
+ for (int i = 0;; i++) {
+- deg = (int) spData[idx][i][4];
++ deg = cast(int) spData[idx][i][4];
+ if (deg > 99990) break;
+- x = -spData[idx][i][0];
++ x = -spData[idx][i][0];
+ y = -spData[idx][i][1];
+- size = spData[idx][i][2];
++ size = spData[idx][i][2];
+ length = spData[idx][i][3];
+- size *= 0.66f;
++ size *= 0.66f;
+ length *= 0.6f;
+- x = -x;
++ x = -x;
+ y = y;
+ deg %= 180;
+- if (deg <= 45 || deg > 135)
++ if (deg <= 45 || deg > 135)
+ drawBox(x, y, size, length, r, g, b);
+- else
++ else
+ drawBox(x, y, length, size, r, g, b);
+- }
++ }
+ }
+
+ private static const int LETTER_NUM = 42;
+@@ -215,7 +215,7 @@
+ glDeleteLists(displayListIdx, LETTER_NUM * 2);
+ }
+
+- private static float[5][16][] spData =
++ private static float[5][16][] spData =
+ [[
+ [0, 1.15f, 0.65f, 0.3f, 0],
+ [-0.6f, 0.55f, 0.65f, 0.3f, 90], [0.6f, 0.55f, 0.65f, 0.3f, 90],
+diff -Naur p47/src/abagames/p47/Lock.d p47-gentoo/src/abagames/p47/Lock.d
+--- p47/src/abagames/p47/Lock.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Lock.d 2007-09-20 08:24:15.000000000 +0200
+@@ -52,7 +52,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- LockInitializer li = (LockInitializer) ini;
++ LockInitializer li = cast(LockInitializer) ini;
+ ship = li.ship;
+ field = li.field;
+ manager = li.manager;
+diff -Naur p47/src/abagames/p47/LuminousActorPool.d p47-gentoo/src/abagames/p47/LuminousActorPool.d
+--- p47/src/abagames/p47/LuminousActorPool.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/LuminousActorPool.d 2007-09-20 08:24:15.000000000 +0200
+@@ -22,7 +22,7 @@
+ public void drawLuminous() {
+ for (int i = 0; i < actor.length; i++) {
+ if (actor[i].isExist)
+- ((LuminousActor) actor[i]).drawLuminous();
++ (cast(LuminousActor) actor[i]).drawLuminous();
+ }
+ }
+ }
+diff -Naur p47/src/abagames/p47/LuminousScreen.d p47-gentoo/src/abagames/p47/LuminousScreen.d
+--- p47/src/abagames/p47/LuminousScreen.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/LuminousScreen.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.LuminousScreen;
+
+-private:
++//private:
+ import std.math;
+ import std.string;
+ import opengl;
+@@ -19,7 +19,7 @@
+ GLuint luminousTexture;
+ const int LUMINOUS_TEXTURE_WIDTH_MAX = 64;
+ const int LUMINOUS_TEXTURE_HEIGHT_MAX = 64;
+- GLuint td[LUMINOUS_TEXTURE_WIDTH_MAX * LUMINOUS_TEXTURE_HEIGHT_MAX * 4 * uint.size];
++ GLuint td[LUMINOUS_TEXTURE_WIDTH_MAX * LUMINOUS_TEXTURE_HEIGHT_MAX * 4 * uint.sizeof];
+ int luminousTextureWidth = 64, luminousTextureHeight = 64;
+ int screenWidth, screenHeight;
+ float luminous;
+@@ -27,7 +27,7 @@
+ private void makeLuminousTexture() {
+ uint *data = td;
+ int i;
+- memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.size);
++ // cast(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
+ glGenTextures(1, &luminousTexture);
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 4, luminousTextureWidth, luminousTextureHeight, 0,
+@@ -57,7 +57,7 @@
+
+ public void endRenderToTexture() {
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+- glCopyTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA,
++ glCopyTexImage2D(GL_TEXTURE_2D, 0, GL_RGBA,
+ 0, 0, luminousTextureWidth, luminousTextureHeight, 0);
+ glViewport(0, 0, screenWidth, screenHeight);
+ }
+diff -Naur p47/src/abagames/p47/P47Boot.d p47-gentoo/src/abagames/p47/P47Boot.d
+--- p47/src/abagames/p47/P47Boot.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/P47Boot.d 2007-09-20 08:24:15.000000000 +0200
+@@ -6,7 +6,7 @@
+ module abagames.p47.P47Boot;
+
+ private:
+-import std.string;
++//import std.string;
+ import std.c.stdlib;
+ import abagames.util.Logger;
+ import abagames.util.sdl.Pad;
+@@ -42,7 +42,7 @@
+ throw new Exception("Invalid options");
+ }
+ i++;
+- float b = (float) atoi(args[i]) / 100;
++ float b = cast(float) atoi(args[i]) / 100;
+ if (b < 0 || b > 1) {
+ usage(args[0]);
+ throw new Exception("Invalid options");
+@@ -55,7 +55,7 @@
+ throw new Exception("Invalid options");
+ }
+ i++;
+- float l = (float) atoi(args[i]) / 100;
++ float l = cast(float) atoi(args[i]) / 100;
+ if (l < 0 || l > 1) {
+ usage(args[0]);
+ throw new Exception("Invalid options");
+diff -Naur p47/src/abagames/p47/P47GameManager.d p47-gentoo/src/abagames/p47/P47GameManager.d
+--- p47/src/abagames/p47/P47GameManager.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/P47GameManager.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,10 +5,33 @@
+ */
+ module abagames.p47.P47GameManager;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import bulletml;
+ import abagames.util.Rand;
+ import abagames.util.Vector;
+@@ -88,9 +111,9 @@
+
+ // Initialize actor pools, load BGMs/SEs and textures.
+ public override void init() {
+- pad = (Pad) input;
+- prefManager = (P47PrefManager) abstPrefManager;
+- screen = (P47Screen) abstScreen;
++ pad = cast(Pad) input;
++ prefManager = cast(P47PrefManager) abstPrefManager;
++ screen = cast(P47Screen) abstScreen;
+ rand = new Rand;
+ Field.createDisplayLists();
+ field = new Field;
+@@ -177,22 +200,22 @@
+ }
+
+ public void addParticle(Vector pos, float deg, float ofs, float speed) {
+- Particle pt = (Particle) particles.getInstanceForced();
++ Particle pt = cast(Particle) particles.getInstanceForced();
+ assert(pt);
+ pt.set(pos, deg, ofs, speed);
+ }
+
+- public void addFragments(int n, float x1, float y1, float x2, float y2, float z,
++ public void addFragments(int n, float x1, float y1, float x2, float y2, float z,
+ float speed, float deg) {
+ for (int i = 0; i < n; i++) {
+- Fragment ft = (Fragment) fragments.getInstanceForced();
++ Fragment ft = cast(Fragment) fragments.getInstanceForced();
+ assert(ft);
+ ft.set(x1, y1, x2, y2, z, speed, deg);
+ }
+ }
+
+ public void addEnemy(Vector pos, float d, EnemyType type, BulletMLParser *moveParser) {
+- Enemy en = (Enemy) enemies.getInstance();
++ Enemy en = cast(Enemy) enemies.getInstance();
+ if (!en)
+ return;
+ en.set(pos, d, type, moveParser);
+@@ -202,33 +225,33 @@
+ for (int i = 0; i < bullets.actor.length; i++) {
+ if (!bullets.actor[i].isExist)
+ continue;
+- ((BulletActor) bullets.actor[i]).toRetro();
++ (cast(BulletActor) bullets.actor[i]).toRetro();
+ }
+ }
+
+ public void addBoss(Vector pos, float d, EnemyType type) {
+- Enemy en = (Enemy) enemies.getInstance();
++ Enemy en = cast(Enemy) enemies.getInstance();
+ if (!en)
+ return;
+ en.setBoss(pos, d, type);
+ }
+
+ public void addShot(Vector pos, float deg) {
+- Shot shot = (Shot) shots.getInstance();
++ Shot shot = cast(Shot) shots.getInstance();
+ if (!shot)
+ return;
+ shot.set(pos, deg);
+ }
+
+ public void addRoll() {
+- Roll roll = (Roll) rolls.getInstance();
++ Roll roll = cast(Roll) rolls.getInstance();
+ if (!roll)
+ return;
+ roll.set();
+ }
+
+ public void addLock() {
+- Lock lock = (Lock) locks.getInstance();
++ Lock lock = cast(Lock) locks.getInstance();
+ if (!lock)
+ return;
+ lock.set();
+@@ -238,7 +261,7 @@
+ for (int i = 0; i < rolls.actor.length; i++) {
+ if (!rolls.actor[i].isExist)
+ continue;
+- ((Roll) rolls.actor[i]).released = true;
++ (cast(Roll) rolls.actor[i]).released = true;
+ }
+ }
+
+@@ -246,14 +269,14 @@
+ for (int i = 0; i < locks.actor.length; i++) {
+ if (!locks.actor[i].isExist)
+ continue;
+- ((Lock) locks.actor[i]).released = true;
++ (cast(Lock) locks.actor[i]).released = true;
+ }
+ }
+
+
+ public void addBonus(Vector pos, Vector ofs, int num) {
+ for (int i = 0; i < num; i++) {
+- Bonus bonus = (Bonus) bonuses.getInstance();
++ Bonus bonus = cast(Bonus) bonuses.getInstance();
+ if (!bonus)
+ return;
+ bonus.set(pos, ofs);
+@@ -262,11 +285,11 @@
+
+ public void setBossShieldMeter(int bs, int s1, int s2, int s3, int s4, float r) {
+ r *= 0.7;
+- bossShield = bs * r;
+- bossWingShield[0] = s1 * r ;
+- bossWingShield[1] = s2 * r;
+- bossWingShield[2] = s3 * r;
+- bossWingShield[3] = s4 * r;
++ bossShield = cast(int)(bs * r);
++ bossWingShield[0] = cast(int)(s1 * r);
++ bossWingShield[1] = cast(int)(s2 * r);
++ bossWingShield[2] = cast(int)(s3 * r);
++ bossWingShield[3] = cast(int)(s4 * r);
+ }
+
+ // Difficulty.
+@@ -341,7 +364,7 @@
+ rolls.clear();
+ locks.clear();
+ setScreenShake(0, 0);
+- mainLoop.interval = interval = mainLoop.INTERVAL_BASE;
++ mainLoop.interval = cast(int)(interval = mainLoop.INTERVAL_BASE);
+ cnt = 0;
+ if (score > prefManager.hiScore[mode][difficulty][parsecSlot])
+ prefManager.hiScore[mode][difficulty][parsecSlot] = score;
+@@ -396,10 +419,10 @@
+ if (sm > 1.75)
+ sm = 1.75;
+ interval += (sm * mainLoop.INTERVAL_BASE - interval) * 0.1;
+- mainLoop.interval = interval;
++ mainLoop.interval = cast(int)(interval);
+ } else {
+ interval += (mainLoop.INTERVAL_BASE - interval) * 0.08;
+- mainLoop.interval = interval;
++ mainLoop.interval = cast(int)(interval);
+ }
+ }
+ }
+@@ -452,7 +475,7 @@
+ startTitle();
+ } else if (cnt > 500) {
+ startTitle();
+- }
++ }
+ field.move();
+ enemies.move();
+ bullets.move();
+@@ -578,7 +601,7 @@
+ LetterRender.drawNum(Bonus.bonusScore, 24, 20, 12, LetterRender.TO_UP);
+ }
+
+- private void drawLeft() {
++ public void drawLeft() {
+ if (left < 0)
+ return;
+ LetterRender.drawString("LEFT", 520, 260, 25, LetterRender.TO_DOWN);
+diff -Naur p47/src/abagames/p47/P47PrefManager.d p47-gentoo/src/abagames/p47/P47PrefManager.d
+--- p47/src/abagames/p47/P47PrefManager.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/P47PrefManager.d 2007-09-20 08:24:15.000000000 +0200
+@@ -53,6 +53,10 @@
+ auto File fd = new File;
+ try {
+ int ver;
++// if (exists(PREF_FILE) == 0){
++ // init();
++ // save();
++ //}
+ fd.open(PREF_FILE);
+ fd.read(ver);
+ if (ver == PREV_VERSION_NUM) {
+diff -Naur p47/src/abagames/p47/P47Screen.d p47-gentoo/src/abagames/p47/P47Screen.d
+--- p47/src/abagames/p47/P47Screen.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/P47Screen.d 2007-09-20 08:24:15.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.p47.P47Screen;
+
+-private:
++//private:
+ import std.math;
+ import opengl;
+ import abagames.util.Rand;
+@@ -33,7 +33,7 @@
+ glDisable(GL_CULL_FACE);
+ glDisable(GL_DEPTH_TEST);
+ glDisable(GL_TEXTURE_2D);
+- glDisable(GL_COLOR_MATERIAL);
++ glDisable(GL_COLOR_MATERIAL);
+ rand = new Rand;
+ if (luminous > 0) {
+ luminousScreen = new LuminousScreen;
+@@ -128,7 +128,7 @@
+ float ly = std.math.fabs(y2 - y1);
+ glBegin(GL_QUADS);
+ if (lx < ly) {
+- int n = ly / ds;
++ int n = cast(int)(ly / ds);
+ if (n > 0) {
+ float xo = (x2 - x1) / n, xos = 0;
+ float yo;
+@@ -152,7 +152,7 @@
+ }
+ }
+ } else {
+- int n = lx / ds;
++ int n = cast(int)(lx / ds);
+ if (n > 0) {
+ float yo = (y2 - y1) / n, yos = 0;
+ float xo;
+diff -Naur p47/src/abagames/p47/Roll.d p47-gentoo/src/abagames/p47/Roll.d
+--- p47/src/abagames/p47/Roll.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Roll.d 2007-09-20 08:24:15.000000000 +0200
+@@ -40,7 +40,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- RollInitializer ri = (RollInitializer) ini;
++ RollInitializer ri = cast(RollInitializer) ini;
+ ship = ri.ship;
+ field = ri.field;
+ manager = ri.manager;
+diff -Naur p47/src/abagames/p47/Shot.d p47-gentoo/src/abagames/p47/Shot.d
+--- p47/src/abagames/p47/Shot.d 2004-01-01 20:26:42.000000000 +0100
++++ p47-gentoo/src/abagames/p47/Shot.d 2007-09-20 08:24:15.000000000 +0200
+@@ -35,7 +35,7 @@
+ }
+
+ public override void init(ActorInitializer ini) {
+- ShotInitializer si = (ShotInitializer) ini;
++ ShotInitializer si = cast(ShotInitializer) ini;
+ field = si.field;
+ pos = new Vector;
+ vel = new Vector;
+diff -Naur p47/src/abagames/util/Logger.d p47-gentoo/src/abagames/util/Logger.d
+--- p47/src/abagames/util/Logger.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/Logger.d 2007-09-20 08:24:15.000000000 +0200
+@@ -52,26 +52,26 @@
+ public class Logger {
+
+ public static void info(char[] msg) {
+- stderr.writeLine("Info: " ~ msg);
++// stderr.writeLine("Info: " ~ msg);
+ }
+
+ public static void info(int n) {
+- if (n >= 0)
+- stderr.writeLine("Info: " ~ std.string.toString(n));
+- else
+- stderr.writeLine("Info: -" ~ std.string.toString(-n));
++ // if (n >= 0)
++ // stderr.writeLine("Info: " ~ std.string.toString(n));
++// else
++ // stderr.writeLine("Info: -" ~ std.string.toString(-n));
+ }
+
+ public static void error(char[] msg) {
+- stderr.writeLine("Error: " ~ msg);
++ // stderr.writeLine("Error: " ~ msg);
+ }
+
+ public static void error(Exception e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ // stderr.writeLine("Error: " ~ e.toString());
+ }
+
+ public static void error(Error e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ //stderr.writeLine("Error: " ~ e.toString());
+ if (e.next)
+ error(e.next);
+ }
+diff -Naur p47/src/abagames/util/sdl/Input.d p47-gentoo/src/abagames/util/sdl/Input.d
+--- p47/src/abagames/util/sdl/Input.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/sdl/Input.d 2007-09-20 08:24:15.000000000 +0200
+@@ -7,6 +7,29 @@
+
+ private:
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+
+ /**
+ * Input device interface.
+diff -Naur p47/src/abagames/util/sdl/MainLoop.d p47-gentoo/src/abagames/util/sdl/MainLoop.d
+--- p47/src/abagames/util/sdl/MainLoop.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/sdl/MainLoop.d 2007-09-20 08:24:15.000000000 +0200
+@@ -8,6 +8,29 @@
+ private:
+ import std.string;
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import abagames.util.Logger;
+ import abagames.util.Rand;
+ import abagames.util.PrefManager;
+@@ -88,7 +111,7 @@
+ if (event.type == SDL_QUIT)
+ breakLoop();
+ nowTick = SDL_GetTicks();
+- frame = (int) (nowTick-prvTickCount) / interval;
++ frame = cast(int) (nowTick-prvTickCount) / interval;
+ if (frame <= 0) {
+ frame = 1;
+ SDL_Delay(prvTickCount+interval-nowTick);
+diff -Naur p47/src/abagames/util/sdl/Pad.d p47-gentoo/src/abagames/util/sdl/Pad.d
+--- p47/src/abagames/util/sdl/Pad.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/sdl/Pad.d 2007-09-20 08:24:15.000000000 +0200
+@@ -8,6 +8,29 @@
+ private:
+ import std.string;
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import abagames.util.sdl.Input;
+ import abagames.util.sdl.SDLInitFailedException;
+
+diff -Naur p47/src/abagames/util/sdl/Screen3D.d p47-gentoo/src/abagames/util/sdl/Screen3D.d
+--- p47/src/abagames/util/sdl/Screen3D.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/sdl/Screen3D.d 2007-09-20 08:24:15.000000000 +0200
+@@ -8,6 +8,29 @@
+ private:
+ import std.string;
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import opengl;
+ import abagames.util.Logger;
+ import abagames.util.sdl.Screen;
+@@ -47,7 +70,7 @@
+ videoFlags = SDL_OPENGL | SDL_RESIZABLE;
+ } else {
+ videoFlags = SDL_OPENGL | SDL_FULLSCREEN;
+- }
++ }
+ if (SDL_SetVideoMode(width, height, 0, videoFlags) == null) {
+ throw new SDLInitFailedException
+ ("Unable to create SDL screen: " ~ std.string.toString(SDL_GetError()));
+@@ -67,8 +90,8 @@
+ //gluPerspective(45.0f, (GLfloat)width/(GLfloat)height, nearPlane, farPlane);
+ glFrustum(-nearPlane,
+ nearPlane,
+- -nearPlane * (GLfloat)height / (GLfloat)width,
+- nearPlane * (GLfloat)height / (GLfloat)width,
++ -nearPlane * cast(GLfloat)height / cast(GLfloat)width,
++ nearPlane * cast(GLfloat)height / cast(GLfloat)width,
+ 0.1f, farPlane);
+ glMatrixMode(GL_MODELVIEW);
+ }
+diff -Naur p47/src/abagames/util/sdl/Sound.d p47-gentoo/src/abagames/util/sdl/Sound.d
+--- p47/src/abagames/util/sdl/Sound.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/sdl/Sound.d 2007-09-20 08:24:15.000000000 +0200
+@@ -8,6 +8,29 @@
+ private:
+ import std.string;
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import SDL_mixer;
+ import abagames.util.sdl.SDLInitFailedException;
+
+diff -Naur p47/src/abagames/util/sdl/Texture.d p47-gentoo/src/abagames/util/sdl/Texture.d
+--- p47/src/abagames/util/sdl/Texture.d 2004-01-01 20:26:44.000000000 +0100
++++ p47-gentoo/src/abagames/util/sdl/Texture.d 2007-09-20 08:24:15.000000000 +0200
+@@ -9,6 +9,29 @@
+ import std.string;
+ import opengl;
+ import SDL;
++import SDL_active;
++import SDL_joystick;
++import SDL_mutex;
++import SDL_timer;
++import SDL_audio;
++import SDL_endian;
++import SDL_keyboard;
++import SDL_quit;
++import SDL_types;
++import SDL_byteorder;
++import SDL_error;
++import SDL_Keysym;
++import SDL_rwops;
++import SDL_version;
++import SDL_cdrom;
++import SDL_events;
++import SDL_syswm;
++import SDL_Version;
++import SDL_copying;
++import SDL_getenv;
++import SDL_mouse;
++import SDL_thread;
++import SDL_video;
+ import abagames.util.sdl.SDLInitFailedException;
+
+ /**
+diff -Naur p47/src/dirent_d.c p47-gentoo/src/dirent_d.c
+--- p47/src/dirent_d.c 2003-11-29 02:26:30.000000000 +0100
++++ p47-gentoo/src/dirent_d.c 2007-09-20 08:24:15.000000000 +0200
+@@ -1,50 +1,4 @@
+-#ifdef WINDOWS
+
+-#include <windows.h>
+-
+-#include <stdio.h>
+-#include <malloc.h>
+-
+-typedef struct {
+- HANDLE h;
+- char* prev;
+-} DIR;
+-
+-DIR* opendir(char* dir) {
+- WIN32_FIND_DATA fd;
+- HANDLE h;
+- DIR* d;
+- char buf[MAX_PATH];
+-
+- sprintf(buf, "%s/*", dir);
+- h = FindFirstFileA(buf, &fd);
+- d = (DIR*)malloc(sizeof(DIR));
+- d->h = h;
+- d->prev = 0;
+- return d;
+-}
+-
+-char* readdir_filename(DIR* d) {
+- WIN32_FIND_DATA fd;
+- BOOL ret = FindNextFileA(d->h, &fd);
+- if (ret) {
+- if (d->prev != 0) free(d->prev);
+- d->prev = malloc(sizeof(char) * strlen(fd.cFileName));
+- strcpy(d->prev, fd.cFileName);
+- return d->prev;
+- }
+- else {
+- return NULL;
+- }
+-}
+-
+-int closedir(DIR* d) {
+- FindClose(d->h);
+- free(d->prev);
+- free(d);
+-}
+-
+-#else // ! WINDOWS
+
+ #include "dirent.h"
+ #include "unistd.h"
+@@ -55,5 +9,5 @@
+ else return ent->d_name;
+ }
+
+-#endif // WINDOWS
++
+
+diff -Naur p47/src/mt.d p47-gentoo/src/mt.d
+--- p47/src/mt.d 2003-11-29 02:26:30.000000000 +0100
++++ p47-gentoo/src/mt.d 2007-09-20 08:24:15.000000000 +0200
+@@ -162,7 +162,7 @@
+ y ^= (y << 15) & 0xefc60000UL;
+ y ^= (y >> 18);
+
+- return (long)(y>>1);
++ return cast(long)(y>>1);
+ }
+
+ /* generates a random number on [0,1]-real-interval */
+@@ -179,7 +179,7 @@
+ y ^= (y << 15) & 0xefc60000UL;
+ y ^= (y >> 18);
+
+- return (double)y * (1.0/4294967295.0);
++ return cast(double)y * (1.0/4294967295.0);
+ /* divided by 2^32-1 */
+ }
+
+@@ -197,7 +197,7 @@
+ y ^= (y << 15) & 0xefc60000UL;
+ y ^= (y >> 18);
+
+- return (double)y * (1.0/4294967296.0);
++ return cast(double)y * (1.0/4294967296.0);
+ /* divided by 2^32 */
+ }
+
+@@ -215,7 +215,7 @@
+ y ^= (y << 15) & 0xefc60000UL;
+ y ^= (y >> 18);
+
+- return ((double)y + 0.5) * (1.0/4294967296.0);
++ return (cast(double)y + 0.5) * (1.0/4294967296.0);
+ /* divided by 2^32 */
+ }
+
diff --git a/games-action/parsec47/files/parsec47.png b/games-action/parsec47/files/parsec47.png
new file mode 100644
index 0000000..04b3279
--- /dev/null
+++ b/games-action/parsec47/files/parsec47.png
Binary files differ
diff --git a/games-action/parsec47/metadata.xml b/games-action/parsec47/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/parsec47/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/parsec47/parsec47-0.2.ebuild b/games-action/parsec47/parsec47-0.2.ebuild
new file mode 100644
index 0000000..2d46f9c
--- /dev/null
+++ b/games-action/parsec47/parsec47-0.2.ebuild
@@ -0,0 +1,76 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=p47
+MY_PV=${PV//./_}
+
+DESCRIPTION="Defeat retro enemies modenly. Retromodern hispeed shmup, 'PARSEC47'. "
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/p47_e.html"
+SRC_URI="http://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}_${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/Texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/Sound.d \
+ -e 's:"\(morph[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(small[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(smallmove[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(smallsidemove[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(middle[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(middlesub[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(middlemove[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(middlebackmove[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(large[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(largemove[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(morph_lock[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(small_lock[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(middlesub_lock[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/p47/BarrageManager.d \
+ -e 's:"\(p47.prf[^"]*\)":"'${GAMES_STATEDIR}'/\1":g' -i src/abagames/p47/P47PrefManager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r morph small smallmove smallsidemove middle middlesub middlemove \
+ middlebackmove large largemove morph_lock small_lock middlesub_lock \
+ images sounds || die
+
+ if [ ! -e "${GAMES_STATEDIR}"/p47.prf ]
+ then
+ dodir "${GAMES_STATEDIR}"
+ insinto "${GAMES_STATEDIR}"
+ doins "${FILESDIR}"/p47.prf || die
+ fi
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ chmod ug+rw "${GAMES_STATEDIR}"/p47.prf
+}
diff --git a/games-action/projectl/Manifest b/games-action/projectl/Manifest
new file mode 100644
index 0000000..1864e59
--- /dev/null
+++ b/games-action/projectl/Manifest
@@ -0,0 +1,5 @@
+AUX projectl-1.001.diff 10744 RMD160 b3bc270dd1c64e60af32ecdffaa4914e37ee5e01 SHA1 a2ee107e155eaa3e83258f6becd5833aa5c5af2d SHA256 684f8acf990600ebc2bdc36200bfd066711943bc19bc7b0651d0a5ebd409fc67
+AUX projectl.png 3787 RMD160 c5f0d5f472111c28b6bff7ff5688df4a4929eb79 SHA1 38c61bbbb7c29ffde100c4baa0e853b25aed9a4d SHA256 e34cb9fa1ca27b03d7fa3396657196f2881dc7b38f12738316b2d0e6c56f29f4
+DIST projectL_1001.zip 3398282 RMD160 f753c9acb8ab2cfb84823acfbcc5e7bdc9b5c4fe SHA1 72bd88714b1cf5eb5205fd22fb565f3695337a1b SHA256 cfc5ed5a693964ef0296f7d52ee31fe9a0a77a715941b3cff086c2338512a716
+EBUILD projectl-1.001.ebuild 1553 RMD160 0633ae75f37f98a4887ebb2d55b966d0840c2325 SHA1 d43f48702017d0b14526240d7255971bc531a969 SHA256 58d43a5835ba27db3b0805ba4c65930aa5e1eda8836b47b7736769f6b43e0dfe
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/projectl/files/digest-projectl-1.001 b/games-action/projectl/files/digest-projectl-1.001
new file mode 100644
index 0000000..27fc02f
--- /dev/null
+++ b/games-action/projectl/files/digest-projectl-1.001
@@ -0,0 +1,3 @@
+MD5 f810243870f15866db2fb8b3e171ed81 projectL_1001.zip 3398282
+RMD160 f753c9acb8ab2cfb84823acfbcc5e7bdc9b5c4fe projectL_1001.zip 3398282
+SHA256 cfc5ed5a693964ef0296f7d52ee31fe9a0a77a715941b3cff086c2338512a716 projectL_1001.zip 3398282
diff --git a/games-action/projectl/files/projectl-1.001.diff b/games-action/projectl/files/projectl-1.001.diff
new file mode 100644
index 0000000..0e6a272
--- /dev/null
+++ b/games-action/projectl/files/projectl-1.001.diff
@@ -0,0 +1,307 @@
+diff -Naur projectL_1001/import/opengl.d projectL_1001-gentoo/import/opengl.d
+--- projectL_1001/import/opengl.d 2005-03-11 01:43:08.000000000 +0100
++++ projectL_1001-gentoo/import/opengl.d 2007-09-20 08:28:17.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-else {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur projectL_1001/import/openglu.d projectL_1001-gentoo/import/openglu.d
+--- projectL_1001/import/openglu.d 2005-03-11 01:43:20.000000000 +0100
++++ projectL_1001-gentoo/import/openglu.d 2007-09-20 08:28:23.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-else {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur projectL_1001/Makefile projectL_1001-gentoo/Makefile
+--- projectL_1001/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ projectL_1001-gentoo/Makefile 2007-09-20 08:27:46.000000000 +0200
+@@ -0,0 +1,21 @@
++DSRC=$(shell find src -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++CFLAGS=
++DFLAGS=-O -debug -Iimport -Isrc -I/usr/X11R6/include/
++EXE=projectL
++
++
++all: $(EXE)
++
++$(EXE): import/SDL_keysym.d $(OBJS)
++ gcc $(CFLAGS) -o $@ $(OBJS) -lbulletml_d -L/usr/local/lib -L/usr/lib -lgphobos -lpthread -lGLU -lGL -lglut -lm -lstdc++ -lSDL -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ gdmd -d -c -of$@ $(DFLAGS) $<
++
++ clean: rm src/*.o
++ rm src/br/*.o
++ rm src/util/*.o
++ rm src/util/sdl/*.o
++ rm -r import/*.o
+diff -Naur projectL_1001/src/br/boot.d projectL_1001-gentoo/src/br/boot.d
+--- projectL_1001/src/br/boot.d 2006-11-18 20:38:22.000000000 +0100
++++ projectL_1001-gentoo/src/br/boot.d 2007-09-20 08:27:46.000000000 +0200
+@@ -6,8 +6,10 @@
+ private Key key;
+
+
+-private:
+-import std.c.windows.windows;
++version (Win32_release) {
++ // Boot as the Windows executable.
++ private import std.c.windows.windows;
++ private import std.string;
+
+ extern (C) void gc_init();
+ extern (C) void gc_term();
+@@ -37,6 +39,20 @@
+ gc_term();
+ return result;
+ }
++} else {
++ // Boot as the general executable.
++ public int main(char[][] args) {
++ return boot(args);
++ }
++}
++
++public int boot(char[][] args) {
++ double d;
++ key = new Key();
++ mainloop = new Mainloop(key);
++ mainloop.loop();
++ return 0;
++}
+
+ int user_start(){
+ double d;
+diff -Naur projectL_1001/src/br/enemy.d projectL_1001-gentoo/src/br/enemy.d
+--- projectL_1001/src/br/enemy.d 2007-01-28 12:24:14.000000000 +0100
++++ projectL_1001-gentoo/src/br/enemy.d 2007-09-20 08:27:46.000000000 +0200
+@@ -1,5 +1,5 @@
+ module br.enemy;
+-private import str = std.string;
++private import std.string;
+ private import util.parts;
+ private import util.shape;
+ private import util.vector;
+@@ -182,7 +182,7 @@
+ case collisionManager.kind.SWORD:
+
+ double d;
+- d = 1.0;//0.5 + 0.6 * fmin(1.0 ,fmax(0.0 ,(ship.laserSpeed - ship.laserMinSpeed) / (ship.laserMaxSpeed - ship.laserMinSpeed)));
++ d = 0.5 + 0.6 * fmin(1.0 ,fmax(0.0 ,(ship.laserSpeed - ship.laserMinSpeed) / (ship.laserMaxSpeed - ship.laserMinSpeed)));
+ if(vincible){
+ hp = hp - d;//fmax(ceil(hp-1.0) ,hp - d);
+ if(hp <= 0)destroy();
+diff -Naur projectL_1001/src/br/enemyImpl.d projectL_1001-gentoo/src/br/enemyImpl.d
+--- projectL_1001/src/br/enemyImpl.d 2006-12-22 12:56:32.000000000 +0100
++++ projectL_1001-gentoo/src/br/enemyImpl.d 2007-09-20 08:27:46.000000000 +0200
+@@ -1,5 +1,5 @@
+ module br.enemyImpl;
+-private import str = std.string;
++private import std.string;
+ private import util.basis;
+ private import util.parts;
+ private import util.shape;
+@@ -2465,14 +2465,14 @@
+
+
+ for(int i = 0;i < 5;i ++){
+- char[] rw0 = "rWing_"~str.toString(i)~"_"~str.toString(0);
+- char[] rw1 = "rWing_"~str.toString(i)~"_"~str.toString(1);
+- char[] rw2 = "rWing_"~str.toString(i)~"_"~str.toString(2);
+- char[] rw3 = "rWing_"~str.toString(i)~"_"~str.toString(3);
+- char[] lw0 = "lWing_"~str.toString(i)~"_"~str.toString(0);
+- char[] lw1 = "lWing_"~str.toString(i)~"_"~str.toString(1);
+- char[] lw2 = "lWing_"~str.toString(i)~"_"~str.toString(2);
+- char[] lw3 = "lWing_"~str.toString(i)~"_"~str.toString(3);
++ char[] rw0 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(0);
++ char[] rw1 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(1);
++ char[] rw2 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(2);
++ char[] rw3 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(3);
++ char[] lw0 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(0);
++ char[] lw1 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(1);
++ char[] lw2 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(2);
++ char[] lw3 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(3);
+ p = new EnemyAppend(Wing.getShape() ,30 ,-1);//p = new Wing();
+ (cast(Enemy)p).disableBorder();
+ //partsManager.add(append);
+@@ -2510,8 +2510,8 @@
+
+
+ for(int i = 1;i < 4;i ++){
+- char[] t1 = "tail_"~str.toString(i-1);
+- char[] t2 = "tail_"~str.toString(i);
++ char[] t1 = "tail_"~std.string.toString(i-1);
++ char[] t2 = "tail_"~std.string.toString(i);
+ p = new EnemyAppend(Tail.getShape() ,30 ,-1);//p = new Tail();
+ (cast(Enemy)p).disableBorder();
+ childHash[t1].addChild(p ,t2 ,60 ,ENGAGED);
+@@ -4553,12 +4553,12 @@
+
+
+ for(int i = 0;i < 5;i ++){
+- char[] rw0 = "rWing_"~str.toString(i)~"_"~str.toString(0);
+- char[] rw1 = "rWing_"~str.toString(i)~"_"~str.toString(1);
+- char[] rw2 = "rWing_"~str.toString(i)~"_"~str.toString(2);
+- char[] lw0 = "lWing_"~str.toString(i)~"_"~str.toString(0);
+- char[] lw1 = "lWing_"~str.toString(i)~"_"~str.toString(1);
+- char[] lw2 = "lWing_"~str.toString(i)~"_"~str.toString(2);
++ char[] rw0 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(0);
++ char[] rw1 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(1);
++ char[] rw2 = "rWing_"~std.string.toString(i)~"_"~std.string.toString(2);
++ char[] lw0 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(0);
++ char[] lw1 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(1);
++ char[] lw2 = "lWing_"~std.string.toString(i)~"_"~std.string.toString(2);
+ p = new Append(Wing.getShape() ,30);//p = new Wing();
+ //partsManager.add(append);
+ childHash["rWingBase"].addChild(p ,rw0 ,60 ,ENGAGED ,matRotateX(90) * matRotateZ(30 * (i - 2)) * matRotateX(-20) );
+@@ -4580,8 +4580,8 @@
+
+
+ for(int i = 1;i < 5;i ++){
+- char[] t1 = "tail_"~str.toString(i-1);
+- char[] t2 = "tail_"~str.toString(i);
++ char[] t1 = "tail_"~std.string.toString(i-1);
++ char[] t2 = "tail_"~std.string.toString(i);
+ p = new Append(Tail.getShape() ,30);//p = new Tail();
+ childHash[t1].addChild(p ,t2 ,60 ,ENGAGED);
+ //append2 = append;
+diff -Naur projectL_1001/src/br/ship.d projectL_1001-gentoo/src/br/ship.d
+--- projectL_1001/src/br/ship.d 2007-01-28 13:32:58.000000000 +0100
++++ projectL_1001-gentoo/src/br/ship.d 2007-09-20 08:27:46.000000000 +0200
+@@ -2,7 +2,7 @@
+
+ private import SDL_mixer;
+ private import opengl;
+-private import str = std.string;
++private import std.string;
+ private import std.math;
+ private import util.parts;
+ private import util.key;
+@@ -34,7 +34,6 @@
+ int reload;
+ double gradient;
+ int cPressed;
+- double predegAim;
+ // Vector3[100] rpos0;
+ // Matrix[100] rpose0;
+ }
+@@ -85,7 +84,7 @@
+ size = 20;
+ collisionRange = 10;
+ R = 1.0;G =0.88;B = 0.7;alpha = 1.5;
+- predegAim = 0.0;
++
+
+ pressing = 0;
+ reload = 0;
+@@ -209,12 +208,8 @@
+ slow = false;
+ }else slow = true;
+ */
+-// if(pressing > 5)speed = 5.0;
+-// else speed = 8.0;
+- if(sword)speed = 6.8;
+- else speed = 6.8;
+-
+-
++ if(pressing > 5)speed = 5.0;
++ else speed = 8.0;
+ int dir = key.getDirState();
+ int aim = 5;
+ //Vector aim = new Vector(0,0);
+@@ -278,13 +273,12 @@
+ case 9:degAim=-45.0; break;
+ case 5:
+ default:
+- degAim = predegAim;
+ moved = false;
+ break;
+ }
+- predegAim = degAim;
++
+ if(childHash["laserGun"] !is null){
+- (cast(Beam)childHash["laserGun"]).setAim(degAim ,true);//moved);
++ (cast(Beam)childHash["laserGun"]).setAim(degAim ,moved);
+ }
+
+ if(pos.y < screen.GAME_DOWN + size)pos.y = screen.GAME_DOWN + size;
+@@ -369,7 +363,7 @@
+ length = 1000;
+ drawDist = 1;
+ rootLength = 10;
+- minSpeed = 9.0;maxSpeed = 9.0;accSpeed = 1.0;
++ minSpeed = 4.0;maxSpeed = 8.0;accSpeed = 0.4;
+ collisionManager.add(this, collisionManager.kind.LASER ,1 );
+ }
+ public void move(){
+@@ -445,7 +439,7 @@
+ length = 300;
+ drawDist = 1;
+ rootLength = 100;
+- minSpeed = 15.0;maxSpeed = 15.0;accSpeed = 1.0;
++ minSpeed = 5.0;maxSpeed = 20.0;accSpeed = 1.0;
+ collisionManager.add(this, collisionManager.kind.SWORD ,1 );
+ }
+ public void move(){
+@@ -455,7 +449,6 @@
+ }
+ public void setColor(double R ,double G ,double B ,double alpha){}
+ public override void reportCollision(int kind){
+-// speed = fmax(0.0 ,speed - 1.0);
+ //drawing = WIRE;
+
+
+diff -Naur projectL_1001/src/util/ascii.d projectL_1001-gentoo/src/util/ascii.d
+--- projectL_1001/src/util/ascii.d 2006-12-21 23:51:06.000000000 +0100
++++ projectL_1001-gentoo/src/util/ascii.d 2007-09-20 08:27:46.000000000 +0200
+@@ -114,7 +114,7 @@
+ default:break;
+ }
+ foreach(int b;bars){
+- bar[b] = true;
++// bar[b] = true;
+ }
+ drawCrossBar(x ,y+20*scale ,scale ,bar[0]);
+ drawVerticalBar(x-10*scale ,y+10*scale ,scale ,bar[1]);
+@@ -304,4 +304,4 @@
+ glEnd();
+
+ glPopMatrix();
+-}
+\ Kein Zeilenumbruch am Dateiende.
++}
diff --git a/games-action/projectl/files/projectl.png b/games-action/projectl/files/projectl.png
new file mode 100644
index 0000000..09a61fe
--- /dev/null
+++ b/games-action/projectl/files/projectl.png
Binary files differ
diff --git a/games-action/projectl/metadata.xml b/games-action/projectl/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/projectl/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/projectl/projectl-1.001.ebuild b/games-action/projectl/projectl-1.001.ebuild
new file mode 100644
index 0000000..50b5c56
--- /dev/null
+++ b/games-action/projectl/projectl-1.001.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=projectL
+MY_PV=${PV//./}
+
+DESCRIPTION="Sword action STG inspired by projectN developed by D.K"
+HOMEPAGE="http://www.mb.ccnw.ne.jp/hiz/game/projectL/index_en.html"
+SRC_URI="http://www.mb.ccnw.ne.jp/hiz/game/projectL/${MY_PN}_${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}_${MY_PV}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(se/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/gamemanager.d \
+ -e 's:"\(music/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/gamemanager.d \
+ -e 's:"\(se/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/sound.d \
+ -e 's:"\(voice/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/sound.d \
+ -e 's:"\(music/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/sound.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin projectL
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r music se voice || die
+
+ if [ ! -e "${GAMES_STATEDIR}"/${PN}.prf ]
+ then
+ dodir "${GAMES_STATEDIR}"
+ touch ${D}/"${GAMES_STATEDIR}"/${PN}.prf
+ fi
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry projectL ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+ chmod ug+rw "${GAMES_STATEDIR}"/${PN}.prf
+}
diff --git a/games-action/reflectball/Manifest b/games-action/reflectball/Manifest
new file mode 100644
index 0000000..3deb229
--- /dev/null
+++ b/games-action/reflectball/Manifest
@@ -0,0 +1,5 @@
+AUX reflectball-0.11.diff 13207 RMD160 671cdbf4b62a339bde784d3561e6e8cfd26e9831 SHA1 2a1a77c588496fa0a590c57ef412bf7433291006 SHA256 32c3b17f6f3f824e1f2c11b065cdacbd6329c6f5747dd17ce0863dd6eae8cd89
+AUX reflectball.png 1034 RMD160 06622ae3d3d47ac50fa0d4a3e9cd0b8a2ddc9129 SHA1 f48e4ddf1d2ed5bd75faef3fecd2c8e6b079183d SHA256 1c233aedb22c7f133a2a87f26bffc9386a06495f9c289a94fd9d6d9ec5c5c517
+DIST RefLectBall.zip 2958034 RMD160 ba0cee2b7835fdae1d4790502ba7ad4e0ec2e28d SHA1 ff30978621b19c7abeb60526be853eed834c334d SHA256 261c81da6e65ae12234627b9b883b1db6843326893cfcc71574f09fa152099fb
+EBUILD reflectball-0.11.ebuild 1598 RMD160 5dc9bd1a7b930abc476eaa6e384b083ed439861e SHA1 f2eed7ba304a84b39fdf48d2b2a7f650543af64b SHA256 737f4cd46e21501e38e7470bdf5cb9fb32faaa09cddebbfd2e3111004cbf672f
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/reflectball/files/digest-reflectball-0.11 b/games-action/reflectball/files/digest-reflectball-0.11
new file mode 100644
index 0000000..cb0e847
--- /dev/null
+++ b/games-action/reflectball/files/digest-reflectball-0.11
@@ -0,0 +1,3 @@
+MD5 2337fa8aad1cb90f2674a053b2ea71c1 RefLectBall.zip 2958034
+RMD160 ba0cee2b7835fdae1d4790502ba7ad4e0ec2e28d RefLectBall.zip 2958034
+SHA256 261c81da6e65ae12234627b9b883b1db6843326893cfcc71574f09fa152099fb RefLectBall.zip 2958034
diff --git a/games-action/reflectball/files/reflectball-0.11.diff b/games-action/reflectball/files/reflectball-0.11.diff
new file mode 100644
index 0000000..d884bc3
--- /dev/null
+++ b/games-action/reflectball/files/reflectball-0.11.diff
@@ -0,0 +1,405 @@
+diff -Naur RefLectBall/Makefile RefLectBall-gentoo/Makefile
+--- RefLectBall/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ RefLectBall-gentoo/Makefile 2007-10-11 21:35:39.000000000 +0200
+@@ -0,0 +1,17 @@
++DC=gdmd
++DFLAGS=-g -O -d -release -Iimport -Isrc
++DOUT=-of
++
++DSRC=$(shell find src/ -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d import/SDL_image.d
++OBJS=$(SOURCES:.d=.o)
++EXE=reflectball
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
+diff -Naur RefLectBall/import/SDL.d RefLectBall-gentoo/import/SDL.d
+--- RefLectBall/import/SDL.d 2006-07-26 16:24:12.000000000 +0200
++++ RefLectBall-gentoo/import/SDL.d 2007-10-11 21:35:39.000000000 +0200
+@@ -31,7 +31,7 @@
+ public import SDL_events;
+ public import SDL_video;
+ public import SDL_byteorder;
+-public import SDL_Version;
++public import SDL_version;
+
+ extern(C):
+
+@@ -73,6 +73,7 @@
+ */
+ void SDL_Quit();
+
++/+
+ void SDL_SetModuleHandle(void *hInst);
+ //extern(Windows) void* GetModuleHandle(char*);
+ extern(Windows) void* GetModuleHandleA(char*);
+@@ -90,3 +91,4 @@
+ {
+ SDL_Quit();
+ }
+++/
+diff -Naur RefLectBall/import/SDL_events.d RefLectBall-gentoo/import/SDL_events.d
+--- RefLectBall/import/SDL_events.d 2006-07-26 16:25:46.000000000 +0200
++++ RefLectBall-gentoo/import/SDL_events.d 2007-10-11 21:35:39.000000000 +0200
+@@ -105,7 +105,7 @@
+ Uint8 type; /* SDL_KEYDOWN or SDL_KEYUP */
+ Uint8 which; /* The keyboard device index */
+ Uint8 state; /* SDL_PRESSED or SDL_RELEASED */
+- SDL_keysym keysym;
++ SDL_keysym2 keysym;
+ }
+
+ /* Mouse motion event structure */
+diff -Naur RefLectBall/import/SDL_keyboard.d RefLectBall-gentoo/import/SDL_keyboard.d
+--- RefLectBall/import/SDL_keyboard.d 2006-07-26 16:25:14.000000000 +0200
++++ RefLectBall-gentoo/import/SDL_keyboard.d 2007-10-11 21:35:39.000000000 +0200
+@@ -26,7 +26,7 @@
+ // !!! A hack! struct SDL_keysym is defined in this module,
+ // !!! so we need to resolve the nameclash...
+ // !!! Definitely won't work on *NIX but for now will do.
+-public import SDL_Keysym;
++public import SDL_keysym;
+
+ extern(C):
+
+@@ -46,7 +46,7 @@
+ An international character..
+ }
+ */
+-struct SDL_keysym {
++struct SDL_keysym2 {
+ Uint8 scancode; /* hardware specific scancode */
+ SDLKey sym; /* SDL virtual keysym */
+ SDLMod mod; /* current key modifiers */
+diff -Naur RefLectBall/import/SDL_syswm.d RefLectBall-gentoo/import/SDL_syswm.d
+--- RefLectBall/import/SDL_syswm.d 2006-07-26 16:25:32.000000000 +0200
++++ RefLectBall-gentoo/import/SDL_syswm.d 2007-10-11 21:35:39.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-public import SDL_Version;
++public import SDL_version;
+
+ extern(C):
+
+diff -Naur RefLectBall/import/opengl.d RefLectBall-gentoo/import/opengl.d
+--- RefLectBall/import/opengl.d 2004-01-09 10:52:04.000000000 +0100
++++ RefLectBall-gentoo/import/opengl.d 2007-10-11 21:35:39.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur RefLectBall/import/openglu.d RefLectBall-gentoo/import/openglu.d
+--- RefLectBall/import/openglu.d 2006-07-26 16:24:24.000000000 +0200
++++ RefLectBall-gentoo/import/openglu.d 2007-10-11 21:35:39.000000000 +0200
+@@ -1,11 +1,6 @@
+ public import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur RefLectBall/src/bulletcommand.d RefLectBall-gentoo/src/bulletcommand.d
+--- RefLectBall/src/bulletcommand.d 2006-10-24 19:55:56.000000000 +0200
++++ RefLectBall-gentoo/src/bulletcommand.d 2007-10-11 21:35:39.000000000 +0200
+@@ -36,7 +36,7 @@
+
+ buf.length = 256;
+ buf = fname ~ "\0";
+- parser[bank] = BulletMLParserTinyXML_new(buf);
++ parser[bank] = BulletMLParserTinyXML_new(buf.ptr);
+ if(parser[bank]) BulletMLParserTinyXML_parse(parser[bank]);
+ buf.length = 0;
+ }
+@@ -169,7 +169,8 @@
+ if(eid != -1){
+ TskBuf[eid].parent = BulletCommand.now.id;
+ d = (d <= 180.0f ? d : -(360.0f - d));
+- d = d / ROTVAL;
++ d = d / ROTVAL;
++ TskBuf[eid].roll = 0;
+ TskBuf[eid].bullet_speed = s;
+ TskBuf[eid].bullet_direction = d;
+ TskBuf[eid].bullet_velx = (sin(d) * (-s * VEL_SDM_SS_RATIO));
+diff -Naur RefLectBall/src/gctrl.d RefLectBall-gentoo/src/gctrl.d
+--- RefLectBall/src/gctrl.d 2006-10-25 18:56:44.000000000 +0200
++++ RefLectBall-gentoo/src/gctrl.d 2007-10-13 10:20:40.000000000 +0200
+@@ -66,6 +66,22 @@
+ GCTRL_RANKING_EXEC,
+ GCTRL_RANKING_EXIT,
+ }
++
++public static char[] pref_dir()
++{
++ char * home = getenv("HOME");
++ if (home is null)
++ throw new Error("HOME environment variable not defined");
++ char[] dir = std.string.toString(home) ~ "/.reflectball";
++ char[] dir2 = std.string.toString(home) ~ "/.reflectball/replay";
++ try {
++ mkdir(dir);
++ mkdir(dir2);
++ } catch (FileException e) {
++ }
++ return dir;
++}
++
+
+ void TSKgctrl(int id)
+ {
+@@ -78,7 +94,7 @@
+ replay_data.length = 8;
+ }
+ replay_fmax = 0;
+- fpath = listdir(std.path.curdir ~ "/replay");
++ fpath = listdir(pref_dir() ~ "/" ~ "replay");
+ for(int i = 0; i < fpath.length; i++){
+ if(fnmatch(fpath[i], "rlb??????????????.rep")){
+ replay_file.length = fcnt + 1;
+@@ -118,7 +134,7 @@
+ replay_data[i] = replay[i];
+ }
+ char[] fname;
+- fname = format("./replay/rlb%04d%02d%02d%02d%02d%02d.rep"
++ fname = format(pref_dir() ~ "/" ~ "/replay/rlb%04d%02d%02d%02d%02d%02d.rep"
+ ,year
+ ,month
+ ,date
+@@ -152,8 +168,8 @@
+ }
+
+ void init_highscore(){
+- if(exists("score.dat")){
+- hi_score = cast(int[])read("score.dat");
++ if(exists(pref_dir() ~ "/" ~ "score.dat")){
++ hi_score = cast(int[])read(pref_dir() ~ "/" ~ "score.dat");
+ }else{
+ hi_score.length = RANKING_MAX * RANKING_RECORD;
+ for(int i = 0; i < RANKING_MAX; i++){
+@@ -161,7 +177,7 @@
+ hi_score[i * RANKING_RECORD + RANKING_BREAK] = 0;
+ hi_score[i * RANKING_RECORD + RANKING_DESTR] = 0;
+ }
+- write("score.dat", cast(void[])hi_score);
++ write(pref_dir() ~ "/" ~ "score.dat", cast(void[])hi_score);
+ }
+ }
+
+@@ -178,7 +194,7 @@
+ hi_score[i * RANKING_RECORD + RANKING_SCORE] = score;
+ hi_score[i * RANKING_RECORD + RANKING_BREAK] = brk_ship;
+ hi_score[i * RANKING_RECORD + RANKING_DESTR] = enemy_dst;
+- write("score.dat", cast(void[])hi_score);
++ write(pref_dir() ~ "/" ~ "score.dat", cast(void[])hi_score);
+ break;
+ }
+ }
+diff -Naur RefLectBall/src/luminous.d RefLectBall-gentoo/src/luminous.d
+--- RefLectBall/src/luminous.d 2006-07-08 04:49:12.000000000 +0200
++++ RefLectBall-gentoo/src/luminous.d 2007-10-11 21:35:39.000000000 +0200
+@@ -7,7 +7,7 @@
+ */
+
+ private import std.math;
+-private import std.string;
++private import std.c.string;
+ private import opengl;
+ private import util_sdl;
+ private import task;
+@@ -36,7 +36,7 @@
+ glDisable(GL_CULL_FACE);
+ glDisable(GL_DEPTH_TEST);
+ glDisable(GL_TEXTURE_2D);
+- glDisable(GL_COLOR_MATERIAL);
++ glDisable(GL_COLOR_MATERIAL);
+ init(0.0f, SCREEN_X, SCREEN_Y);
+ TskBuf[id].fp_draw = &TSKluminousDraw;
+ TskBuf[id].step++;
+@@ -68,11 +68,11 @@
+
+ static void makeLuminousTexture()
+ {
+- uint *data = td;
++ uint *data = td.ptr;
+ int i;
+
+ td[0..length] = 0;
+- //memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
++ memset(data, 0, luminousTextureWidth * luminousTextureHeight * 4 * uint.sizeof);
+ glGenTextures(1, &luminousTexture);
+ glBindTexture(GL_TEXTURE_2D, luminousTexture);
+ glTexImage2D(GL_TEXTURE_2D, 0, 4, luminousTextureWidth, luminousTextureHeight, 0, GL_RGBA, GL_UNSIGNED_BYTE, data);
+diff -Naur RefLectBall/src/main.d RefLectBall-gentoo/src/main.d
+--- RefLectBall/src/main.d 2006-10-20 20:10:16.000000000 +0200
++++ RefLectBall-gentoo/src/main.d 2007-10-11 21:35:39.000000000 +0200
+@@ -4,14 +4,14 @@
+ 'main.d'
+ */
+
+-private import std.c.windows.windows;
++//private import std.c.windows.windows;
+ private import std.stdio;
+ private import std.string;
+ private import std.random;
+ private import std.math;
+ private import SDL;
+ private import opengl;
+-private import reflection;
++//private import reflection;
+ private import util_sdl;
+ private import util_glbf;
+ private import util_pad;
+@@ -65,8 +65,8 @@
+ str_buf[i] = lpCmdLine[i];
+ }
+ split_buf = split(str_buf);
+- if(split_buf[0].length > 1) Reflection.init(split_buf[0]);
+- else Reflection.init("main.exe");
++ // if(split_buf[0].length > 1) Reflection.init(split_buf[0]);
++ // else Reflection.init("main.exe");
+ }
+
+ try{
+@@ -84,7 +84,7 @@
+ }else{
+ int main(char[][] argv)
+ {
+- Reflection.init(argv[argv.length-1]);
++ // Reflection.init(argv[argv.length-1]);
+ return boot();
+ }
+ }
+diff -Naur RefLectBall/src/task.d RefLectBall-gentoo/src/task.d
+--- RefLectBall/src/task.d 2006-10-20 20:08:50.000000000 +0200
++++ RefLectBall-gentoo/src/task.d 2007-10-11 21:35:39.000000000 +0200
+@@ -175,7 +175,9 @@
+ TskBuf[i].fp_draw = null;
+ TskBuf[i].fp_exit = null;
+ TskBuf[i].bullet_command = null;
+- TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_accx = 0;
++ TskBuf[i].bullet_accy = 0;
+ }
+ TskBuf[i].tskid = TSKID_NONE;
+ TskBuf[i].entry = -1;
+@@ -186,7 +188,7 @@
+ TskBuf[i].fp_draw = null;
+ TskBuf[i].fp_exit = null;
+ TskBuf[i].bullet_command = null;
+- TskBuf[i].bullet_state = null;
++ TskBuf[i].bullet_state = null;
+ }
+
+ int setTSK(int group,void function(int) func)
+diff -Naur RefLectBall/src/util_glbf.d RefLectBall-gentoo/src/util_glbf.d
+--- RefLectBall/src/util_glbf.d 2006-07-07 17:37:52.000000000 +0200
++++ RefLectBall-gentoo/src/util_glbf.d 2007-10-11 21:35:39.000000000 +0200
+@@ -156,7 +156,7 @@
+ {
+ glBindTexture(GL_TEXTURE_2D, font.texture); // Select Our Font Texture
+ glListBase(font.base-32); // Choose The Font Set (0 or 1)
+- glCallLists(str.length, GL_BYTE, str); // Write The Text To The Screen
++ glCallLists(str.length, GL_BYTE, str.ptr); // Write The Text To The Screen
+ }
+
+ int glbfInit(GLBitmapFont* font, char* filename, GLfloat xsize, GLfloat xdots, GLfloat ydots)
+diff -Naur RefLectBall/src/util_rand.d RefLectBall-gentoo/src/util_rand.d
+--- RefLectBall/src/util_rand.d 2006-07-26 16:50:10.000000000 +0200
++++ RefLectBall-gentoo/src/util_rand.d 2007-10-11 21:35:39.000000000 +0200
+@@ -112,14 +112,14 @@
+
+ void next_state()
+ {
+- uint *p=state;
++ uint *p=state.ptr;
+
+ /* if init_genrand() has not been called, */
+ /* a default initial seed is used */
+ if (initf==0) init_genrand(5489);
+
+ left = N;
+- next = state;
++ next = state.ptr;
+
+ for (int j=N-M+1; --j; p++)
+ *p = p[M] ^ TWIST(p[0], p[1]);
+diff -Naur RefLectBall/src/util_sdl.d RefLectBall-gentoo/src/util_sdl.d
+--- RefLectBall/src/util_sdl.d 2006-10-19 19:04:16.000000000 +0200
++++ RefLectBall-gentoo/src/util_sdl.d 2007-10-11 21:35:39.000000000 +0200
+@@ -105,7 +105,7 @@
+ resizedSDL(width, height);
+ SDL_ShowCursor(SDL_DISABLE);
+
+- SDL_WM_SetCaption(PROJECT_NAME, null);
++ SDL_WM_SetCaption(PROJECT_NAME.ptr, null);
+ SDL_WM_SetIcon(SDL_LoadBMP("icon.bmp"), null);
+
+ return 1;
+@@ -142,7 +142,7 @@
+ {
+ SDL_Surface* tmp;
+
+- tmp = IMG_Load(toStringz(fname));
++// tmp = IMG_Load(toStringz(fname));
+ if(tmp){
+ SDL_Surface* tmp2;
+ int bpp = getBPP(tmp);
+diff -Naur RefLectBall/src/util_snd.d RefLectBall-gentoo/src/util_snd.d
+--- RefLectBall/src/util_snd.d 2006-10-22 21:07:36.000000000 +0200
++++ RefLectBall-gentoo/src/util_snd.d 2007-10-11 21:35:39.000000000 +0200
+@@ -99,7 +99,7 @@
+
+ char[] fileName = name ~ "\0";
+
+- music[ch] = Mix_LoadMUS(fileName);
++ music[ch] = Mix_LoadMUS(fileName.ptr);
+ if(!music[ch]){
+ writefln("snd load error %s", name);
+ sound_use = false;
+@@ -119,7 +119,7 @@
+
+ char[] fileName = name ~ "\0";
+
+- chunk[bank] = Mix_LoadWAV(fileName);
++ chunk[bank] = Mix_LoadWAV(fileName.ptr);
+ if(!chunk[bank]){
+ sound_use = false;
+ }
diff --git a/games-action/reflectball/files/reflectball.png b/games-action/reflectball/files/reflectball.png
new file mode 100644
index 0000000..2b38eae
--- /dev/null
+++ b/games-action/reflectball/files/reflectball.png
Binary files differ
diff --git a/games-action/reflectball/metadata.xml b/games-action/reflectball/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/reflectball/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/reflectball/reflectball-0.11.ebuild b/games-action/reflectball/reflectball-0.11.ebuild
new file mode 100644
index 0000000..e3c27ca
--- /dev/null
+++ b/games-action/reflectball/reflectball-0.11.ebuild
@@ -0,0 +1,58 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=RefLectBall
+MY_PV=${PV//./_}
+
+DESCRIPTION="jumpei isshiki's HelloWorldProject (2006/09/09) "
+HOMEPAGE="http://homepage2.nifty.com/isshiki/prog_win_d.html"
+SRC_URI="http://isshiki.la.coocan.jp/game/${MY_PN}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ mv src/reflection.d src/reflection.d-OFF
+ sed -i \
+ -e 's:"\(title.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(next.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(gameover.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(edificio.bmp[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/main.d \
+ -e 's:"\(ref-ball[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(voice_[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(zlock[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ -e 's:"\(bullets[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/init.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r bullets *.bmp *.ogg *.wav || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/supertirititran/Manifest b/games-action/supertirititran/Manifest
new file mode 100644
index 0000000..30ffc62
--- /dev/null
+++ b/games-action/supertirititran/Manifest
@@ -0,0 +1,5 @@
+AUX 0.9-gentoopath.diff 940 RMD160 585e47da0a8b6b75db74f0bd6249e525ca3106d9 SHA1 062e411bf083e724c99e0229eb47261105790fd7 SHA256 85305b576430a22e80f071db9efe4ddfdba65eb8daf29c464231e2a51204a0b6
+AUX supertirititran.png 5767 RMD160 063d6d5b2357d6d5c1afcbea9dffd3a334471898 SHA1 d431a423ee200f11ad85b7e60b7e8982095c1372 SHA256 be523a9fb217d7c6b57e99e9b3dcb5956bd89cdd9e903d8c542eb097b5e69330
+DIST supertirititran-09-linux-sources.tar.gz 34338560 RMD160 0746474849716286451ac7af1deb2e2b5e7cc7c0 SHA1 86d0cec3aceaba8389ab55bba2c130e0374eec8b SHA256 f76c00390046ef7e797a16b8c9ad0e761277365561be834546121ad887b2fb6c
+EBUILD supertirititran-0.9.ebuild 845 RMD160 102eeb8d8701a75a0ee52939e1d3ede05f93dfe9 SHA1 93e2d5cb81fdf5fd55698c48fd2f2799198ad93b SHA256 d1360492eb8adaa200315fae13d6b9e045693eadc232847f0139de2532a31f16
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/supertirititran/files/0.9-gentoopath.diff b/games-action/supertirititran/files/0.9-gentoopath.diff
new file mode 100644
index 0000000..336ca99
--- /dev/null
+++ b/games-action/supertirititran/files/0.9-gentoopath.diff
@@ -0,0 +1,24 @@
+diff -Naur org/Makefile patch/Makefile
+--- org/Makefile 2006-09-05 14:53:11.000000000 +0200
++++ patch/Makefile 2009-08-20 10:47:22.000000000 +0200
+@@ -27,7 +27,7 @@
+ # OBJETIVOS
+ #---------------------------
+
+-NAME_EXE= tirititran
++NAME_EXE= supertirititran
+ PROGRAMA = $(SRCDIR)/tirititran.cpp
+
+ DEP = SDL_rotozoom.o barra.o cargar.o configuracion.o disparojugador.o disparosenemigos.o elementos.o explosion.o fuente.o intercom.o joystick.o juego.o mapa.o niveles.o opciones.o pantalla.o SDL_Animation.o sonido.o tiempo.o unrarlib.o tirititran.o
+diff -Naur org/src/defines.h patch/src/defines.h
+--- org/src/defines.h 2006-09-17 19:05:07.000000000 +0200
++++ patch/src/defines.h 2009-08-20 10:47:32.000000000 +0200
+@@ -30,7 +30,7 @@
+ #ifndef DEFINES_H_
+ #define DEFINES_H_
+
+-#define DATA_DIR "/usr/share/tirititran/data"
++#define DATA_DIR "/usr/share/games/supertirititran/data"
+
+ #define NOPCIONES 8
+ #define NOPCIONES_OPCIONES 8
diff --git a/games-action/supertirititran/files/supertirititran.png b/games-action/supertirititran/files/supertirititran.png
new file mode 100644
index 0000000..e046f08
--- /dev/null
+++ b/games-action/supertirititran/files/supertirititran.png
Binary files differ
diff --git a/games-action/supertirititran/metadata.xml b/games-action/supertirititran/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/supertirititran/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/supertirititran/supertirititran-0.9.ebuild b/games-action/supertirititran/supertirititran-0.9.ebuild
new file mode 100644
index 0000000..cf7bb0d
--- /dev/null
+++ b/games-action/supertirititran/supertirititran-0.9.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit eutils games
+
+DESCRIPTION="super hero shoot em up"
+HOMEPAGE="http://www.super-tirititran.com"
+SRC_URI="mirror://sourceforge/${PN}/${PN}-09-linux-sources.tar.gz"
+LICENSE="CCPL-Attribution-NonCommercial-NoDerivs-2.0"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+DEPEND="media-libs/libsdl
+ media-libs/sdl-image
+ media-libs/sdl-mixer
+ media-libs/sdl-ttf
+ dev-libs/expat"
+RDEPEND=""
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PV}-gentoopath.diff || die "patch failed"
+}
+
+src_install() {
+ dogamesbin supertirititran
+ dodoc README
+ insinto "${GAMES_DATADIR}"/"${PN}"
+ doins -r data || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/tatan/Manifest b/games-action/tatan/Manifest
new file mode 100644
index 0000000..99675cf
--- /dev/null
+++ b/games-action/tatan/Manifest
@@ -0,0 +1,5 @@
+AUX tatan-1.0.diff 3553 RMD160 9dfd1127a13f4a0047511884b0c3a6f036cf6364 SHA1 694552a25ed82bb67236f8f8069730ec5243f8d7 SHA256 dece075e19e842838e0013aefa8e896b03a0cdec03c1161ab78c6b69cf9c874a
+AUX tatan.png 2241 RMD160 ecb3b09a29cb5bda54ab0cfa6f6a91b6ab9c89f2 SHA1 0c66f2035477207a783e94a98ebd0a7499ec30f1 SHA256 1a5d661ebf8137a63c86e59ad1126421499b280087029be078f2731f5c6ac0fb
+DIST tatan.zip 2343296 RMD160 010f8c22e23d16838defe1a6a040e733f20ebf5f SHA1 2872e396344c1d18a5083733c872d13775204b36 SHA256 59ffd457ce67c3c75c01eb74aa330bd729c741607b5437b351fb5faab532de9f
+EBUILD tatan-1.0.ebuild 1500 RMD160 1129256d35e2cc8aea538a8e9a2135e78d12edc0 SHA1 50a2ec6b3e7ac72bdb3c3d7af43ed5b73215791c SHA256 c4a82bc627cd9fb3032f211810c2c97efe47ea2142e2dbd04f65eb0f6cb864ab
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/tatan/files/digest-tatan-1.0 b/games-action/tatan/files/digest-tatan-1.0
new file mode 100644
index 0000000..ca8b582
--- /dev/null
+++ b/games-action/tatan/files/digest-tatan-1.0
@@ -0,0 +1,3 @@
+MD5 2c676c5b64c5ade64e57744d459e050a tatan.zip 2343296
+RMD160 010f8c22e23d16838defe1a6a040e733f20ebf5f tatan.zip 2343296
+SHA256 59ffd457ce67c3c75c01eb74aa330bd729c741607b5437b351fb5faab532de9f tatan.zip 2343296
diff --git a/games-action/tatan/files/tatan-1.0.diff b/games-action/tatan/files/tatan-1.0.diff
new file mode 100644
index 0000000..8899c06
--- /dev/null
+++ b/games-action/tatan/files/tatan-1.0.diff
@@ -0,0 +1,123 @@
+diff -Naur tatan/import/opengl.d tatan-gentoo/import/opengl.d
+--- tatan/import/opengl.d 2007-07-28 16:01:16.000000000 +0200
++++ tatan-gentoo/import/opengl.d 2007-09-20 08:30:48.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-//void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-//void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur tatan/import/openglu.d tatan-gentoo/import/openglu.d
+--- tatan/import/openglu.d 2007-07-28 15:26:24.000000000 +0200
++++ tatan-gentoo/import/openglu.d 2007-09-20 08:30:55.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur tatan/Makefile tatan-gentoo/Makefile
+--- tatan/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ tatan-gentoo/Makefile 2007-09-20 08:30:00.000000000 +0200
+@@ -0,0 +1,17 @@
++DC=gdmd
++DFLAGS=-g -O -d -release -Iimport -Isrc
++DOUT=-of
++
++DSRC=$(shell find src/ -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mouse.d import/hell2.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=tatan
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
+diff -Naur tatan/src/br/boot.d tatan-gentoo/src/br/boot.d
+--- tatan/src/br/boot.d 2007-07-28 16:09:10.000000000 +0200
++++ tatan-gentoo/src/br/boot.d 2007-09-20 08:30:00.000000000 +0200
+@@ -6,6 +6,8 @@
+ private Mainloop mainloop;
+ private Key key;
+ private Mouse mouse;
++
++version (Win32_release) {
+
+ private:
+ import std.c.windows.windows;
+@@ -37,7 +39,22 @@
+ }
+ gc_term();
+ return result;
++}
++} else {
++ // Boot as the general executable.
++ public int main(char[][] args) {
++ return boot(args);
++ }
+ }
++
++public int boot(char[][] args) {
++ double d;
++ key = new Key();
++ mouse = new Mouse();
++ mainloop = new Mainloop(key ,mouse);
++ mainloop.loop();
++ return 0;
++}
+
+ int user_start(){
+ double d;
+diff -Naur tatan/src/util/ascii.d tatan-gentoo/src/util/ascii.d
+--- tatan/src/util/ascii.d 2007-07-29 21:57:04.000000000 +0200
++++ tatan-gentoo/src/util/ascii.d 2007-09-20 08:30:00.000000000 +0200
+@@ -116,7 +116,7 @@
+ default:break;
+ }
+ foreach(int b;bars){
+- bar[b] = true;
++ // bar[b] = true;
+ }
+ drawCrossBar(x ,y+20*scale ,scale ,bar[0]);
+ drawVerticalBar(x-10*scale ,y+10*scale ,scale ,bar[1]);
+@@ -333,4 +333,5 @@
+
+ glPopMatrix();
+ }
+-}
+\ Kein Zeilenumbruch am Dateiende.
++}
++
diff --git a/games-action/tatan/files/tatan.png b/games-action/tatan/files/tatan.png
new file mode 100644
index 0000000..71d9418
--- /dev/null
+++ b/games-action/tatan/files/tatan.png
Binary files differ
diff --git a/games-action/tatan/metadata.xml b/games-action/tatan/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/tatan/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/tatan/tatan-1.0.ebuild b/games-action/tatan/tatan-1.0.ebuild
new file mode 100644
index 0000000..3d577aa
--- /dev/null
+++ b/games-action/tatan/tatan-1.0.ebuild
@@ -0,0 +1,57 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=tatan
+MY_PV=${PV//./_}
+
+DESCRIPTION="pointing STG by HIZ "
+HOMEPAGE="http://http://hizuoka.web.fc2.com/game/tatan/index_en.html"
+SRC_URI="http://hizuoka.web.fc2.com/game/tatan/${MY_PN}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(resource/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i import/hell2.d \
+ -e 's:"\(image/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/gamemanager.d \
+ -e 's:"\(image/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/screen.d \
+ -e 's:"\(se/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/sound.d \
+ -e 's:"\(voice/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/sound.d \
+ -e 's:"\(music/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/br/sound.d \
+ -e 's:"\(screenshot.bmp[^"]*\)":"'${GAMES_STATEDIR}'/\1":g' -i src/br/screen.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r image music voice resource se || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/titanion/Manifest b/games-action/titanion/Manifest
new file mode 100644
index 0000000..d1b3e44
--- /dev/null
+++ b/games-action/titanion/Manifest
@@ -0,0 +1,5 @@
+AUX titanion-0.3.diff 15721 RMD160 2f871db473a5167692a786111f231d4786d702f2 SHA1 a00ad3cd861f46bb7c5ccbd534701619c9cfbed3 SHA256 45d47250658c635001d188c6fcf37199dc4d827c33d4d1f54c7752a05f58a081
+AUX titanion.png 2741 RMD160 422b7b35a3d71be171db719fd07a3d128ad249c0 SHA1 35dffb15d79e9f07eddda2dd9a6ca3bef4bfb1f8 SHA256 6e52cf0a3fafa870f8d23988e7883bd5f03407f9a9032c5a44ac5191c4bb4ad4
+DIST ttn0_3.zip 5551368 RMD160 fb4913eb2aa6f8cf068c366a5a9e29987b516d60 SHA1 02390f59eda413ba5848343c605040394f357f74 SHA256 7d1d1cb9f8ba754f3df303fc28697fbf16df409ccc98cc65619dd03462da8df3
+EBUILD titanion-0.3.ebuild 1621 RMD160 8d7b2fae617c92c3c9198e0d65ac4bac23f17634 SHA1 3112659b7131581264c69347c845994749e4e404 SHA256 a9d23d554897c85405897eadeb3dc3c2e0b2fb4caf218e90f7095785a2945792
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/titanion/files/digest-titanion-0.3 b/games-action/titanion/files/digest-titanion-0.3
new file mode 100644
index 0000000..f79460c
--- /dev/null
+++ b/games-action/titanion/files/digest-titanion-0.3
@@ -0,0 +1,3 @@
+MD5 33044d2542f93753b5aa1611fbf22e69 ttn0_3.zip 5551368
+RMD160 fb4913eb2aa6f8cf068c366a5a9e29987b516d60 ttn0_3.zip 5551368
+SHA256 7d1d1cb9f8ba754f3df303fc28697fbf16df409ccc98cc65619dd03462da8df3 ttn0_3.zip 5551368
diff --git a/games-action/titanion/files/titanion-0.3.diff b/games-action/titanion/files/titanion-0.3.diff
new file mode 100644
index 0000000..416784a
--- /dev/null
+++ b/games-action/titanion/files/titanion-0.3.diff
@@ -0,0 +1,616 @@
+diff -Naur ttn/import/opengl.d ttn-gentoo/import/opengl.d
+--- ttn/import/opengl.d 2006-11-19 08:54:54.000000000 +0100
++++ ttn-gentoo/import/opengl.d 2007-09-20 08:33:36.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur ttn/import/openglu.d ttn-gentoo/import/openglu.d
+--- ttn/import/openglu.d 2006-11-19 08:54:54.000000000 +0100
++++ ttn-gentoo/import/openglu.d 2007-09-20 08:33:43.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur ttn/Makefile ttn-gentoo/Makefile
+--- ttn/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ ttn-gentoo/Makefile 2007-09-20 08:33:10.000000000 +0200
+@@ -0,0 +1,30 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-O -release -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -frelease -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/abagames -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=titanion
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS):
++ $(DC) -c -op $(DFLAGS) $(SOURCES)
++
++#$(OBJS): %.o: %.d
++# $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
++clean:
++ rm -f $(OBJS) $(EXE)
+diff -Naur ttn/src/abagames/ttn/bullet.d ttn-gentoo/src/abagames/ttn/bullet.d
+--- ttn/src/abagames/ttn/bullet.d 2006-12-04 17:04:26.000000000 +0100
++++ ttn-gentoo/src/abagames/ttn/bullet.d 2007-09-20 08:33:10.000000000 +0200
+@@ -59,7 +59,54 @@
+ }
+ }
+
+-public class Bullet: Token!(BulletState, BulletSpec) {
++public class Token2(ST, SP): Actor {
++ protected:
++ ST state;
++ SP spec;
++
++ public void init(Object[] args) {
++ state = new ST;
++ }
++
++ public void set(SP spec, Vector pos, float deg, float speed) {
++ set(spec, pos.x, pos.y, deg, speed);
++ }
++
++ public void set(SP spec, float x, float y, float deg, float speed) {
++ this.spec = spec;
++ set(x, y, deg, speed);
++ }
++
++ public void set(float x, float y, float deg, float speed) {
++ state.clear();
++ state.pos.x = x;
++ state.pos.y = y;
++ state.deg = deg;
++ state.speed = speed;
++ spec.set(state);
++ _exists = true;
++ }
++
++ public void move() {
++ if (!spec.move(state))
++ remove();
++ }
++
++ public void remove() {
++ _exists = false;
++ spec.removed(state);
++ }
++
++ public void draw() {
++ spec.draw(state);
++ }
++
++ public Vector pos() {
++ return state.pos;
++ }
++}
++
++public class Bullet: Token2!(BulletState, BulletSpec) {
+ private:
+
+ public void setWaitCnt(int c) {
+@@ -102,7 +149,28 @@
+ }
+ }
+
+-public class BulletSpec: TokenSpec!(BulletState) {
++public class TokenSpec2(T) {
++ protected:
++ Field field;
++ Shape shape;
++
++ public void set(T state) {}
++ public void removed(T state) {}
++
++ public bool move(T state) {
++ return true;
++ }
++
++ public void draw(T state) {
++ with (state) {
++ Vector3 p = field.calcCircularPos(pos);
++ float cd = field.calcCircularDeg(pos.x);
++ shape.draw(p, cd, deg);
++ }
++ }
++}
++
++public class BulletSpec: TokenSpec2!(BulletState) {
+ private:
+ static const float DISAPPEAR_CNT = 300;
+ Player player;
+diff -Naur ttn/src/abagames/ttn/enemy.d ttn-gentoo/src/abagames/ttn/enemy.d
+--- ttn/src/abagames/ttn/enemy.d 2006-12-09 05:17:40.000000000 +0100
++++ ttn-gentoo/src/abagames/ttn/enemy.d 2007-09-20 08:33:10.000000000 +0200
+@@ -188,7 +188,54 @@
+ }
+ }
+
+-public class Enemy: Token!(EnemyState, EnemySpec) {
++public class Token2(ST, SP): Actor {
++ protected:
++ ST state;
++ SP spec;
++
++ public void init(Object[] args) {
++ state = new ST;
++ }
++
++ public void set(SP spec, Vector pos, float deg, float speed) {
++ set(spec, pos.x, pos.y, deg, speed);
++ }
++
++ public void set(SP spec, float x, float y, float deg, float speed) {
++ this.spec = spec;
++ set(x, y, deg, speed);
++ }
++
++ public void set(float x, float y, float deg, float speed) {
++ state.clear();
++ state.pos.x = x;
++ state.pos.y = y;
++ state.deg = deg;
++ state.speed = speed;
++ spec.set(state);
++ _exists = true;
++ }
++
++ public void move() {
++ if (!spec.move(state))
++ remove();
++ }
++
++ public void remove() {
++ _exists = false;
++ spec.removed(state);
++ }
++
++ public void draw() {
++ spec.draw(state);
++ }
++
++ public Vector pos() {
++ return state.pos;
++ }
++}
++
++public class Enemy: Token2!(EnemyState, EnemySpec) {
+ private:
+
+ public override void init(Object[] args) {
+@@ -423,7 +470,28 @@
+ }
+ }
+
+-public class EnemySpec: TokenSpec!(EnemyState) {
++public class TokenSpec2(T) {
++ protected:
++ Field field;
++ Shape shape;
++
++ public void set(T state) {}
++ public void removed(T state) {}
++
++ public bool move(T state) {
++ return true;
++ }
++
++ public void draw(T state) {
++ with (state) {
++ Vector3 p = field.calcCircularPos(pos);
++ float cd = field.calcCircularDeg(pos.x);
++ shape.draw(p, cd, deg);
++ }
++ }
++}
++
++public class EnemySpec: TokenSpec2!(EnemyState) {
+ mixin StaticRandImpl;
+ protected:
+ static const float BULLET_HIT_WIDTH = 0.8f;
+@@ -1464,7 +1532,7 @@
+ }
+ }
+
+-public class TurretSpec: TokenSpec!(TurretState) {
++public class TurretSpec: TokenSpec2!(TurretState) {
+ mixin StaticRandImpl;
+ public:
+ static const float SPEED_RATIO = 5.0f;
+diff -Naur ttn/src/abagames/ttn/particle.d ttn-gentoo/src/abagames/ttn/particle.d
+--- ttn/src/abagames/ttn/particle.d 2006-12-04 17:04:26.000000000 +0100
++++ ttn-gentoo/src/abagames/ttn/particle.d 2007-09-20 08:33:10.000000000 +0200
+@@ -24,7 +24,55 @@
+ public class ParticlePool: ActorPool!(Particle) {
+ }
+
+-public class Particle: Token!(ParticleState, ParticleSpec) {
++public class Token2(ST, SP): Actor {
++ protected:
++ ST state;
++ SP spec;
++
++ public void init(Object[] args) {
++ state = new ST;
++ }
++
++ public void set(SP spec, Vector pos, float deg, float speed) {
++ set(spec, pos.x, pos.y, deg, speed);
++ }
++
++ public void set(SP spec, float x, float y, float deg, float speed) {
++ this.spec = spec;
++ set(x, y, deg, speed);
++ }
++
++ public void set(float x, float y, float deg, float speed) {
++ state.clear();
++ state.pos.x = x;
++ state.pos.y = y;
++ state.deg = deg;
++ state.speed = speed;
++ spec.set(state);
++ _exists = true;
++ }
++
++ public void move() {
++ if (!spec.move(state))
++ remove();
++ }
++
++ public void remove() {
++ _exists = false;
++ spec.removed(state);
++ }
++
++ public void draw() {
++ spec.draw(state);
++ }
++
++ public Vector pos() {
++ return state.pos;
++ }
++}
++
++
++public class Particle: Token2!(ParticleState, ParticleSpec) {
+ public:
+ static const enum Shape {
+ TRIANGLE, LINE, QUAD, BONUS,
+@@ -153,7 +201,28 @@
+ }
+ }
+
+-public class ParticleSpec: TokenSpec!(ParticleState) {
++public class TokenSpec2(T) {
++ protected:
++ Field field;
++ Shape shape;
++
++ public void set(T state) {}
++ public void removed(T state) {}
++
++ public bool move(T state) {
++ return true;
++ }
++
++ public void draw(T state) {
++ with (state) {
++ Vector3 p = field.calcCircularPos(pos);
++ float cd = field.calcCircularDeg(pos.x);
++ shape.draw(p, cd, deg);
++ }
++ }
++}
++
++public class ParticleSpec: TokenSpec2!(ParticleState) {
+ mixin StaticRandImpl;
+ private:
+ Player player;
+diff -Naur ttn/src/abagames/ttn/pillar.d ttn-gentoo/src/abagames/ttn/pillar.d
+--- ttn/src/abagames/ttn/pillar.d 2006-11-19 08:54:55.000000000 +0100
++++ ttn-gentoo/src/abagames/ttn/pillar.d 2007-09-20 08:33:10.000000000 +0200
+@@ -6,6 +6,7 @@
+ module abagames.ttn.pillar;
+
+ private import std.math;
++private import abagames.util.vector;
+ private import abagames.util.actor;
+ private import abagames.ttn.field;
+ private import abagames.ttn.token;
+@@ -38,7 +39,54 @@
+ }
+ }
+
+-public class Pillar: Token!(PillarState, PillarSpec) {
++public class Token2(ST, SP): Actor {
++ protected:
++ ST state;
++ SP spec;
++
++ public void init(Object[] args) {
++ state = new ST;
++ }
++
++ public void set(SP spec, Vector pos, float deg, float speed) {
++ set(spec, pos.x, pos.y, deg, speed);
++ }
++
++ public void set(SP spec, float x, float y, float deg, float speed) {
++ this.spec = spec;
++ set(x, y, deg, speed);
++ }
++
++ public void set(float x, float y, float deg, float speed) {
++ state.clear();
++ state.pos.x = x;
++ state.pos.y = y;
++ state.deg = deg;
++ state.speed = speed;
++ spec.set(state);
++ _exists = true;
++ }
++
++ public void move() {
++ if (!spec.move(state))
++ remove();
++ }
++
++ public void remove() {
++ _exists = false;
++ spec.removed(state);
++ }
++
++ public void draw() {
++ spec.draw(state);
++ }
++
++ public Vector pos() {
++ return state.pos;
++ }
++}
++
++public class Pillar: Token2!(PillarState, PillarSpec) {
+ private:
+
+ public void set(PillarSpec ps, float y, float maxY, Pillar pp, PillarShape s, float vdeg, bool outside = false) {
+@@ -83,7 +131,28 @@
+ }
+ }
+
+-public class PillarSpec:TokenSpec!(PillarState) {
++public class TokenSpec2(T) {
++ protected:
++ Field field;
++ Shape shape;
++
++ public void set(T state) {}
++ public void removed(T state) {}
++
++ public bool move(T state) {
++ return true;
++ }
++
++ public void draw(T state) {
++ with (state) {
++ Vector3 p = field.calcCircularPos(pos);
++ float cd = field.calcCircularDeg(pos.x);
++ shape.draw(p, cd, deg);
++ }
++ }
++}
++
++public class PillarSpec:TokenSpec2!(PillarState) {
+ private:
+ static const VELOCITY_Y = 0.025f;
+
+diff -Naur ttn/src/abagames/ttn/player.d ttn-gentoo/src/abagames/ttn/player.d
+--- ttn/src/abagames/ttn/player.d 2006-12-04 17:04:26.000000000 +0100
++++ ttn-gentoo/src/abagames/ttn/player.d 2007-09-20 08:33:10.000000000 +0200
+@@ -24,10 +24,57 @@
+ private import abagames.ttn.sound;
+ private import abagames.ttn.letter;
+
++public class Token2(ST, SP): Actor {
++ protected:
++ ST state;
++ SP spec;
++
++ public void init(Object[] args) {
++ state = new ST;
++ }
++
++ public void set(SP spec, Vector pos, float deg, float speed) {
++ set(spec, pos.x, pos.y, deg, speed);
++ }
++
++ public void set(SP spec, float x, float y, float deg, float speed) {
++ this.spec = spec;
++ set(x, y, deg, speed);
++ }
++
++ public void set(float x, float y, float deg, float speed) {
++ state.clear();
++ state.pos.x = x;
++ state.pos.y = y;
++ state.deg = deg;
++ state.speed = speed;
++ spec.set(state);
++ _exists = true;
++ }
++
++ public void move() {
++ if (!spec.move(state))
++ remove();
++ }
++
++ public void remove() {
++ _exists = false;
++ spec.removed(state);
++ }
++
++ public void draw() {
++ spec.draw(state);
++ }
++
++ public Vector pos() {
++ return state.pos;
++ }
++}
++
+ /**
+ * Player and shots.
+ */
+-public class Player: Token!(PlayerState, PlayerSpec) {
++public class Player: Token2!(PlayerState, PlayerSpec) {
+ private:
+ Vector hitOffset;
+
+@@ -300,7 +347,28 @@
+ }
+ }
+
+-public class PlayerSpec: TokenSpec!(PlayerState) {
++public class TokenSpec2(T) {
++ protected:
++ Field field;
++ Shape shape;
++
++ public void set(T state) {}
++ public void removed(T state) {}
++
++ public bool move(T state) {
++ return true;
++ }
++
++ public void draw(T state) {
++ with (state) {
++ Vector3 p = field.calcCircularPos(pos);
++ float cd = field.calcCircularDeg(pos.x);
++ shape.draw(p, cd, deg);
++ }
++ }
++}
++
++public class PlayerSpec: TokenSpec2!(PlayerState) {
+ mixin StaticRandImpl;
+ public:
+ static const float BASE_SPEED = 0.15f;
+@@ -768,7 +836,7 @@
+ }
+ }
+
+-public class Shot: Token!(ShotState, ShotSpec) {
++public class Shot: Token2!(ShotState, ShotSpec) {
+ private:
+
+ public void setParent(Shot s) {
+@@ -788,7 +856,7 @@
+ }
+ }
+
+-public class ShotSpec: TokenSpec!(ShotState) {
++public class ShotSpec: TokenSpec2!(ShotState) {
+ private:
+ EnemyPool enemies;
+ BulletPool bullets;
+diff -Naur ttn/src/abagames/ttn/screen.d ttn-gentoo/src/abagames/ttn/screen.d
+--- ttn/src/abagames/ttn/screen.d 2006-12-04 17:04:26.000000000 +0100
++++ ttn-gentoo/src/abagames/ttn/screen.d 2007-09-20 08:33:10.000000000 +0200
+@@ -21,7 +21,7 @@
+ Field field;
+
+ protected void setIcon() {
+- SDL_WM_SetIcon(SDL_LoadBMP(ICON_FILE_NAME), null);
++// SDL_WM_SetIcon(SDL_LoadBMP(ICON_FILE_NAME), null);
+ }
+
+ protected void init() {
+diff -Naur ttn/src/abagames/util/rand.d ttn-gentoo/src/abagames/util/rand.d
+--- ttn/src/abagames/util/rand.d 2006-11-19 08:54:55.000000000 +0100
++++ ttn-gentoo/src/abagames/util/rand.d 2007-09-20 08:33:10.000000000 +0200
+@@ -176,14 +176,14 @@
+
+ void next_state()
+ {
+- uint *p=state;
++ uint *p=state.ptr;
+
+ /* if init_genrand() has not been called, */
+ /* a default initial seed is used */
+ if (initf==0) init_genrand(5489UL);
+
+ left = N;
+- next = state;
++ next = state.ptr;
+
+ for (int j=N-M+1; --j; p++)
+ *p = p[M] ^ TWIST(p[0], p[1]);
+diff -Naur ttn/src/abagames/util/sdl/texture.d ttn-gentoo/src/abagames/util/sdl/texture.d
+--- ttn/src/abagames/util/sdl/texture.d 2006-11-19 08:54:55.000000000 +0100
++++ ttn-gentoo/src/abagames/util/sdl/texture.d 2007-09-20 08:33:10.000000000 +0200
+@@ -103,13 +103,13 @@
+ }
+ glBindTexture(GL_TEXTURE_2D, num + ti);
+ gluBuild2DMipmaps(GL_TEXTURE_2D, 4, panelWidth, panelHeight,
+- GL_RGBA, GL_UNSIGNED_BYTE, pixels);
++ GL_RGBA, GL_UNSIGNED_BYTE, pixels.ptr);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ if (maskColor != 0xffffffffu) {
+ glBindTexture(GL_TEXTURE_2D, maskNum + ti);
+ gluBuild2DMipmaps(GL_TEXTURE_2D, 4, panelWidth, panelHeight,
+- GL_RGBA, GL_UNSIGNED_BYTE, maskPixels);
++ GL_RGBA, GL_UNSIGNED_BYTE, maskPixels.ptr);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MIN_FILTER,GL_LINEAR_MIPMAP_NEAREST);
+ glTexParameteri(GL_TEXTURE_2D,GL_TEXTURE_MAG_FILTER,GL_LINEAR);
+ }
diff --git a/games-action/titanion/files/titanion.png b/games-action/titanion/files/titanion.png
new file mode 100644
index 0000000..b424a84
--- /dev/null
+++ b/games-action/titanion/files/titanion.png
Binary files differ
diff --git a/games-action/titanion/metadata.xml b/games-action/titanion/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/titanion/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/titanion/titanion-0.3.ebuild b/games-action/titanion/titanion-0.3.ebuild
new file mode 100644
index 0000000..0ae87d7
--- /dev/null
+++ b/games-action/titanion/titanion-0.3.ebuild
@@ -0,0 +1,64 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=ttn
+MY_PV=${PV//./_}
+
+DESCRIPTION="Strike down super high-velocity swooping insects. Fixed shooter in the good old days, 'Titanion'. "
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/ttn_e.html"
+SRC_URI="http://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+DEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer"
+RDEPEND=""
+
+S=${WORKDIR}/${MY_PN}
+
+src_unpack(){
+ unpack ${A}
+}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(ttn.prf[^"]*\)":"'${GAMES_STATEDIR}'/'${PN}'/\1":g' -i src/abagames/ttn/preference.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+ dodir "${GAMES_STATEDIR}/${PN}" "${GAMES_STATEDIR}/${PN}/replay"
+ local statedir="${GAMES_STATEDIR}"/${PN}
+
+ if [ ! -e ${D}"${GAMES_STATEDIR}"/${PN}/ttn.prf ]; then
+ touch ${D}"${GAMES_STATEDIR}"/${PN}/ttn.prf
+ chmod ug+rw ${D}$"{GAMES_STATEDIR}"/${PN}/ttn.prf
+ fperms 660 ${D}"${GAMES_STATEDIR}"/${PN}/ttn.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r images sounds || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/torustrooper/Manifest b/games-action/torustrooper/Manifest
new file mode 100644
index 0000000..ef4fd99
--- /dev/null
+++ b/games-action/torustrooper/Manifest
@@ -0,0 +1,5 @@
+AUX torustrooper-0.22.diff 25604 RMD160 974631e87f9201e66d2e07e43f3e39425fc02767 SHA1 69b5be3732ca114853704040d028cfe2281388ec SHA256 3d9c81299af85d4aa05eb36ac8c7854a5b1f8efd0716ca396817900ecbc29160
+AUX torustrooper.png 3106 RMD160 8182a4c4a79dd1cb013ac503d43076350c15b60f SHA1 c55233b8b2c214022d50f5811f5d11f52d3fdff9 SHA256 cced357701c1bee13231f2f396f2e45ccc7c84921574fa8fd60c09ede1e865d8
+DIST tt0_22.zip 6315755 RMD160 d72fdb66cd103ed0a935c079531a7d271e982506 SHA1 b00dc240e5c503031febf9a305f39b475afc279f SHA256 6fcbb3de9ac5cfce38253f71257143631a978c625b041c8527d18ddb5c8813fa
+EBUILD torustrooper-0.22.ebuild 1689 RMD160 b57a93a295d821d8e89074d5b862d62511610fc6 SHA1 929a58cf71dd7f5c3180d211fbcf330a9a45795f SHA256 3c132fc5a89f20ce0a9e8903cf9e504977a97343963dfb338f1c54adc15ac380
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/torustrooper/files/digest-torustrooper-0.22 b/games-action/torustrooper/files/digest-torustrooper-0.22
new file mode 100644
index 0000000..74c2eb6
--- /dev/null
+++ b/games-action/torustrooper/files/digest-torustrooper-0.22
@@ -0,0 +1,3 @@
+MD5 1abb57950b96f1a7f7ac8364e9a42322 tt0_22.zip 6315755
+RMD160 d72fdb66cd103ed0a935c079531a7d271e982506 tt0_22.zip 6315755
+SHA256 6fcbb3de9ac5cfce38253f71257143631a978c625b041c8527d18ddb5c8813fa tt0_22.zip 6315755
diff --git a/games-action/torustrooper/files/torustrooper-0.22.diff b/games-action/torustrooper/files/torustrooper-0.22.diff
new file mode 100644
index 0000000..2528d95
--- /dev/null
+++ b/games-action/torustrooper/files/torustrooper-0.22.diff
@@ -0,0 +1,881 @@
+diff -Naur tt/import/opengl.d tt-gentoo/import/opengl.d
+--- tt/import/opengl.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/import/opengl.d 2007-09-20 08:35:29.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur tt/import/openglu.d tt-gentoo/import/openglu.d
+--- tt/import/openglu.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/import/openglu.d 2007-09-20 08:35:35.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur tt/import/SDL.d tt-gentoo/import/SDL.d
+--- tt/import/SDL.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/import/SDL.d 2007-09-20 08:35:03.000000000 +0200
+@@ -20,18 +20,28 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_keysym_;
++public import SDL_version_;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+
+ extern(C):
+
+@@ -73,20 +83,3 @@
+ */
+ void SDL_Quit();
+
+-/+
+-void SDL_SetModuleHandle(void *hInst);
+-extern(Windows) void* GetModuleHandle(char*);
+-
+-static this()
+-{
+- /* Load SDL dynamic link library */
+- if (SDL_Init(SDL_INIT_NOPARACHUTE) < 0)
+- throw new Error("Error loading SDL");
+- SDL_SetModuleHandle(GetModuleHandle(null));
+-}
+-
+-static ~this()
+-{
+- SDL_Quit();
+-}
+-+/
+diff -Naur tt/import/SDL_events.d tt-gentoo/import/SDL_events.d
+--- tt/import/SDL_events.d 2005-01-01 21:40:28.000000000 +0100
++++ tt-gentoo/import/SDL_events.d 2007-09-20 08:35:03.000000000 +0200
+@@ -304,8 +304,8 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() will return the
+ current processing state of the specified event.
+ */
+-const uint SDL_QUERY = cast(uint) -1;
+-const uint SDL_IGNORE = 0;
+-const uint SDL_DISABLE = 0;
+-const uint SDL_ENABLE = 1;
++const int SDL_QUERY = -1;
++const int SDL_IGNORE = 0;
++const int SDL_DISABLE = 0;
++const int SDL_ENABLE = 1;
+ Uint8 SDL_EventState(Uint8 type, int state);
+diff -Naur tt/import/SDL_keyboard.d tt-gentoo/import/SDL_keyboard.d
+--- tt/import/SDL_keyboard.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/import/SDL_keyboard.d 2007-09-20 08:35:03.000000000 +0200
+@@ -26,7 +26,7 @@
+ // !!! A hack! struct SDL_keysym is defined in this module,
+ // !!! so we need to resolve the nameclash...
+ // !!! Definitely won't work on *NIX but for now will do.
+-import SDL_Keysym;
++import SDL_keysym_;
+
+ extern(C):
+
+diff -Naur tt/import/SDL_keysym_.d tt-gentoo/import/SDL_keysym_.d
+--- tt/import/SDL_keysym_.d 1970-01-01 01:00:00.000000000 +0100
++++ tt-gentoo/import/SDL_keysym_.d 2007-09-20 08:35:03.000000000 +0200
+@@ -0,0 +1,308 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* What we really want is a mapping of every raw key on the keyboard.
++ To support international keyboards, we use the range 0xA1 - 0xFF
++ as international virtual keycodes. We'll follow in the footsteps of X11...
++ The names of the keys
++ */
++
++alias int SDLKey;
++enum {
++ /* The keyboard syms have been cleverly chosen to map to ASCII */
++ SDLK_UNKNOWN = 0,
++ SDLK_FIRST = 0,
++ SDLK_BACKSPACE = 8,
++ SDLK_TAB = 9,
++ SDLK_CLEAR = 12,
++ SDLK_RETURN = 13,
++ SDLK_PAUSE = 19,
++ SDLK_ESCAPE = 27,
++ SDLK_SPACE = 32,
++ SDLK_EXCLAIM = 33,
++ SDLK_QUOTEDBL = 34,
++ SDLK_HASH = 35,
++ SDLK_DOLLAR = 36,
++ SDLK_AMPERSAND = 38,
++ SDLK_QUOTE = 39,
++ SDLK_LEFTPAREN = 40,
++ SDLK_RIGHTPAREN = 41,
++ SDLK_ASTERISK = 42,
++ SDLK_PLUS = 43,
++ SDLK_COMMA = 44,
++ SDLK_MINUS = 45,
++ SDLK_PERIOD = 46,
++ SDLK_SLASH = 47,
++ SDLK_0 = 48,
++ SDLK_1 = 49,
++ SDLK_2 = 50,
++ SDLK_3 = 51,
++ SDLK_4 = 52,
++ SDLK_5 = 53,
++ SDLK_6 = 54,
++ SDLK_7 = 55,
++ SDLK_8 = 56,
++ SDLK_9 = 57,
++ SDLK_COLON = 58,
++ SDLK_SEMICOLON = 59,
++ SDLK_LESS = 60,
++ SDLK_EQUALS = 61,
++ SDLK_GREATER = 62,
++ SDLK_QUESTION = 63,
++ SDLK_AT = 64,
++ /*
++ Skip uppercase letters
++ */
++ SDLK_LEFTBRACKET = 91,
++ SDLK_BACKSLASH = 92,
++ SDLK_RIGHTBRACKET = 93,
++ SDLK_CARET = 94,
++ SDLK_UNDERSCORE = 95,
++ SDLK_BACKQUOTE = 96,
++ SDLK_a = 97,
++ SDLK_b = 98,
++ SDLK_c = 99,
++ SDLK_d = 100,
++ SDLK_e = 101,
++ SDLK_f = 102,
++ SDLK_g = 103,
++ SDLK_h = 104,
++ SDLK_i = 105,
++ SDLK_j = 106,
++ SDLK_k = 107,
++ SDLK_l = 108,
++ SDLK_m = 109,
++ SDLK_n = 110,
++ SDLK_o = 111,
++ SDLK_p = 112,
++ SDLK_q = 113,
++ SDLK_r = 114,
++ SDLK_s = 115,
++ SDLK_t = 116,
++ SDLK_u = 117,
++ SDLK_v = 118,
++ SDLK_w = 119,
++ SDLK_x = 120,
++ SDLK_y = 121,
++ SDLK_z = 122,
++ SDLK_DELETE = 127,
++ /* End of ASCII mapped keysyms */
++
++ /* International keyboard syms */
++ SDLK_WORLD_0 = 160, /* 0xA0 */
++ SDLK_WORLD_1 = 161,
++ SDLK_WORLD_2 = 162,
++ SDLK_WORLD_3 = 163,
++ SDLK_WORLD_4 = 164,
++ SDLK_WORLD_5 = 165,
++ SDLK_WORLD_6 = 166,
++ SDLK_WORLD_7 = 167,
++ SDLK_WORLD_8 = 168,
++ SDLK_WORLD_9 = 169,
++ SDLK_WORLD_10 = 170,
++ SDLK_WORLD_11 = 171,
++ SDLK_WORLD_12 = 172,
++ SDLK_WORLD_13 = 173,
++ SDLK_WORLD_14 = 174,
++ SDLK_WORLD_15 = 175,
++ SDLK_WORLD_16 = 176,
++ SDLK_WORLD_17 = 177,
++ SDLK_WORLD_18 = 178,
++ SDLK_WORLD_19 = 179,
++ SDLK_WORLD_20 = 180,
++ SDLK_WORLD_21 = 181,
++ SDLK_WORLD_22 = 182,
++ SDLK_WORLD_23 = 183,
++ SDLK_WORLD_24 = 184,
++ SDLK_WORLD_25 = 185,
++ SDLK_WORLD_26 = 186,
++ SDLK_WORLD_27 = 187,
++ SDLK_WORLD_28 = 188,
++ SDLK_WORLD_29 = 189,
++ SDLK_WORLD_30 = 190,
++ SDLK_WORLD_31 = 191,
++ SDLK_WORLD_32 = 192,
++ SDLK_WORLD_33 = 193,
++ SDLK_WORLD_34 = 194,
++ SDLK_WORLD_35 = 195,
++ SDLK_WORLD_36 = 196,
++ SDLK_WORLD_37 = 197,
++ SDLK_WORLD_38 = 198,
++ SDLK_WORLD_39 = 199,
++ SDLK_WORLD_40 = 200,
++ SDLK_WORLD_41 = 201,
++ SDLK_WORLD_42 = 202,
++ SDLK_WORLD_43 = 203,
++ SDLK_WORLD_44 = 204,
++ SDLK_WORLD_45 = 205,
++ SDLK_WORLD_46 = 206,
++ SDLK_WORLD_47 = 207,
++ SDLK_WORLD_48 = 208,
++ SDLK_WORLD_49 = 209,
++ SDLK_WORLD_50 = 210,
++ SDLK_WORLD_51 = 211,
++ SDLK_WORLD_52 = 212,
++ SDLK_WORLD_53 = 213,
++ SDLK_WORLD_54 = 214,
++ SDLK_WORLD_55 = 215,
++ SDLK_WORLD_56 = 216,
++ SDLK_WORLD_57 = 217,
++ SDLK_WORLD_58 = 218,
++ SDLK_WORLD_59 = 219,
++ SDLK_WORLD_60 = 220,
++ SDLK_WORLD_61 = 221,
++ SDLK_WORLD_62 = 222,
++ SDLK_WORLD_63 = 223,
++ SDLK_WORLD_64 = 224,
++ SDLK_WORLD_65 = 225,
++ SDLK_WORLD_66 = 226,
++ SDLK_WORLD_67 = 227,
++ SDLK_WORLD_68 = 228,
++ SDLK_WORLD_69 = 229,
++ SDLK_WORLD_70 = 230,
++ SDLK_WORLD_71 = 231,
++ SDLK_WORLD_72 = 232,
++ SDLK_WORLD_73 = 233,
++ SDLK_WORLD_74 = 234,
++ SDLK_WORLD_75 = 235,
++ SDLK_WORLD_76 = 236,
++ SDLK_WORLD_77 = 237,
++ SDLK_WORLD_78 = 238,
++ SDLK_WORLD_79 = 239,
++ SDLK_WORLD_80 = 240,
++ SDLK_WORLD_81 = 241,
++ SDLK_WORLD_82 = 242,
++ SDLK_WORLD_83 = 243,
++ SDLK_WORLD_84 = 244,
++ SDLK_WORLD_85 = 245,
++ SDLK_WORLD_86 = 246,
++ SDLK_WORLD_87 = 247,
++ SDLK_WORLD_88 = 248,
++ SDLK_WORLD_89 = 249,
++ SDLK_WORLD_90 = 250,
++ SDLK_WORLD_91 = 251,
++ SDLK_WORLD_92 = 252,
++ SDLK_WORLD_93 = 253,
++ SDLK_WORLD_94 = 254,
++ SDLK_WORLD_95 = 255, /* 0xFF */
++
++ /* Numeric keypad */
++ SDLK_KP0 = 256,
++ SDLK_KP1 = 257,
++ SDLK_KP2 = 258,
++ SDLK_KP3 = 259,
++ SDLK_KP4 = 260,
++ SDLK_KP5 = 261,
++ SDLK_KP6 = 262,
++ SDLK_KP7 = 263,
++ SDLK_KP8 = 264,
++ SDLK_KP9 = 265,
++ SDLK_KP_PERIOD = 266,
++ SDLK_KP_DIVIDE = 267,
++ SDLK_KP_MULTIPLY = 268,
++ SDLK_KP_MINUS = 269,
++ SDLK_KP_PLUS = 270,
++ SDLK_KP_ENTER = 271,
++ SDLK_KP_EQUALS = 272,
++
++ /* Arrows + Home/End pad */
++ SDLK_UP = 273,
++ SDLK_DOWN = 274,
++ SDLK_RIGHT = 275,
++ SDLK_LEFT = 276,
++ SDLK_INSERT = 277,
++ SDLK_HOME = 278,
++ SDLK_END = 279,
++ SDLK_PAGEUP = 280,
++ SDLK_PAGEDOWN = 281,
++
++ /* Function keys */
++ SDLK_F1 = 282,
++ SDLK_F2 = 283,
++ SDLK_F3 = 284,
++ SDLK_F4 = 285,
++ SDLK_F5 = 286,
++ SDLK_F6 = 287,
++ SDLK_F7 = 288,
++ SDLK_F8 = 289,
++ SDLK_F9 = 290,
++ SDLK_F10 = 291,
++ SDLK_F11 = 292,
++ SDLK_F12 = 293,
++ SDLK_F13 = 294,
++ SDLK_F14 = 295,
++ SDLK_F15 = 296,
++
++ /* Key state modifier keys */
++ SDLK_NUMLOCK = 300,
++ SDLK_CAPSLOCK = 301,
++ SDLK_SCROLLOCK = 302,
++ SDLK_RSHIFT = 303,
++ SDLK_LSHIFT = 304,
++ SDLK_RCTRL = 305,
++ SDLK_LCTRL = 306,
++ SDLK_RALT = 307,
++ SDLK_LALT = 308,
++ SDLK_RMETA = 309,
++ SDLK_LMETA = 310,
++ SDLK_LSUPER = 311, /* Left "Windows" key */
++ SDLK_RSUPER = 312, /* Right "Windows" key */
++ SDLK_MODE = 313, /* "Alt Gr" key */
++ SDLK_COMPOSE = 314, /* Multi-key compose key */
++
++ /* Miscellaneous function keys */
++ SDLK_HELP = 315,
++ SDLK_PRINT = 316,
++ SDLK_SYSREQ = 317,
++ SDLK_BREAK = 318,
++ SDLK_MENU = 319,
++ SDLK_POWER = 320, /* Power Macintosh power key */
++ SDLK_EURO = 321, /* Some european keyboards */
++ SDLK_UNDO = 322, /* Atari keyboard has Undo */
++
++ /* Add any other keys here */
++
++ SDLK_LAST
++}
++
++/* Enumeration of valid key mods (possibly OR'd together) */
++alias int SDLMod;
++enum {
++ KMOD_NONE = 0x0000,
++ KMOD_LSHIFT= 0x0001,
++ KMOD_RSHIFT= 0x0002,
++ KMOD_LCTRL = 0x0040,
++ KMOD_RCTRL = 0x0080,
++ KMOD_LALT = 0x0100,
++ KMOD_RALT = 0x0200,
++ KMOD_LMETA = 0x0400,
++ KMOD_RMETA = 0x0800,
++ KMOD_NUM = 0x1000,
++ KMOD_CAPS = 0x2000,
++ KMOD_MODE = 0x4000,
++ KMOD_RESERVED = 0x8000
++}
++
++const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
++const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
++const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
++const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur tt/import/SDL_mixer.d tt-gentoo/import/SDL_mixer.d
+--- tt/import/SDL_mixer.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/import/SDL_mixer.d 2007-09-20 08:35:03.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ // convert to D by shinichiro.h
+
+-/* $Id: SDL_mixer.d,v 1.1.1.1 2004/11/10 13:45:22 kenta Exp $ */
++/* $Id: SDL_mixer.d,v 1.1.1.1 2006/11/19 07:54:54 kenta Exp $ */
+
+ import SDL;
+
+diff -Naur tt/import/SDL_syswm.d tt-gentoo/import/SDL_syswm.d
+--- tt/import/SDL_syswm.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/import/SDL_syswm.d 2007-09-20 08:35:03.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-import SDL_Version;
++import SDL_version_;
+
+ extern(C):
+
+diff -Naur tt/import/SDL_version_.d tt-gentoo/import/SDL_version_.d
+--- tt/import/SDL_version_.d 1970-01-01 01:00:00.000000000 +0100
++++ tt-gentoo/import/SDL_version_.d 2007-09-20 08:35:03.000000000 +0200
+@@ -0,0 +1,75 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* This header defines the current SDL version */
++
++import SDL_types;
++
++extern(C):
++
++/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
++*/
++const uint SDL_MAJOR_VERSION = 1;
++const uint SDL_MINOR_VERSION = 2;
++const uint SDL_PATCHLEVEL = 6;
++
++struct SDL_version {
++ Uint8 major;
++ Uint8 minor;
++ Uint8 patch;
++}
++
++/* This macro can be used to fill a version structure with the compile-time
++ * version of the SDL library.
++ */
++void SDL_VERSION(SDL_version* X)
++{
++ X.major = SDL_MAJOR_VERSION;
++ X.minor = SDL_MINOR_VERSION;
++ X.patch = SDL_PATCHLEVEL;
++}
++
++/* This macro turns the version numbers into a numeric value:
++ (1,2,3) -> (1203)
++ This assumes that there will never be more than 100 patchlevels
++*/
++uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return X * 1000 + Y * 100 + Z;
++}
++
++/* This is the version number macro for the current SDL version */
++const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
++ SDL_MINOR_VERSION * 100 +
++ SDL_PATCHLEVEL;
++
++/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
++bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
++}
++
++/* This function gets the version of the dynamically linked SDL library.
++ it should NOT be used to fill a version structure, instead you should
++ use the SDL_Version() macro.
++ */
++SDL_version * SDL_Linked_Version();
+diff -Naur tt/Makefile tt-gentoo/Makefile
+--- tt/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ tt-gentoo/Makefile 2007-09-20 08:35:03.000000000 +0200
+@@ -0,0 +1,27 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-O -d -release -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -frelease -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/ -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=torustrooper
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer -lstdc++
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
++
++
+diff -Naur tt/src/abagames/tt/barrage.d tt-gentoo/src/abagames/tt/barrage.d
+--- tt/src/abagames/tt/barrage.d 2005-01-01 21:40:28.000000000 +0100
++++ tt-gentoo/src/abagames/tt/barrage.d 2007-09-20 08:35:03.000000000 +0200
+@@ -17,6 +17,7 @@
+ private import abagames.tt.bulletimpl;
+ private import abagames.tt.bullettarget;
+ private import abagames.tt.shape;
++import linux_listdir;
+
+ /**
+ * Barrage pattern.
+@@ -30,11 +31,12 @@
+ int prevWait, postWait;
+ bool noXReverse = false;
+
+- public static this() {
++ public static void randInit() {
+ rand = new Rand;
+ }
+
+ public static void setRandSeed(long seed) {
++ if (!rand) rand = new Rand;
+ rand.setSeed(seed);
+ }
+
+@@ -93,29 +95,31 @@
+ public class BarrageManager {
+ private:
+ static BulletMLParserTinyXML *parser[char[]][char[]];
++ static BulletMLParserTinyXML *parser2[char[]];
+ static const char[] BARRAGE_DIR_NAME = "barrage";
+
+ public static void load() {
+- char[][] dirs = listdir(BARRAGE_DIR_NAME);
++ char[][] dirs = linux_listdir.listdir(BARRAGE_DIR_NAME);
+ foreach (char[] dirName; dirs) {
+- char[][] files = listdir(BARRAGE_DIR_NAME ~ "/" ~ dirName);
++ char[][] files = linux_listdir.listdir(BARRAGE_DIR_NAME ~ "/" ~ dirName);
+ foreach (char[] fileName; files) {
+ if (getExt(fileName) != "xml")
+ continue;
+- parser[dirName][fileName] = getInstance(dirName, fileName);
++ char[] barrageName = dirName ~ "/" ~ fileName;
++ parser2[barrageName] = getInstance(dirName, fileName);
+ }
+ }
+ }
+
+ public static BulletMLParserTinyXML* getInstance(char[] dirName, char[] fileName) {
+- if (!parser[dirName][fileName]) {
+- char[] barrageName = dirName ~ "/" ~ fileName;
+- Logger.info("Load BulletML: " ~ barrageName);
+- parser[dirName][fileName] =
+- BulletMLParserTinyXML_new(std.string.toStringz(BARRAGE_DIR_NAME ~ "/" ~ barrageName));
+- BulletMLParserTinyXML_parse(parser[dirName][fileName]);
++ char[] barrageName = dirName ~ "/" ~ fileName;
++ if (!parser2[barrageName]) {
++ Logger.info("Load BulletML: " ~ barrageName);
++ parser2[barrageName] =
++ BulletMLParserTinyXML_new(std.string.toStringz(BARRAGE_DIR_NAME ~ "/" ~ barrageName));
++ BulletMLParserTinyXML_parse(parser2[barrageName]);
+ }
+- return parser[dirName][fileName];
++ return parser2[barrageName];
+ }
+
+ public static BulletMLParserTinyXML*[] getInstanceList(char[] dirName) {
+diff -Naur tt/src/abagames/tt/enemy.d tt-gentoo/src/abagames/tt/enemy.d
+--- tt/src/abagames/tt/enemy.d 2005-01-09 12:50:00.000000000 +0100
++++ tt-gentoo/src/abagames/tt/enemy.d 2007-09-20 08:35:03.000000000 +0200
+@@ -59,6 +59,9 @@
+
+ public static this() {
+ rand = new Rand;
++ ShipShape.randInit();
++ Particle.randInit();
++ Barrage.randInit();
+ }
+
+ public static void setRandSeed(long seed) {
+diff -Naur tt/src/abagames/tt/particle.d tt-gentoo/src/abagames/tt/particle.d
+--- tt/src/abagames/tt/particle.d 2005-01-01 21:40:28.000000000 +0100
++++ tt-gentoo/src/abagames/tt/particle.d 2007-09-20 08:35:03.000000000 +0200
+@@ -42,7 +42,7 @@
+ float d1, d2, md1, md2;
+ float width, height;
+
+- public static this() {
++ public static void randInit() {
+ rand = new Rand;
+ }
+
+diff -Naur tt/src/abagames/tt/shape.d tt-gentoo/src/abagames/tt/shape.d
+--- tt/src/abagames/tt/shape.d 2004-11-12 23:46:02.000000000 +0100
++++ tt-gentoo/src/abagames/tt/shape.d 2007-09-20 08:35:03.000000000 +0200
+@@ -66,10 +66,10 @@
+ Vector rocketPos, fragmentPos;
+ int color;
+
+- static this() {
++ public static void randInit() {
+ rand = new Rand;
+ }
+-
++
+ public this(long randSeed) {
+ rand.setSeed(randSeed);
+ }
+@@ -809,7 +809,7 @@
+ _collision = new Vector;
+ return _shape = v;
+ }
+-
++
+ public float size(float v) {
+ return _size = v;
+ }
+diff -Naur tt/src/abagames/tt/stagemanager.d tt-gentoo/src/abagames/tt/stagemanager.d
+--- tt/src/abagames/tt/stagemanager.d 2005-01-09 12:50:00.000000000 +0100
++++ tt-gentoo/src/abagames/tt/stagemanager.d 2007-09-20 08:35:03.000000000 +0200
+@@ -435,25 +435,25 @@
+ br.setLongRange(longRange);
+ BulletMLParserTinyXML*[] ps;
+ int psn;
+- if (baseDir) {
+- ps = BarrageManager.getInstanceList(baseDir);
+- int pi = rand.nextInt(ps.length);
+- br.addBml(ps[pi], rank, true, speedRank);
+- } else {
++ // if (baseDir) {
++ // ps = BarrageManager.getInstanceList(baseDir);
++ // int pi = rand.nextInt(ps.length);
++ // br.addBml(ps[pi], rank, true, speedRank);
++ // } else {
+ br.addBml("basic", "straight.xml", rank, true, speedRank);
+- }
+- ps = BarrageManager.getInstanceList("morph");
+- psn = ps.length;
++ // }
++ // ps = BarrageManager.getInstanceList("morph");
++ psn = 13;
+ for (int i = 0; i < morphCnt; i++) {
+- int pi = rand.nextInt(ps.length);
+- while (!ps[pi]) {
+- pi--;
++ int pi = rand.nextInt(13);
++ // while (!ps[pi]) {
++ // pi--;
+ if (pi < 0)
+- pi = ps.length - 1;
+- }
+- br.addBml(ps[pi], morphRank, true, speedRank);
+- delete ps[pi];
+- psn--;
++ pi = 13 - 1;
++ // }
++// br.addBml(ps[pi], morphRank, true, speedRank);
++ // delete ps[pi];
++ // psn--;
+ }
+ return br;
+ }
+diff -Naur tt/src/abagames/util/bulletml/bullet.d tt-gentoo/src/abagames/util/bulletml/bullet.d
+--- tt/src/abagames/util/bulletml/bullet.d 2005-01-01 21:40:28.000000000 +0100
++++ tt-gentoo/src/abagames/util/bulletml/bullet.d 2007-09-20 08:35:03.000000000 +0200
+@@ -77,7 +77,7 @@
+ this.runner = runner;
+ }
+
+- public void set(BulletMLRunner* runner,
++ public void set(BulletMLRunner* runner,
+ float x, float y, float deg, float speed, float rank) {
+ set(x, y, deg, speed, rank);
+ setRunner(runner);
+diff -Naur tt/src/abagames/util/iterator.d tt-gentoo/src/abagames/util/iterator.d
+--- tt/src/abagames/util/iterator.d 2005-01-01 21:40:28.000000000 +0100
++++ tt-gentoo/src/abagames/util/iterator.d 2007-09-20 08:35:03.000000000 +0200
+@@ -35,4 +35,7 @@
+ }
+ }
+
+-alias ArrayIterator!(char[]) StringIterator;
++//alias ArrayIterator!(char[]) StringIterator;
++class StringIterator : ArrayIterator!(char[]) {
++ this(char[][] d) { super(d); }
++}
+\ Kein Zeilenumbruch am Dateiende.
+diff -Naur tt/src/abagames/util/logger.d tt-gentoo/src/abagames/util/logger.d
+--- tt/src/abagames/util/logger.d 2004-11-10 22:45:22.000000000 +0100
++++ tt-gentoo/src/abagames/util/logger.d 2007-09-20 08:35:03.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.util.logger;
+
+-private import std.stream;
++private import std.cstream;
+ private import std.string;
+
+ /**
+@@ -56,28 +56,28 @@
+
+ public static void info(char[] msg, bool nline = true) {
+ if (nline)
+- stderr.writeLine(msg);
++ derr.writeLine(msg);
+ else
+- stderr.writeString(msg);
++ derr.writeString(msg);
+ }
+
+ public static void info(double n, bool nline = true) {
+ if (nline)
+- stderr.writeLine(std.string.toString(n));
++ derr.writeLine(std.string.toString(n));
+ else
+- stderr.writeString(std.string.toString(n) ~ " ");
++ derr.writeString(std.string.toString(n) ~ " ");
+ }
+
+ public static void error(char[] msg) {
+- stderr.writeLine("Error: " ~ msg);
++ derr.writeLine("Error: " ~ msg);
+ }
+
+ public static void error(Exception e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ derr.writeLine("Error: " ~ e.toString());
+ }
+
+ public static void error(Error e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ derr.writeLine("Error: " ~ e.toString());
+ if (e.next)
+ error(e.next);
+ }
+diff -Naur tt/src/abagames/util/sdl/luminous.d tt-gentoo/src/abagames/util/sdl/luminous.d
+--- tt/src/abagames/util/sdl/luminous.d 2005-01-01 21:40:28.000000000 +0100
++++ tt-gentoo/src/abagames/util/sdl/luminous.d 2007-09-20 08:35:03.000000000 +0200
+@@ -9,6 +9,7 @@
+ private import std.string;
+ private import opengl;
+ private import abagames.util.actor;
++import std.c.string;
+
+ /**
+ * Luminous effect texture.
+diff -Naur tt/src/linux_listdir.d tt-gentoo/src/linux_listdir.d
+--- tt/src/linux_listdir.d 1970-01-01 01:00:00.000000000 +0100
++++ tt-gentoo/src/linux_listdir.d 2007-09-20 08:35:03.000000000 +0200
+@@ -0,0 +1,45 @@
++private import std.string;
++
++/***************************************************
++ * Return contents of directory.
++ */
++
++extern (C)
++{
++ struct DIR;
++
++ struct Dirent
++ {
++ uint d_ino;
++ uint d_off;
++ ushort d_reclen;
++ char d_type;
++ char[256] d_name; /* NAME_MAX+1 from linux/limits.h */
++ };
++
++ DIR* opendir(char* name);
++ int closedir(DIR* dir);
++ Dirent* readdir(DIR* dir);
++}
++
++char[][] listdir(char[] pathname)
++{
++
++ Dirent* entry;
++ DIR* dir = opendir(toStringz(pathname));
++ char[][] result;
++ entry = readdir(dir);
++ while ( entry !is null )
++ {
++
++ if ( std.string.strcmp(entry.d_name.ptr, ".") != 0
++ && std.string.strcmp(entry.d_name.ptr, "..") != 0)
++ {
++ result ~= std.string.toString(entry.d_name.ptr).dup;
++ }
++ entry = readdir(dir);
++ }
++ closedir(dir);
++ return result;
++
++}
diff --git a/games-action/torustrooper/files/torustrooper.png b/games-action/torustrooper/files/torustrooper.png
new file mode 100644
index 0000000..6060a42
--- /dev/null
+++ b/games-action/torustrooper/files/torustrooper.png
Binary files differ
diff --git a/games-action/torustrooper/metadata.xml b/games-action/torustrooper/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/torustrooper/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/torustrooper/torustrooper-0.22.ebuild b/games-action/torustrooper/torustrooper-0.22.ebuild
new file mode 100644
index 0000000..35fd612
--- /dev/null
+++ b/games-action/torustrooper/torustrooper-0.22.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=tt
+MY_PV=${PV//./_}
+
+DESCRIPTION="Speed! More speed! Speeding ship sailing through barrage, 'Torus Trooper'"
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/tt_e.html"
+SRC_URI="http://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(barrage[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tt/barrage.d \
+ -e 's:"\(tt.prf[^"]*\)":"'${GAMES_STATEDIR}'/'${PN}'/\1":g' -i src/abagames/tt/prefmanager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ dodir "${GAMES_STATEDIR}/${PN}" "${GAMES_STATEDIR}/${PN}/replay"
+ local statedir="${GAMES_STATEDIR}"/${PN}
+
+ if [ ! -e ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf ]; then
+ touch ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf
+ chmod ug+rw ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf
+ fperms 660 ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r barrage images sounds || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/torustrooperpure/Manifest b/games-action/torustrooperpure/Manifest
new file mode 100644
index 0000000..4f66488
--- /dev/null
+++ b/games-action/torustrooperpure/Manifest
@@ -0,0 +1,5 @@
+AUX torustrooperpure-0.2.diff 23009 RMD160 ded7404af0cd851fcd00efe99c119ca4d2b26d89 SHA1 2ab0c3c4c140b786caa19592ce03118c62ddd213 SHA256 095deeb85eec5117e4a7065214f79a697dbdb2b79f840222d015592ebe574309
+AUX torustrooperpure.png 7754 RMD160 6c1d85960642b94fc32d72c30815cce9edb22aac SHA1 08af4712cef5027dbfd22276962108030b039b58 SHA256 27742be9fd8399671b1f517cb7445e98e38e249c7579c5571d62b636e3dd32fa
+DIST ttp0_2.zip 6333904 RMD160 2b58f196144c8e0b6debe54c2025f3a7572c7e64 SHA1 0d7fa7c29866017e06427220ad463d9bf4197649 SHA256 8097a8ff19d74f1f145a541865d97ee8536241e937f255d3837df5d3955b7be2
+EBUILD torustrooperpure-0.2.ebuild 1665 RMD160 0e52fe6855333ebf80a6edf4571581d1fae1b369 SHA1 429ad630203dd26a324afc69617941d3bf06166f SHA256 dd1e2e39706e0f2dd9849fedeebe97588dd5a9fb1837fafbae29039f9368f064
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/torustrooperpure/files/digest-torustrooperpure-0.2 b/games-action/torustrooperpure/files/digest-torustrooperpure-0.2
new file mode 100644
index 0000000..d95b844
--- /dev/null
+++ b/games-action/torustrooperpure/files/digest-torustrooperpure-0.2
@@ -0,0 +1,3 @@
+MD5 fbf2f090ae8916b404ab875e4fece1de ttp0_2.zip 6333904
+RMD160 2b58f196144c8e0b6debe54c2025f3a7572c7e64 ttp0_2.zip 6333904
+SHA256 8097a8ff19d74f1f145a541865d97ee8536241e937f255d3837df5d3955b7be2 ttp0_2.zip 6333904
diff --git a/games-action/torustrooperpure/files/torustrooperpure-0.2.diff b/games-action/torustrooperpure/files/torustrooperpure-0.2.diff
new file mode 100644
index 0000000..da9442c
--- /dev/null
+++ b/games-action/torustrooperpure/files/torustrooperpure-0.2.diff
@@ -0,0 +1,781 @@
+diff -Naur ttp0_2/import/opengl.d ttp0_2-gentoo/import/opengl.d
+--- ttp0_2/import/opengl.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/import/opengl.d 2007-09-20 08:37:46.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1110,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1363,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur ttp0_2/import/openglu.d ttp0_2-gentoo/import/openglu.d
+--- ttp0_2/import/openglu.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/import/openglu.d 2007-09-20 08:37:52.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur ttp0_2/import/SDL.d ttp0_2-gentoo/import/SDL.d
+--- ttp0_2/import/SDL.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/import/SDL.d 2007-09-20 08:37:14.000000000 +0200
+@@ -20,18 +20,28 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_keysym_;
++public import SDL_version_;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+
+ extern(C):
+
+@@ -73,20 +83,3 @@
+ */
+ void SDL_Quit();
+
+-/+
+-void SDL_SetModuleHandle(void *hInst);
+-extern(Windows) void* GetModuleHandle(char*);
+-
+-static this()
+-{
+- /* Load SDL dynamic link library */
+- if (SDL_Init(SDL_INIT_NOPARACHUTE) < 0)
+- throw new Error("Error loading SDL");
+- SDL_SetModuleHandle(GetModuleHandle(null));
+-}
+-
+-static ~this()
+-{
+- SDL_Quit();
+-}
+-+/
+diff -Naur ttp0_2/import/SDL_events.d ttp0_2-gentoo/import/SDL_events.d
+--- ttp0_2/import/SDL_events.d 2005-01-01 13:40:28.000000000 +0100
++++ ttp0_2-gentoo/import/SDL_events.d 2007-09-20 08:37:14.000000000 +0200
+@@ -304,8 +304,8 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() will return the
+ current processing state of the specified event.
+ */
+-const uint SDL_QUERY = cast(uint) -1;
+-const uint SDL_IGNORE = 0;
+-const uint SDL_DISABLE = 0;
+-const uint SDL_ENABLE = 1;
++const int SDL_QUERY = -1;
++const int SDL_IGNORE = 0;
++const int SDL_DISABLE = 0;
++const int SDL_ENABLE = 1;
+ Uint8 SDL_EventState(Uint8 type, int state);
+diff -Naur ttp0_2/import/SDL_keyboard.d ttp0_2-gentoo/import/SDL_keyboard.d
+--- ttp0_2/import/SDL_keyboard.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/import/SDL_keyboard.d 2007-09-20 08:37:14.000000000 +0200
+@@ -26,7 +26,7 @@
+ // !!! A hack! struct SDL_keysym is defined in this module,
+ // !!! so we need to resolve the nameclash...
+ // !!! Definitely won't work on *NIX but for now will do.
+-import SDL_Keysym;
++import SDL_keysym_;
+
+ extern(C):
+
+diff -Naur ttp0_2/import/SDL_keysym_.d ttp0_2-gentoo/import/SDL_keysym_.d
+--- ttp0_2/import/SDL_keysym_.d 1970-01-01 01:00:00.000000000 +0100
++++ ttp0_2-gentoo/import/SDL_keysym_.d 2007-09-20 08:37:14.000000000 +0200
+@@ -0,0 +1,308 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* What we really want is a mapping of every raw key on the keyboard.
++ To support international keyboards, we use the range 0xA1 - 0xFF
++ as international virtual keycodes. We'll follow in the footsteps of X11...
++ The names of the keys
++ */
++
++alias int SDLKey;
++enum {
++ /* The keyboard syms have been cleverly chosen to map to ASCII */
++ SDLK_UNKNOWN = 0,
++ SDLK_FIRST = 0,
++ SDLK_BACKSPACE = 8,
++ SDLK_TAB = 9,
++ SDLK_CLEAR = 12,
++ SDLK_RETURN = 13,
++ SDLK_PAUSE = 19,
++ SDLK_ESCAPE = 27,
++ SDLK_SPACE = 32,
++ SDLK_EXCLAIM = 33,
++ SDLK_QUOTEDBL = 34,
++ SDLK_HASH = 35,
++ SDLK_DOLLAR = 36,
++ SDLK_AMPERSAND = 38,
++ SDLK_QUOTE = 39,
++ SDLK_LEFTPAREN = 40,
++ SDLK_RIGHTPAREN = 41,
++ SDLK_ASTERISK = 42,
++ SDLK_PLUS = 43,
++ SDLK_COMMA = 44,
++ SDLK_MINUS = 45,
++ SDLK_PERIOD = 46,
++ SDLK_SLASH = 47,
++ SDLK_0 = 48,
++ SDLK_1 = 49,
++ SDLK_2 = 50,
++ SDLK_3 = 51,
++ SDLK_4 = 52,
++ SDLK_5 = 53,
++ SDLK_6 = 54,
++ SDLK_7 = 55,
++ SDLK_8 = 56,
++ SDLK_9 = 57,
++ SDLK_COLON = 58,
++ SDLK_SEMICOLON = 59,
++ SDLK_LESS = 60,
++ SDLK_EQUALS = 61,
++ SDLK_GREATER = 62,
++ SDLK_QUESTION = 63,
++ SDLK_AT = 64,
++ /*
++ Skip uppercase letters
++ */
++ SDLK_LEFTBRACKET = 91,
++ SDLK_BACKSLASH = 92,
++ SDLK_RIGHTBRACKET = 93,
++ SDLK_CARET = 94,
++ SDLK_UNDERSCORE = 95,
++ SDLK_BACKQUOTE = 96,
++ SDLK_a = 97,
++ SDLK_b = 98,
++ SDLK_c = 99,
++ SDLK_d = 100,
++ SDLK_e = 101,
++ SDLK_f = 102,
++ SDLK_g = 103,
++ SDLK_h = 104,
++ SDLK_i = 105,
++ SDLK_j = 106,
++ SDLK_k = 107,
++ SDLK_l = 108,
++ SDLK_m = 109,
++ SDLK_n = 110,
++ SDLK_o = 111,
++ SDLK_p = 112,
++ SDLK_q = 113,
++ SDLK_r = 114,
++ SDLK_s = 115,
++ SDLK_t = 116,
++ SDLK_u = 117,
++ SDLK_v = 118,
++ SDLK_w = 119,
++ SDLK_x = 120,
++ SDLK_y = 121,
++ SDLK_z = 122,
++ SDLK_DELETE = 127,
++ /* End of ASCII mapped keysyms */
++
++ /* International keyboard syms */
++ SDLK_WORLD_0 = 160, /* 0xA0 */
++ SDLK_WORLD_1 = 161,
++ SDLK_WORLD_2 = 162,
++ SDLK_WORLD_3 = 163,
++ SDLK_WORLD_4 = 164,
++ SDLK_WORLD_5 = 165,
++ SDLK_WORLD_6 = 166,
++ SDLK_WORLD_7 = 167,
++ SDLK_WORLD_8 = 168,
++ SDLK_WORLD_9 = 169,
++ SDLK_WORLD_10 = 170,
++ SDLK_WORLD_11 = 171,
++ SDLK_WORLD_12 = 172,
++ SDLK_WORLD_13 = 173,
++ SDLK_WORLD_14 = 174,
++ SDLK_WORLD_15 = 175,
++ SDLK_WORLD_16 = 176,
++ SDLK_WORLD_17 = 177,
++ SDLK_WORLD_18 = 178,
++ SDLK_WORLD_19 = 179,
++ SDLK_WORLD_20 = 180,
++ SDLK_WORLD_21 = 181,
++ SDLK_WORLD_22 = 182,
++ SDLK_WORLD_23 = 183,
++ SDLK_WORLD_24 = 184,
++ SDLK_WORLD_25 = 185,
++ SDLK_WORLD_26 = 186,
++ SDLK_WORLD_27 = 187,
++ SDLK_WORLD_28 = 188,
++ SDLK_WORLD_29 = 189,
++ SDLK_WORLD_30 = 190,
++ SDLK_WORLD_31 = 191,
++ SDLK_WORLD_32 = 192,
++ SDLK_WORLD_33 = 193,
++ SDLK_WORLD_34 = 194,
++ SDLK_WORLD_35 = 195,
++ SDLK_WORLD_36 = 196,
++ SDLK_WORLD_37 = 197,
++ SDLK_WORLD_38 = 198,
++ SDLK_WORLD_39 = 199,
++ SDLK_WORLD_40 = 200,
++ SDLK_WORLD_41 = 201,
++ SDLK_WORLD_42 = 202,
++ SDLK_WORLD_43 = 203,
++ SDLK_WORLD_44 = 204,
++ SDLK_WORLD_45 = 205,
++ SDLK_WORLD_46 = 206,
++ SDLK_WORLD_47 = 207,
++ SDLK_WORLD_48 = 208,
++ SDLK_WORLD_49 = 209,
++ SDLK_WORLD_50 = 210,
++ SDLK_WORLD_51 = 211,
++ SDLK_WORLD_52 = 212,
++ SDLK_WORLD_53 = 213,
++ SDLK_WORLD_54 = 214,
++ SDLK_WORLD_55 = 215,
++ SDLK_WORLD_56 = 216,
++ SDLK_WORLD_57 = 217,
++ SDLK_WORLD_58 = 218,
++ SDLK_WORLD_59 = 219,
++ SDLK_WORLD_60 = 220,
++ SDLK_WORLD_61 = 221,
++ SDLK_WORLD_62 = 222,
++ SDLK_WORLD_63 = 223,
++ SDLK_WORLD_64 = 224,
++ SDLK_WORLD_65 = 225,
++ SDLK_WORLD_66 = 226,
++ SDLK_WORLD_67 = 227,
++ SDLK_WORLD_68 = 228,
++ SDLK_WORLD_69 = 229,
++ SDLK_WORLD_70 = 230,
++ SDLK_WORLD_71 = 231,
++ SDLK_WORLD_72 = 232,
++ SDLK_WORLD_73 = 233,
++ SDLK_WORLD_74 = 234,
++ SDLK_WORLD_75 = 235,
++ SDLK_WORLD_76 = 236,
++ SDLK_WORLD_77 = 237,
++ SDLK_WORLD_78 = 238,
++ SDLK_WORLD_79 = 239,
++ SDLK_WORLD_80 = 240,
++ SDLK_WORLD_81 = 241,
++ SDLK_WORLD_82 = 242,
++ SDLK_WORLD_83 = 243,
++ SDLK_WORLD_84 = 244,
++ SDLK_WORLD_85 = 245,
++ SDLK_WORLD_86 = 246,
++ SDLK_WORLD_87 = 247,
++ SDLK_WORLD_88 = 248,
++ SDLK_WORLD_89 = 249,
++ SDLK_WORLD_90 = 250,
++ SDLK_WORLD_91 = 251,
++ SDLK_WORLD_92 = 252,
++ SDLK_WORLD_93 = 253,
++ SDLK_WORLD_94 = 254,
++ SDLK_WORLD_95 = 255, /* 0xFF */
++
++ /* Numeric keypad */
++ SDLK_KP0 = 256,
++ SDLK_KP1 = 257,
++ SDLK_KP2 = 258,
++ SDLK_KP3 = 259,
++ SDLK_KP4 = 260,
++ SDLK_KP5 = 261,
++ SDLK_KP6 = 262,
++ SDLK_KP7 = 263,
++ SDLK_KP8 = 264,
++ SDLK_KP9 = 265,
++ SDLK_KP_PERIOD = 266,
++ SDLK_KP_DIVIDE = 267,
++ SDLK_KP_MULTIPLY = 268,
++ SDLK_KP_MINUS = 269,
++ SDLK_KP_PLUS = 270,
++ SDLK_KP_ENTER = 271,
++ SDLK_KP_EQUALS = 272,
++
++ /* Arrows + Home/End pad */
++ SDLK_UP = 273,
++ SDLK_DOWN = 274,
++ SDLK_RIGHT = 275,
++ SDLK_LEFT = 276,
++ SDLK_INSERT = 277,
++ SDLK_HOME = 278,
++ SDLK_END = 279,
++ SDLK_PAGEUP = 280,
++ SDLK_PAGEDOWN = 281,
++
++ /* Function keys */
++ SDLK_F1 = 282,
++ SDLK_F2 = 283,
++ SDLK_F3 = 284,
++ SDLK_F4 = 285,
++ SDLK_F5 = 286,
++ SDLK_F6 = 287,
++ SDLK_F7 = 288,
++ SDLK_F8 = 289,
++ SDLK_F9 = 290,
++ SDLK_F10 = 291,
++ SDLK_F11 = 292,
++ SDLK_F12 = 293,
++ SDLK_F13 = 294,
++ SDLK_F14 = 295,
++ SDLK_F15 = 296,
++
++ /* Key state modifier keys */
++ SDLK_NUMLOCK = 300,
++ SDLK_CAPSLOCK = 301,
++ SDLK_SCROLLOCK = 302,
++ SDLK_RSHIFT = 303,
++ SDLK_LSHIFT = 304,
++ SDLK_RCTRL = 305,
++ SDLK_LCTRL = 306,
++ SDLK_RALT = 307,
++ SDLK_LALT = 308,
++ SDLK_RMETA = 309,
++ SDLK_LMETA = 310,
++ SDLK_LSUPER = 311, /* Left "Windows" key */
++ SDLK_RSUPER = 312, /* Right "Windows" key */
++ SDLK_MODE = 313, /* "Alt Gr" key */
++ SDLK_COMPOSE = 314, /* Multi-key compose key */
++
++ /* Miscellaneous function keys */
++ SDLK_HELP = 315,
++ SDLK_PRINT = 316,
++ SDLK_SYSREQ = 317,
++ SDLK_BREAK = 318,
++ SDLK_MENU = 319,
++ SDLK_POWER = 320, /* Power Macintosh power key */
++ SDLK_EURO = 321, /* Some european keyboards */
++ SDLK_UNDO = 322, /* Atari keyboard has Undo */
++
++ /* Add any other keys here */
++
++ SDLK_LAST
++}
++
++/* Enumeration of valid key mods (possibly OR'd together) */
++alias int SDLMod;
++enum {
++ KMOD_NONE = 0x0000,
++ KMOD_LSHIFT= 0x0001,
++ KMOD_RSHIFT= 0x0002,
++ KMOD_LCTRL = 0x0040,
++ KMOD_RCTRL = 0x0080,
++ KMOD_LALT = 0x0100,
++ KMOD_RALT = 0x0200,
++ KMOD_LMETA = 0x0400,
++ KMOD_RMETA = 0x0800,
++ KMOD_NUM = 0x1000,
++ KMOD_CAPS = 0x2000,
++ KMOD_MODE = 0x4000,
++ KMOD_RESERVED = 0x8000
++}
++
++const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
++const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
++const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
++const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur ttp0_2/import/SDL_mixer.d ttp0_2-gentoo/import/SDL_mixer.d
+--- ttp0_2/import/SDL_mixer.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/import/SDL_mixer.d 2007-09-20 08:37:14.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ // convert to D by shinichiro.h
+
+-/* $Id: SDL_mixer.d,v 1.1.1.1 2004/11/10 13:45:22 kenta Exp $ */
++/* $Id: SDL_mixer.d,v 1.1.1.1 2006/11/19 07:54:54 kenta Exp $ */
+
+ import SDL;
+
+diff -Naur ttp0_2/import/SDL_syswm.d ttp0_2-gentoo/import/SDL_syswm.d
+--- ttp0_2/import/SDL_syswm.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/import/SDL_syswm.d 2007-09-20 08:37:14.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-import SDL_Version;
++import SDL_version_;
+
+ extern(C):
+
+diff -Naur ttp0_2/import/SDL_version_.d ttp0_2-gentoo/import/SDL_version_.d
+--- ttp0_2/import/SDL_version_.d 1970-01-01 01:00:00.000000000 +0100
++++ ttp0_2-gentoo/import/SDL_version_.d 2007-09-20 08:37:14.000000000 +0200
+@@ -0,0 +1,75 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* This header defines the current SDL version */
++
++import SDL_types;
++
++extern(C):
++
++/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
++*/
++const uint SDL_MAJOR_VERSION = 1;
++const uint SDL_MINOR_VERSION = 2;
++const uint SDL_PATCHLEVEL = 6;
++
++struct SDL_version {
++ Uint8 major;
++ Uint8 minor;
++ Uint8 patch;
++}
++
++/* This macro can be used to fill a version structure with the compile-time
++ * version of the SDL library.
++ */
++void SDL_VERSION(SDL_version* X)
++{
++ X.major = SDL_MAJOR_VERSION;
++ X.minor = SDL_MINOR_VERSION;
++ X.patch = SDL_PATCHLEVEL;
++}
++
++/* This macro turns the version numbers into a numeric value:
++ (1,2,3) -> (1203)
++ This assumes that there will never be more than 100 patchlevels
++*/
++uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return X * 1000 + Y * 100 + Z;
++}
++
++/* This is the version number macro for the current SDL version */
++const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
++ SDL_MINOR_VERSION * 100 +
++ SDL_PATCHLEVEL;
++
++/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
++bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
++}
++
++/* This function gets the version of the dynamically linked SDL library.
++ it should NOT be used to fill a version structure, instead you should
++ use the SDL_Version() macro.
++ */
++SDL_version * SDL_Linked_Version();
+diff -Naur ttp0_2/Makefile ttp0_2-gentoo/Makefile
+--- ttp0_2/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ ttp0_2-gentoo/Makefile 2007-09-20 08:37:14.000000000 +0200
+@@ -0,0 +1,27 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-O -d -release -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -frelease -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/ -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=torustrooperpure
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer -lstdc++
++
++$(OBJS): %.o: %.d
++ $(DC) -c $(DOUT)$@ $(DFLAGS) $<
++
++
++
+diff -Naur ttp0_2/src/abagames/tt/barrage.d ttp0_2-gentoo/src/abagames/tt/barrage.d
+--- ttp0_2/src/abagames/tt/barrage.d 2006-04-22 09:42:59.000000000 +0200
++++ ttp0_2-gentoo/src/abagames/tt/barrage.d 2007-09-20 08:37:14.000000000 +0200
+@@ -30,12 +30,13 @@
+ int prevWait, postWait;
+ bool noXReverse = false;
+
+- public static this() {
++ public static void randInit() {
+ rand = new Rand;
+ if(rand==null){}
+ }
+
+ public static void setRandSeed(long seed) {
++ if (!rand) rand = new Rand;
+ rand.setSeed(seed);
+ }
+
+@@ -94,6 +95,7 @@
+ public class BarrageManager {
+ private:
+ static BulletMLParserTinyXML *parser[char[]][char[]];
++ static BulletMLParserTinyXML *parser2[char[]];
+ static const char[] BARRAGE_DIR_NAME = "barrage";
+
+ public static void load() {
+@@ -103,20 +105,21 @@
+ foreach (char[] fileName; files) {
+ if (getExt(fileName) != "xml")
+ continue;
+- parser[dirName][fileName] = getInstance(dirName, fileName);
++ char[] barrageName = dirName ~ "/" ~ fileName;
++ parser2[barrageName] = getInstance(dirName, fileName);
+ }
+ }
+ }
+
+ public static BulletMLParserTinyXML* getInstance(char[] dirName, char[] fileName) {
+- if (!parser[dirName][fileName]) {
+ char[] barrageName = dirName ~ "/" ~ fileName;
++ if (!parser2[barrageName]) {
+ Logger.info("Load BulletML: " ~ barrageName);
+- parser[dirName][fileName] =
++ parser2[barrageName] =
+ BulletMLParserTinyXML_new(std.string.toStringz(BARRAGE_DIR_NAME ~ "/" ~ barrageName));
+- BulletMLParserTinyXML_parse(parser[dirName][fileName]);
++ BulletMLParserTinyXML_parse(parser2[barrageName]);
+ }
+- return parser[dirName][fileName];
++ return parser2[barrageName];
+ }
+
+ public static BulletMLParserTinyXML*[] getInstanceList(char[] dirName) {
+diff -Naur ttp0_2/src/abagames/tt/enemy.d ttp0_2-gentoo/src/abagames/tt/enemy.d
+--- ttp0_2/src/abagames/tt/enemy.d 2006-04-24 09:30:44.000000000 +0200
++++ ttp0_2-gentoo/src/abagames/tt/enemy.d 2007-09-20 08:37:14.000000000 +0200
+@@ -61,6 +61,9 @@
+
+ public static this() {
+ rand = new Rand;
++ ShipShape.randInit();
++ Particle.randInit();
++ Barrage.randInit();
+ }
+
+ public static void setRandSeed(long seed) {
+diff -Naur ttp0_2/src/abagames/tt/particle.d ttp0_2-gentoo/src/abagames/tt/particle.d
+--- ttp0_2/src/abagames/tt/particle.d 2005-01-01 13:40:28.000000000 +0100
++++ ttp0_2-gentoo/src/abagames/tt/particle.d 2007-09-20 08:37:14.000000000 +0200
+@@ -42,7 +42,7 @@
+ float d1, d2, md1, md2;
+ float width, height;
+
+- public static this() {
++ public static void randInit() {
+ rand = new Rand;
+ }
+
+diff -Naur ttp0_2/src/abagames/tt/shape.d ttp0_2-gentoo/src/abagames/tt/shape.d
+--- ttp0_2/src/abagames/tt/shape.d 2006-04-24 11:25:14.000000000 +0200
++++ ttp0_2-gentoo/src/abagames/tt/shape.d 2007-09-20 08:37:14.000000000 +0200
+@@ -66,7 +66,7 @@
+ Vector rocketPos, fragmentPos;
+ int color;
+
+- static this() {
++ public static void randInit() {
+ rand = new Rand;
+ }
+
+diff -Naur ttp0_2/src/abagames/tt/stagemanager.d ttp0_2-gentoo/src/abagames/tt/stagemanager.d
+--- ttp0_2/src/abagames/tt/stagemanager.d 2006-04-22 09:17:55.000000000 +0200
++++ ttp0_2-gentoo/src/abagames/tt/stagemanager.d 2007-09-20 08:37:14.000000000 +0200
+@@ -435,25 +435,25 @@
+ br.setLongRange(longRange);
+ BulletMLParserTinyXML*[] ps;
+ int psn;
+- if (baseDir) {
+- ps = BarrageManager.getInstanceList(baseDir);
+- int pi = rand.nextInt(ps.length);
+- br.addBml(ps[pi], rank, true, speedRank);
+- } else {
++ // if (baseDir) {
++ // ps = BarrageManager.getInstanceList(baseDir);
++ // int pi = rand.nextInt(ps.length);
++ // br.addBml(ps[pi], rank, true, speedRank);
++ // } else {
+ br.addBml("basic", "straight.xml", rank, true, speedRank);
+- }
+- ps = BarrageManager.getInstanceList("morph");
+- psn = ps.length;
++ // }
++ // ps = BarrageManager.getInstanceList("morph");
++ psn = 13;
+ for (int i = 0; i < morphCnt; i++) {
+- int pi = rand.nextInt(ps.length);
+- while (!ps[pi]) {
+- pi--;
++ int pi = rand.nextInt(13);
++ // while (!ps[pi]) {
++ // pi--;
+ if (pi < 0)
+- pi = ps.length - 1;
+- }
+- br.addBml(ps[pi], morphRank, true, speedRank);
+- delete ps[pi];
+- psn--;
++ pi = 13 - 1;
++ // }
++ // br.addBml(ps[pi], morphRank, true, speedRank);
++ // delete ps[pi];
++ // psn--;
+ }
+ return br;
+ }
+diff -Naur ttp0_2/src/abagames/util/logger.d ttp0_2-gentoo/src/abagames/util/logger.d
+--- ttp0_2/src/abagames/util/logger.d 2004-11-10 14:45:22.000000000 +0100
++++ ttp0_2-gentoo/src/abagames/util/logger.d 2007-09-20 08:37:14.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.util.logger;
+
+-private import std.stream;
++private import std.cstream;
+ private import std.string;
+
+ /**
+@@ -56,28 +56,28 @@
+
+ public static void info(char[] msg, bool nline = true) {
+ if (nline)
+- stderr.writeLine(msg);
++ derr.writeLine(msg);
+ else
+- stderr.writeString(msg);
++ derr.writeString(msg);
+ }
+
+ public static void info(double n, bool nline = true) {
+ if (nline)
+- stderr.writeLine(std.string.toString(n));
++ derr.writeLine(std.string.toString(n));
+ else
+- stderr.writeString(std.string.toString(n) ~ " ");
++ derr.writeString(std.string.toString(n) ~ " ");
+ }
+
+ public static void error(char[] msg) {
+- stderr.writeLine("Error: " ~ msg);
++ derr.writeLine("Error: " ~ msg);
+ }
+
+ public static void error(Exception e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ derr.writeLine("Error: " ~ e.toString());
+ }
+
+ public static void error(Error e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ derr.writeLine("Error: " ~ e.toString());
+ if (e.next)
+ error(e.next);
+ }
+diff -Naur ttp0_2/src/abagames/util/sdl/luminous.d ttp0_2-gentoo/src/abagames/util/sdl/luminous.d
+--- ttp0_2/src/abagames/util/sdl/luminous.d 2005-01-01 13:40:28.000000000 +0100
++++ ttp0_2-gentoo/src/abagames/util/sdl/luminous.d 2007-09-20 08:37:14.000000000 +0200
+@@ -6,7 +6,7 @@
+ module abagames.util.sdl.luminous;
+
+ private import std.math;
+-private import std.string;
++private import std.c.string;
+ private import opengl;
+ private import abagames.util.actor;
+
diff --git a/games-action/torustrooperpure/files/torustrooperpure.png b/games-action/torustrooperpure/files/torustrooperpure.png
new file mode 100644
index 0000000..9d607fc
--- /dev/null
+++ b/games-action/torustrooperpure/files/torustrooperpure.png
Binary files differ
diff --git a/games-action/torustrooperpure/metadata.xml b/games-action/torustrooperpure/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/torustrooperpure/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/torustrooperpure/torustrooperpure-0.2.ebuild b/games-action/torustrooperpure/torustrooperpure-0.2.ebuild
new file mode 100644
index 0000000..b9dca39
--- /dev/null
+++ b/games-action/torustrooperpure/torustrooperpure-0.2.ebuild
@@ -0,0 +1,62 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=ttp
+MY_PV=${PV//./_}
+
+DESCRIPTION="Brake down and Burn up! original:Torus Trooper (ABA)"
+HOMEPAGE="http://www.mb.ccnw.ne.jp/hiz/game/tt/index_en.html"
+SRC_URI="http://www.mb.ccnw.ne.jp/hiz/game/tt//${MY_PN}${MY_PV}.zip"
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}${MY_PV}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(images/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/texture.d \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(barrage[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tt/barrage.d \
+ -e 's:"\(tt.prf[^"]*\)":"'${GAMES_STATEDIR}'/'${PN}'/\1":g' -i src/abagames/tt/prefmanager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ dodir "${GAMES_STATEDIR}/${PN}" "${GAMES_STATEDIR}/${PN}/replay"
+ local statedir="${GAMES_STATEDIR}"/${PN}
+
+ if [ ! -e ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf ]; then
+ touch ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf
+ chmod ug+rw ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf
+ fperms 660 ${D}"${GAMES_STATEDIR}"/${PN}/tt.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r barrage images sounds || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ games_pkg_postinst
+}
diff --git a/games-action/tumikifighters/Manifest b/games-action/tumikifighters/Manifest
new file mode 100644
index 0000000..7169b63
--- /dev/null
+++ b/games-action/tumikifighters/Manifest
@@ -0,0 +1,5 @@
+AUX tumikifighters-0.2.diff 37502 RMD160 c2a01084cefe183cb1f9b955d3ba4bcc05c33779 SHA1 d6aafbc06db2e79d9397ffd7b782d42dcb09e24a SHA256 ac68eef44c3ca1dcfaa61d6f28a5c560e8f3f798416aceaf0325a48dada64036
+AUX tumikifighters.png 2198 RMD160 ad8bed670a9620f7fbb09f8dda0974141669121c SHA1 1b49cec6a7f1a506253fe9f141ebe479261c0b24 SHA256 f77ecdb7d747836130985aa1eaf2f69a5ace60cf9999e85f135b7864aa8abf73
+DIST tf0_2.zip 5278017 RMD160 68d81ea4c70b2f596e16c6638271003cd4554c2a SHA1 42ab2b2af38f9e7ec71051713f172407f00e2a63 SHA256 dd2f7f793acb5a38da58632041a07d7cd09717dfb7450dfc973638a68f2a5f22
+EBUILD tumikifighters-0.2.ebuild 1820 RMD160 b18515002b4acff6dc837922cdb594ec8597d010 SHA1 da6f2831598080b63cdd3ac0c7af902a0dee8878 SHA256 8f2bfd454aac2561b0a5da6f6035b86b9f796ec694f732efd691f90b2db43a8c
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/tumikifighters/files/digest-tumikifighters-0.2 b/games-action/tumikifighters/files/digest-tumikifighters-0.2
new file mode 100644
index 0000000..584fc12
--- /dev/null
+++ b/games-action/tumikifighters/files/digest-tumikifighters-0.2
@@ -0,0 +1,3 @@
+MD5 ff68363954f256c30fb4e15636a824be tf0_2.zip 5278017
+RMD160 68d81ea4c70b2f596e16c6638271003cd4554c2a tf0_2.zip 5278017
+SHA256 dd2f7f793acb5a38da58632041a07d7cd09717dfb7450dfc973638a68f2a5f22 tf0_2.zip 5278017
diff --git a/games-action/tumikifighters/files/tumikifighters-0.2.diff b/games-action/tumikifighters/files/tumikifighters-0.2.diff
new file mode 100644
index 0000000..96bdaaa
--- /dev/null
+++ b/games-action/tumikifighters/files/tumikifighters-0.2.diff
@@ -0,0 +1,1285 @@
+diff -Naur tf/import/opengl.d tf-gentoo/import/opengl.d
+--- tf/import/opengl.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/opengl.d 2007-09-19 22:08:36.000000000 +0200
+@@ -1,10 +1,6 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
++
+ extern(C):
+-}
++
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -1116,7 +1112,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1365,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur tf/import/openglu.d tf-gentoo/import/openglu.d
+--- tf/import/openglu.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/openglu.d 2007-09-19 22:08:22.000000000 +0200
+@@ -1,11 +1,6 @@
+-import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
++
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur tf/import/SDL.d tf-gentoo/import/SDL.d
+--- tf/import/SDL.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL.d 2007-09-19 22:07:12.000000000 +0200
+@@ -20,18 +20,21 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_version_;
++public import SDL_types;
++public import SDL_getenv;
++public import SDL_error;
++public import SDL_rwops;
++public import SDL_timer;
++public import SDL_audio;
++public import SDL_cdrom;
++public import SDL_joystick;
++public import SDL_events;
++public import SDL_video;
++public import SDL_byteorder;
++public import SDL_Version;
++public import SDL_Keysym;
++public import SDL_mouse;
++public import SDL_keyboard;
+
+ extern(C):
+
+@@ -73,6 +76,7 @@
+ */
+ void SDL_Quit();
+
++/+
+ void SDL_SetModuleHandle(void *hInst);
+ extern(Windows) void* GetModuleHandle(char*);
+
+@@ -88,3 +92,4 @@
+ {
+ SDL_Quit();
+ }
+++/
+diff -Naur tf/import/SDL_endian.d tf-gentoo/import/SDL_endian.d
+--- tf/import/SDL_endian.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_endian.d 2007-09-19 22:07:12.000000000 +0200
+@@ -57,9 +57,9 @@
+ Uint64 SDL_Swap64(Uint64 val) {
+ Uint32 hi, lo;
+ /* Separate into high and low 32-bit values and swap them */
+- lo = (Uint32)(val&0xFFFFFFFF);
++ lo = cast(Uint32)(val&0xFFFFFFFF);
+ val >>= 32;
+- hi = (Uint32)(val&0xFFFFFFFF);
++ hi = cast(Uint32)(val&0xFFFFFFFF);
+ val = SDL_Swap32(lo);
+ val <<= 32;
+ val |= SDL_Swap32(hi);
+diff -Naur tf/import/SDL_events.d tf-gentoo/import/SDL_events.d
+--- tf/import/SDL_events.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_events.d 2007-09-19 22:07:12.000000000 +0200
+@@ -304,7 +304,7 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() will return the
+ current processing state of the specified event.
+ */
+-const uint SDL_QUERY = -1;
++const uint SDL_QUERY = cast(uint) -1;
+ const uint SDL_IGNORE = 0;
+ const uint SDL_DISABLE = 0;
+ const uint SDL_ENABLE = 1;
+diff -Naur tf/import/SDL_getenv.d tf-gentoo/import/SDL_getenv.d
+--- tf/import/SDL_getenv.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_getenv.d 2007-09-19 22:07:12.000000000 +0200
+@@ -2,6 +2,7 @@
+
+ extern(C):
+
++/+
+ /* Put a variable of the form "name=value" into the environment */
+ int SDL_putenv(char *variable);
+ int putenv(char* X) { return SDL_putenv(X); }
+@@ -9,3 +10,4 @@
+ /* Retrieve a variable named "name" from the environment */
+ char *SDL_getenv(char *name);
+ char *getenv(char* X) { return SDL_getenv(X); }
+++/
+diff -Naur tf/import/SDL_keyboard.d tf-gentoo/import/SDL_keyboard.d
+--- tf/import/SDL_keyboard.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_keyboard.d 2007-09-19 22:07:12.000000000 +0200
+@@ -26,7 +26,7 @@
+ // !!! A hack! struct SDL_keysym is defined in this module,
+ // !!! so we need to resolve the nameclash...
+ // !!! Definitely won't work on *NIX but for now will do.
+-import SDL_keysym_;
++import SDL_Keysym;
+
+ extern(C):
+
+diff -Naur tf/import/SDL_keysym_.d tf-gentoo/import/SDL_keysym_.d
+--- tf/import/SDL_keysym_.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_keysym_.d 1970-01-01 01:00:00.000000000 +0100
+@@ -1,308 +0,0 @@
+-/*
+- SDL - Simple DirectMedia Layer
+- Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
+-
+- This library is free software; you can redistribute it and/or
+- modify it under the terms of the GNU Library General Public
+- License as published by the Free Software Foundation; either
+- version 2 of the License, or (at your option) any later version.
+-
+- This library is distributed in the hope that it will be useful,
+- but WITHOUT ANY WARRANTY; without even the implied warranty of
+- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+- Library General Public License for more details.
+-
+- You should have received a copy of the GNU Library General Public
+- License along with this library; if not, write to the Free
+- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+-
+- Sam Lantinga
+- slouken@devolution.com
+-*/
+-
+-/* What we really want is a mapping of every raw key on the keyboard.
+- To support international keyboards, we use the range 0xA1 - 0xFF
+- as international virtual keycodes. We'll follow in the footsteps of X11...
+- The names of the keys
+- */
+-
+-alias int SDLKey;
+-enum {
+- /* The keyboard syms have been cleverly chosen to map to ASCII */
+- SDLK_UNKNOWN = 0,
+- SDLK_FIRST = 0,
+- SDLK_BACKSPACE = 8,
+- SDLK_TAB = 9,
+- SDLK_CLEAR = 12,
+- SDLK_RETURN = 13,
+- SDLK_PAUSE = 19,
+- SDLK_ESCAPE = 27,
+- SDLK_SPACE = 32,
+- SDLK_EXCLAIM = 33,
+- SDLK_QUOTEDBL = 34,
+- SDLK_HASH = 35,
+- SDLK_DOLLAR = 36,
+- SDLK_AMPERSAND = 38,
+- SDLK_QUOTE = 39,
+- SDLK_LEFTPAREN = 40,
+- SDLK_RIGHTPAREN = 41,
+- SDLK_ASTERISK = 42,
+- SDLK_PLUS = 43,
+- SDLK_COMMA = 44,
+- SDLK_MINUS = 45,
+- SDLK_PERIOD = 46,
+- SDLK_SLASH = 47,
+- SDLK_0 = 48,
+- SDLK_1 = 49,
+- SDLK_2 = 50,
+- SDLK_3 = 51,
+- SDLK_4 = 52,
+- SDLK_5 = 53,
+- SDLK_6 = 54,
+- SDLK_7 = 55,
+- SDLK_8 = 56,
+- SDLK_9 = 57,
+- SDLK_COLON = 58,
+- SDLK_SEMICOLON = 59,
+- SDLK_LESS = 60,
+- SDLK_EQUALS = 61,
+- SDLK_GREATER = 62,
+- SDLK_QUESTION = 63,
+- SDLK_AT = 64,
+- /*
+- Skip uppercase letters
+- */
+- SDLK_LEFTBRACKET = 91,
+- SDLK_BACKSLASH = 92,
+- SDLK_RIGHTBRACKET = 93,
+- SDLK_CARET = 94,
+- SDLK_UNDERSCORE = 95,
+- SDLK_BACKQUOTE = 96,
+- SDLK_a = 97,
+- SDLK_b = 98,
+- SDLK_c = 99,
+- SDLK_d = 100,
+- SDLK_e = 101,
+- SDLK_f = 102,
+- SDLK_g = 103,
+- SDLK_h = 104,
+- SDLK_i = 105,
+- SDLK_j = 106,
+- SDLK_k = 107,
+- SDLK_l = 108,
+- SDLK_m = 109,
+- SDLK_n = 110,
+- SDLK_o = 111,
+- SDLK_p = 112,
+- SDLK_q = 113,
+- SDLK_r = 114,
+- SDLK_s = 115,
+- SDLK_t = 116,
+- SDLK_u = 117,
+- SDLK_v = 118,
+- SDLK_w = 119,
+- SDLK_x = 120,
+- SDLK_y = 121,
+- SDLK_z = 122,
+- SDLK_DELETE = 127,
+- /* End of ASCII mapped keysyms */
+-
+- /* International keyboard syms */
+- SDLK_WORLD_0 = 160, /* 0xA0 */
+- SDLK_WORLD_1 = 161,
+- SDLK_WORLD_2 = 162,
+- SDLK_WORLD_3 = 163,
+- SDLK_WORLD_4 = 164,
+- SDLK_WORLD_5 = 165,
+- SDLK_WORLD_6 = 166,
+- SDLK_WORLD_7 = 167,
+- SDLK_WORLD_8 = 168,
+- SDLK_WORLD_9 = 169,
+- SDLK_WORLD_10 = 170,
+- SDLK_WORLD_11 = 171,
+- SDLK_WORLD_12 = 172,
+- SDLK_WORLD_13 = 173,
+- SDLK_WORLD_14 = 174,
+- SDLK_WORLD_15 = 175,
+- SDLK_WORLD_16 = 176,
+- SDLK_WORLD_17 = 177,
+- SDLK_WORLD_18 = 178,
+- SDLK_WORLD_19 = 179,
+- SDLK_WORLD_20 = 180,
+- SDLK_WORLD_21 = 181,
+- SDLK_WORLD_22 = 182,
+- SDLK_WORLD_23 = 183,
+- SDLK_WORLD_24 = 184,
+- SDLK_WORLD_25 = 185,
+- SDLK_WORLD_26 = 186,
+- SDLK_WORLD_27 = 187,
+- SDLK_WORLD_28 = 188,
+- SDLK_WORLD_29 = 189,
+- SDLK_WORLD_30 = 190,
+- SDLK_WORLD_31 = 191,
+- SDLK_WORLD_32 = 192,
+- SDLK_WORLD_33 = 193,
+- SDLK_WORLD_34 = 194,
+- SDLK_WORLD_35 = 195,
+- SDLK_WORLD_36 = 196,
+- SDLK_WORLD_37 = 197,
+- SDLK_WORLD_38 = 198,
+- SDLK_WORLD_39 = 199,
+- SDLK_WORLD_40 = 200,
+- SDLK_WORLD_41 = 201,
+- SDLK_WORLD_42 = 202,
+- SDLK_WORLD_43 = 203,
+- SDLK_WORLD_44 = 204,
+- SDLK_WORLD_45 = 205,
+- SDLK_WORLD_46 = 206,
+- SDLK_WORLD_47 = 207,
+- SDLK_WORLD_48 = 208,
+- SDLK_WORLD_49 = 209,
+- SDLK_WORLD_50 = 210,
+- SDLK_WORLD_51 = 211,
+- SDLK_WORLD_52 = 212,
+- SDLK_WORLD_53 = 213,
+- SDLK_WORLD_54 = 214,
+- SDLK_WORLD_55 = 215,
+- SDLK_WORLD_56 = 216,
+- SDLK_WORLD_57 = 217,
+- SDLK_WORLD_58 = 218,
+- SDLK_WORLD_59 = 219,
+- SDLK_WORLD_60 = 220,
+- SDLK_WORLD_61 = 221,
+- SDLK_WORLD_62 = 222,
+- SDLK_WORLD_63 = 223,
+- SDLK_WORLD_64 = 224,
+- SDLK_WORLD_65 = 225,
+- SDLK_WORLD_66 = 226,
+- SDLK_WORLD_67 = 227,
+- SDLK_WORLD_68 = 228,
+- SDLK_WORLD_69 = 229,
+- SDLK_WORLD_70 = 230,
+- SDLK_WORLD_71 = 231,
+- SDLK_WORLD_72 = 232,
+- SDLK_WORLD_73 = 233,
+- SDLK_WORLD_74 = 234,
+- SDLK_WORLD_75 = 235,
+- SDLK_WORLD_76 = 236,
+- SDLK_WORLD_77 = 237,
+- SDLK_WORLD_78 = 238,
+- SDLK_WORLD_79 = 239,
+- SDLK_WORLD_80 = 240,
+- SDLK_WORLD_81 = 241,
+- SDLK_WORLD_82 = 242,
+- SDLK_WORLD_83 = 243,
+- SDLK_WORLD_84 = 244,
+- SDLK_WORLD_85 = 245,
+- SDLK_WORLD_86 = 246,
+- SDLK_WORLD_87 = 247,
+- SDLK_WORLD_88 = 248,
+- SDLK_WORLD_89 = 249,
+- SDLK_WORLD_90 = 250,
+- SDLK_WORLD_91 = 251,
+- SDLK_WORLD_92 = 252,
+- SDLK_WORLD_93 = 253,
+- SDLK_WORLD_94 = 254,
+- SDLK_WORLD_95 = 255, /* 0xFF */
+-
+- /* Numeric keypad */
+- SDLK_KP0 = 256,
+- SDLK_KP1 = 257,
+- SDLK_KP2 = 258,
+- SDLK_KP3 = 259,
+- SDLK_KP4 = 260,
+- SDLK_KP5 = 261,
+- SDLK_KP6 = 262,
+- SDLK_KP7 = 263,
+- SDLK_KP8 = 264,
+- SDLK_KP9 = 265,
+- SDLK_KP_PERIOD = 266,
+- SDLK_KP_DIVIDE = 267,
+- SDLK_KP_MULTIPLY = 268,
+- SDLK_KP_MINUS = 269,
+- SDLK_KP_PLUS = 270,
+- SDLK_KP_ENTER = 271,
+- SDLK_KP_EQUALS = 272,
+-
+- /* Arrows + Home/End pad */
+- SDLK_UP = 273,
+- SDLK_DOWN = 274,
+- SDLK_RIGHT = 275,
+- SDLK_LEFT = 276,
+- SDLK_INSERT = 277,
+- SDLK_HOME = 278,
+- SDLK_END = 279,
+- SDLK_PAGEUP = 280,
+- SDLK_PAGEDOWN = 281,
+-
+- /* Function keys */
+- SDLK_F1 = 282,
+- SDLK_F2 = 283,
+- SDLK_F3 = 284,
+- SDLK_F4 = 285,
+- SDLK_F5 = 286,
+- SDLK_F6 = 287,
+- SDLK_F7 = 288,
+- SDLK_F8 = 289,
+- SDLK_F9 = 290,
+- SDLK_F10 = 291,
+- SDLK_F11 = 292,
+- SDLK_F12 = 293,
+- SDLK_F13 = 294,
+- SDLK_F14 = 295,
+- SDLK_F15 = 296,
+-
+- /* Key state modifier keys */
+- SDLK_NUMLOCK = 300,
+- SDLK_CAPSLOCK = 301,
+- SDLK_SCROLLOCK = 302,
+- SDLK_RSHIFT = 303,
+- SDLK_LSHIFT = 304,
+- SDLK_RCTRL = 305,
+- SDLK_LCTRL = 306,
+- SDLK_RALT = 307,
+- SDLK_LALT = 308,
+- SDLK_RMETA = 309,
+- SDLK_LMETA = 310,
+- SDLK_LSUPER = 311, /* Left "Windows" key */
+- SDLK_RSUPER = 312, /* Right "Windows" key */
+- SDLK_MODE = 313, /* "Alt Gr" key */
+- SDLK_COMPOSE = 314, /* Multi-key compose key */
+-
+- /* Miscellaneous function keys */
+- SDLK_HELP = 315,
+- SDLK_PRINT = 316,
+- SDLK_SYSREQ = 317,
+- SDLK_BREAK = 318,
+- SDLK_MENU = 319,
+- SDLK_POWER = 320, /* Power Macintosh power key */
+- SDLK_EURO = 321, /* Some european keyboards */
+- SDLK_UNDO = 322, /* Atari keyboard has Undo */
+-
+- /* Add any other keys here */
+-
+- SDLK_LAST
+-}
+-
+-/* Enumeration of valid key mods (possibly OR'd together) */
+-alias int SDLMod;
+-enum {
+- KMOD_NONE = 0x0000,
+- KMOD_LSHIFT= 0x0001,
+- KMOD_RSHIFT= 0x0002,
+- KMOD_LCTRL = 0x0040,
+- KMOD_RCTRL = 0x0080,
+- KMOD_LALT = 0x0100,
+- KMOD_RALT = 0x0200,
+- KMOD_LMETA = 0x0400,
+- KMOD_RMETA = 0x0800,
+- KMOD_NUM = 0x1000,
+- KMOD_CAPS = 0x2000,
+- KMOD_MODE = 0x4000,
+- KMOD_RESERVED = 0x8000
+-}
+-
+-const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
+-const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
+-const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
+-const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur tf/import/SDL_Keysym.d tf-gentoo/import/SDL_Keysym.d
+--- tf/import/SDL_Keysym.d 1970-01-01 01:00:00.000000000 +0100
++++ tf-gentoo/import/SDL_Keysym.d 2007-09-19 22:07:12.000000000 +0200
+@@ -0,0 +1,308 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* What we really want is a mapping of every raw key on the keyboard.
++ To support international keyboards, we use the range 0xA1 - 0xFF
++ as international virtual keycodes. We'll follow in the footsteps of X11...
++ The names of the keys
++ */
++
++alias int SDLKey;
++enum {
++ /* The keyboard syms have been cleverly chosen to map to ASCII */
++ SDLK_UNKNOWN = 0,
++ SDLK_FIRST = 0,
++ SDLK_BACKSPACE = 8,
++ SDLK_TAB = 9,
++ SDLK_CLEAR = 12,
++ SDLK_RETURN = 13,
++ SDLK_PAUSE = 19,
++ SDLK_ESCAPE = 27,
++ SDLK_SPACE = 32,
++ SDLK_EXCLAIM = 33,
++ SDLK_QUOTEDBL = 34,
++ SDLK_HASH = 35,
++ SDLK_DOLLAR = 36,
++ SDLK_AMPERSAND = 38,
++ SDLK_QUOTE = 39,
++ SDLK_LEFTPAREN = 40,
++ SDLK_RIGHTPAREN = 41,
++ SDLK_ASTERISK = 42,
++ SDLK_PLUS = 43,
++ SDLK_COMMA = 44,
++ SDLK_MINUS = 45,
++ SDLK_PERIOD = 46,
++ SDLK_SLASH = 47,
++ SDLK_0 = 48,
++ SDLK_1 = 49,
++ SDLK_2 = 50,
++ SDLK_3 = 51,
++ SDLK_4 = 52,
++ SDLK_5 = 53,
++ SDLK_6 = 54,
++ SDLK_7 = 55,
++ SDLK_8 = 56,
++ SDLK_9 = 57,
++ SDLK_COLON = 58,
++ SDLK_SEMICOLON = 59,
++ SDLK_LESS = 60,
++ SDLK_EQUALS = 61,
++ SDLK_GREATER = 62,
++ SDLK_QUESTION = 63,
++ SDLK_AT = 64,
++ /*
++ Skip uppercase letters
++ */
++ SDLK_LEFTBRACKET = 91,
++ SDLK_BACKSLASH = 92,
++ SDLK_RIGHTBRACKET = 93,
++ SDLK_CARET = 94,
++ SDLK_UNDERSCORE = 95,
++ SDLK_BACKQUOTE = 96,
++ SDLK_a = 97,
++ SDLK_b = 98,
++ SDLK_c = 99,
++ SDLK_d = 100,
++ SDLK_e = 101,
++ SDLK_f = 102,
++ SDLK_g = 103,
++ SDLK_h = 104,
++ SDLK_i = 105,
++ SDLK_j = 106,
++ SDLK_k = 107,
++ SDLK_l = 108,
++ SDLK_m = 109,
++ SDLK_n = 110,
++ SDLK_o = 111,
++ SDLK_p = 112,
++ SDLK_q = 113,
++ SDLK_r = 114,
++ SDLK_s = 115,
++ SDLK_t = 116,
++ SDLK_u = 117,
++ SDLK_v = 118,
++ SDLK_w = 119,
++ SDLK_x = 120,
++ SDLK_y = 121,
++ SDLK_z = 122,
++ SDLK_DELETE = 127,
++ /* End of ASCII mapped keysyms */
++
++ /* International keyboard syms */
++ SDLK_WORLD_0 = 160, /* 0xA0 */
++ SDLK_WORLD_1 = 161,
++ SDLK_WORLD_2 = 162,
++ SDLK_WORLD_3 = 163,
++ SDLK_WORLD_4 = 164,
++ SDLK_WORLD_5 = 165,
++ SDLK_WORLD_6 = 166,
++ SDLK_WORLD_7 = 167,
++ SDLK_WORLD_8 = 168,
++ SDLK_WORLD_9 = 169,
++ SDLK_WORLD_10 = 170,
++ SDLK_WORLD_11 = 171,
++ SDLK_WORLD_12 = 172,
++ SDLK_WORLD_13 = 173,
++ SDLK_WORLD_14 = 174,
++ SDLK_WORLD_15 = 175,
++ SDLK_WORLD_16 = 176,
++ SDLK_WORLD_17 = 177,
++ SDLK_WORLD_18 = 178,
++ SDLK_WORLD_19 = 179,
++ SDLK_WORLD_20 = 180,
++ SDLK_WORLD_21 = 181,
++ SDLK_WORLD_22 = 182,
++ SDLK_WORLD_23 = 183,
++ SDLK_WORLD_24 = 184,
++ SDLK_WORLD_25 = 185,
++ SDLK_WORLD_26 = 186,
++ SDLK_WORLD_27 = 187,
++ SDLK_WORLD_28 = 188,
++ SDLK_WORLD_29 = 189,
++ SDLK_WORLD_30 = 190,
++ SDLK_WORLD_31 = 191,
++ SDLK_WORLD_32 = 192,
++ SDLK_WORLD_33 = 193,
++ SDLK_WORLD_34 = 194,
++ SDLK_WORLD_35 = 195,
++ SDLK_WORLD_36 = 196,
++ SDLK_WORLD_37 = 197,
++ SDLK_WORLD_38 = 198,
++ SDLK_WORLD_39 = 199,
++ SDLK_WORLD_40 = 200,
++ SDLK_WORLD_41 = 201,
++ SDLK_WORLD_42 = 202,
++ SDLK_WORLD_43 = 203,
++ SDLK_WORLD_44 = 204,
++ SDLK_WORLD_45 = 205,
++ SDLK_WORLD_46 = 206,
++ SDLK_WORLD_47 = 207,
++ SDLK_WORLD_48 = 208,
++ SDLK_WORLD_49 = 209,
++ SDLK_WORLD_50 = 210,
++ SDLK_WORLD_51 = 211,
++ SDLK_WORLD_52 = 212,
++ SDLK_WORLD_53 = 213,
++ SDLK_WORLD_54 = 214,
++ SDLK_WORLD_55 = 215,
++ SDLK_WORLD_56 = 216,
++ SDLK_WORLD_57 = 217,
++ SDLK_WORLD_58 = 218,
++ SDLK_WORLD_59 = 219,
++ SDLK_WORLD_60 = 220,
++ SDLK_WORLD_61 = 221,
++ SDLK_WORLD_62 = 222,
++ SDLK_WORLD_63 = 223,
++ SDLK_WORLD_64 = 224,
++ SDLK_WORLD_65 = 225,
++ SDLK_WORLD_66 = 226,
++ SDLK_WORLD_67 = 227,
++ SDLK_WORLD_68 = 228,
++ SDLK_WORLD_69 = 229,
++ SDLK_WORLD_70 = 230,
++ SDLK_WORLD_71 = 231,
++ SDLK_WORLD_72 = 232,
++ SDLK_WORLD_73 = 233,
++ SDLK_WORLD_74 = 234,
++ SDLK_WORLD_75 = 235,
++ SDLK_WORLD_76 = 236,
++ SDLK_WORLD_77 = 237,
++ SDLK_WORLD_78 = 238,
++ SDLK_WORLD_79 = 239,
++ SDLK_WORLD_80 = 240,
++ SDLK_WORLD_81 = 241,
++ SDLK_WORLD_82 = 242,
++ SDLK_WORLD_83 = 243,
++ SDLK_WORLD_84 = 244,
++ SDLK_WORLD_85 = 245,
++ SDLK_WORLD_86 = 246,
++ SDLK_WORLD_87 = 247,
++ SDLK_WORLD_88 = 248,
++ SDLK_WORLD_89 = 249,
++ SDLK_WORLD_90 = 250,
++ SDLK_WORLD_91 = 251,
++ SDLK_WORLD_92 = 252,
++ SDLK_WORLD_93 = 253,
++ SDLK_WORLD_94 = 254,
++ SDLK_WORLD_95 = 255, /* 0xFF */
++
++ /* Numeric keypad */
++ SDLK_KP0 = 256,
++ SDLK_KP1 = 257,
++ SDLK_KP2 = 258,
++ SDLK_KP3 = 259,
++ SDLK_KP4 = 260,
++ SDLK_KP5 = 261,
++ SDLK_KP6 = 262,
++ SDLK_KP7 = 263,
++ SDLK_KP8 = 264,
++ SDLK_KP9 = 265,
++ SDLK_KP_PERIOD = 266,
++ SDLK_KP_DIVIDE = 267,
++ SDLK_KP_MULTIPLY = 268,
++ SDLK_KP_MINUS = 269,
++ SDLK_KP_PLUS = 270,
++ SDLK_KP_ENTER = 271,
++ SDLK_KP_EQUALS = 272,
++
++ /* Arrows + Home/End pad */
++ SDLK_UP = 273,
++ SDLK_DOWN = 274,
++ SDLK_RIGHT = 275,
++ SDLK_LEFT = 276,
++ SDLK_INSERT = 277,
++ SDLK_HOME = 278,
++ SDLK_END = 279,
++ SDLK_PAGEUP = 280,
++ SDLK_PAGEDOWN = 281,
++
++ /* Function keys */
++ SDLK_F1 = 282,
++ SDLK_F2 = 283,
++ SDLK_F3 = 284,
++ SDLK_F4 = 285,
++ SDLK_F5 = 286,
++ SDLK_F6 = 287,
++ SDLK_F7 = 288,
++ SDLK_F8 = 289,
++ SDLK_F9 = 290,
++ SDLK_F10 = 291,
++ SDLK_F11 = 292,
++ SDLK_F12 = 293,
++ SDLK_F13 = 294,
++ SDLK_F14 = 295,
++ SDLK_F15 = 296,
++
++ /* Key state modifier keys */
++ SDLK_NUMLOCK = 300,
++ SDLK_CAPSLOCK = 301,
++ SDLK_SCROLLOCK = 302,
++ SDLK_RSHIFT = 303,
++ SDLK_LSHIFT = 304,
++ SDLK_RCTRL = 305,
++ SDLK_LCTRL = 306,
++ SDLK_RALT = 307,
++ SDLK_LALT = 308,
++ SDLK_RMETA = 309,
++ SDLK_LMETA = 310,
++ SDLK_LSUPER = 311, /* Left "Windows" key */
++ SDLK_RSUPER = 312, /* Right "Windows" key */
++ SDLK_MODE = 313, /* "Alt Gr" key */
++ SDLK_COMPOSE = 314, /* Multi-key compose key */
++
++ /* Miscellaneous function keys */
++ SDLK_HELP = 315,
++ SDLK_PRINT = 316,
++ SDLK_SYSREQ = 317,
++ SDLK_BREAK = 318,
++ SDLK_MENU = 319,
++ SDLK_POWER = 320, /* Power Macintosh power key */
++ SDLK_EURO = 321, /* Some european keyboards */
++ SDLK_UNDO = 322, /* Atari keyboard has Undo */
++
++ /* Add any other keys here */
++
++ SDLK_LAST
++}
++
++/* Enumeration of valid key mods (possibly OR'd together) */
++alias int SDLMod;
++enum {
++ KMOD_NONE = 0x0000,
++ KMOD_LSHIFT= 0x0001,
++ KMOD_RSHIFT= 0x0002,
++ KMOD_LCTRL = 0x0040,
++ KMOD_RCTRL = 0x0080,
++ KMOD_LALT = 0x0100,
++ KMOD_RALT = 0x0200,
++ KMOD_LMETA = 0x0400,
++ KMOD_RMETA = 0x0800,
++ KMOD_NUM = 0x1000,
++ KMOD_CAPS = 0x2000,
++ KMOD_MODE = 0x4000,
++ KMOD_RESERVED = 0x8000
++}
++
++const uint KMOD_CTRL = (KMOD_LCTRL|KMOD_RCTRL);
++const uint KMOD_SHIFT = (KMOD_LSHIFT|KMOD_RSHIFT);
++const uint KMOD_ALT = (KMOD_LALT|KMOD_RALT);
++const uint KMOD_META = (KMOD_LMETA|KMOD_RMETA);
+diff -Naur tf/import/SDL_mixer.d tf-gentoo/import/SDL_mixer.d
+--- tf/import/SDL_mixer.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_mixer.d 2007-09-19 22:07:12.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ // convert to D by shinichiro.h
+
+-/* $Id: SDL_mixer.d,v 1.1.1.1 2004/04/03 10:36:30 kenta Exp $ */
++/* $Id: SDL_mixer.d,v 1.1.1.1 2005/06/18 00:46:00 kenta Exp $ */
+
+ import SDL;
+
+diff -Naur tf/import/SDL_mouse.d tf-gentoo/import/SDL_mouse.d
+--- tf/import/SDL_mouse.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_mouse.d 2007-09-19 22:07:12.000000000 +0200
+@@ -109,6 +109,8 @@
+ const uint SDL_BUTTON_LEFT = 1;
+ const uint SDL_BUTTON_MIDDLE = 2;
+ const uint SDL_BUTTON_RIGHT = 3;
++const uint SDL_BUTTON_WHEELUP = 4;
++const uint SDL_BUTTON_WHEELDOWN = 5;
+ const uint SDL_BUTTON_LMASK = SDL_PRESSED << (SDL_BUTTON_LEFT - 1);
+ const uint SDL_BUTTON_MMASK = SDL_PRESSED << (SDL_BUTTON_MIDDLE - 1);
+ const uint SDL_BUTTON_RMASK = SDL_PRESSED << (SDL_BUTTON_RIGHT - 1);
+diff -Naur tf/import/SDL_syswm.d tf-gentoo/import/SDL_syswm.d
+--- tf/import/SDL_syswm.d 2004-04-03 19:36:30.000000000 +0200
++++ tf-gentoo/import/SDL_syswm.d 2007-09-19 22:07:12.000000000 +0200
+@@ -22,7 +22,7 @@
+
+ /* Include file for SDL custom system window manager hooks */
+
+-import SDL_version_;
++import SDL_Version;
+
+ extern(C):
+
+diff -Naur tf/import/SDL_version_.d tf-gentoo/import/SDL_version_.d
+--- tf/import/SDL_version_.d 2004-04-03 19:36:32.000000000 +0200
++++ tf-gentoo/import/SDL_version_.d 1970-01-01 01:00:00.000000000 +0100
+@@ -1,75 +0,0 @@
+-/*
+- SDL - Simple DirectMedia Layer
+- Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
+-
+- This library is free software; you can redistribute it and/or
+- modify it under the terms of the GNU Library General Public
+- License as published by the Free Software Foundation; either
+- version 2 of the License, or (at your option) any later version.
+-
+- This library is distributed in the hope that it will be useful,
+- but WITHOUT ANY WARRANTY; without even the implied warranty of
+- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+- Library General Public License for more details.
+-
+- You should have received a copy of the GNU Library General Public
+- License along with this library; if not, write to the Free
+- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+-
+- Sam Lantinga
+- slouken@devolution.com
+-*/
+-
+-/* This header defines the current SDL version */
+-
+-import SDL_types;
+-
+-extern(C):
+-
+-/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
+-*/
+-const uint SDL_MAJOR_VERSION = 1;
+-const uint SDL_MINOR_VERSION = 2;
+-const uint SDL_PATCHLEVEL = 6;
+-
+-struct SDL_version {
+- Uint8 major;
+- Uint8 minor;
+- Uint8 patch;
+-}
+-
+-/* This macro can be used to fill a version structure with the compile-time
+- * version of the SDL library.
+- */
+-void SDL_VERSION(SDL_version* X)
+-{
+- X.major = SDL_MAJOR_VERSION;
+- X.minor = SDL_MINOR_VERSION;
+- X.patch = SDL_PATCHLEVEL;
+-}
+-
+-/* This macro turns the version numbers into a numeric value:
+- (1,2,3) -> (1203)
+- This assumes that there will never be more than 100 patchlevels
+-*/
+-uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
+-{
+- return X * 1000 + Y * 100 + Z;
+-}
+-
+-/* This is the version number macro for the current SDL version */
+-const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
+- SDL_MINOR_VERSION * 100 +
+- SDL_PATCHLEVEL;
+-
+-/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
+-bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
+-{
+- return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
+-}
+-
+-/* This function gets the version of the dynamically linked SDL library.
+- it should NOT be used to fill a version structure, instead you should
+- use the SDL_Version() macro.
+- */
+-SDL_version * SDL_Linked_Version();
+diff -Naur tf/import/SDL_Version.d tf-gentoo/import/SDL_Version.d
+--- tf/import/SDL_Version.d 1970-01-01 01:00:00.000000000 +0100
++++ tf-gentoo/import/SDL_Version.d 2007-09-19 22:07:12.000000000 +0200
+@@ -0,0 +1,75 @@
++/*
++ SDL - Simple DirectMedia Layer
++ Copyright (C) 1997, 1998, 1999, 2000, 2001 Sam Lantinga
++
++ This library is free software; you can redistribute it and/or
++ modify it under the terms of the GNU Library General Public
++ License as published by the Free Software Foundation; either
++ version 2 of the License, or (at your option) any later version.
++
++ This library is distributed in the hope that it will be useful,
++ but WITHOUT ANY WARRANTY; without even the implied warranty of
++ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
++ Library General Public License for more details.
++
++ You should have received a copy of the GNU Library General Public
++ License along with this library; if not, write to the Free
++ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
++
++ Sam Lantinga
++ slouken@devolution.com
++*/
++
++/* This header defines the current SDL version */
++
++import SDL_types;
++
++extern(C):
++
++/* Printable format: "%d.%d.%d", MAJOR, MINOR, PATCHLEVEL
++*/
++const uint SDL_MAJOR_VERSION = 1;
++const uint SDL_MINOR_VERSION = 2;
++const uint SDL_PATCHLEVEL = 6;
++
++struct SDL_version {
++ Uint8 major;
++ Uint8 minor;
++ Uint8 patch;
++}
++
++/* This macro can be used to fill a version structure with the compile-time
++ * version of the SDL library.
++ */
++void SDL_VERSION(SDL_version* X)
++{
++ X.major = SDL_MAJOR_VERSION;
++ X.minor = SDL_MINOR_VERSION;
++ X.patch = SDL_PATCHLEVEL;
++}
++
++/* This macro turns the version numbers into a numeric value:
++ (1,2,3) -> (1203)
++ This assumes that there will never be more than 100 patchlevels
++*/
++uint SDL_VERSIONNUM(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return X * 1000 + Y * 100 + Z;
++}
++
++/* This is the version number macro for the current SDL version */
++const uint SDL_COMPILEDVERSION = SDL_MAJOR_VERSION * 1000 +
++ SDL_MINOR_VERSION * 100 +
++ SDL_PATCHLEVEL;
++
++/* This macro will evaluate to true if compiled with SDL at least X.Y.Z */
++bit SDL_VERSION_ATLEAST(Uint8 X, Uint8 Y, Uint8 Z)
++{
++ return (SDL_COMPILEDVERSION >= SDL_VERSIONNUM(X, Y, Z));
++}
++
++/* This function gets the version of the dynamically linked SDL library.
++ it should NOT be used to fill a version structure, instead you should
++ use the SDL_Version() macro.
++ */
++SDL_version * SDL_Linked_Version();
+diff -Naur tf/Makefile tf-gentoo/Makefile
+--- tf/Makefile 1970-01-01 01:00:00.000000000 +0100
++++ tf-gentoo/Makefile 2007-09-19 22:07:12.000000000 +0200
+@@ -0,0 +1,25 @@
++DC=gdmd
++#DC=gdc
++ifeq ($(DC), gdmd)
++DFLAGS=-g -debug -O -Iimport -Isrc
++#DFLAGS=-g -debug -Iimport -Isrc
++DOUT=-of
++else
++DFLAGS=-O -debug -Iimport -Isrc
++#DFLAGS=-g -fdebug -Iimport -Isrc
++DOUT=-o
++endif
++
++DSRC=$(shell find src/ -name "*.d")
++SOURCES=$(DSRC) import/SDL_video.d import/SDL_mixer.d
++OBJS=$(SOURCES:.d=.o)
++EXE=tumikifighters
++
++all: $(EXE)
++
++$(EXE): $(OBJS)
++ gcc -o $@ $(OBJS) -lbulletml_d -lgphobos -lpthread -lm -lSDL -lGL -lGLU -lSDL_mixer
++
++$(OBJS): %.o: %.d
++ gdmd -d -c -of$@ $(DFLAGS) $<
++
+diff -Naur tf/src/abagames/tf/boot.d tf-gentoo/src/abagames/tf/boot.d
+--- tf/src/abagames/tf/boot.d 2004-05-14 23:35:38.000000000 +0200
++++ tf-gentoo/src/abagames/tf/boot.d 2007-09-19 22:07:12.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.tf.boot;
+
+-private import std.string;
++private import std.c.string;
+ private import std.c.stdlib;
+ private import abagames.util.logger;
+ private import abagames.util.sdl.mainloop;
+diff -Naur tf/src/abagames/tf/enemy.d tf-gentoo/src/abagames/tf/enemy.d
+--- tf/src/abagames/tf/enemy.d 2004-05-15 16:46:52.000000000 +0200
++++ tf-gentoo/src/abagames/tf/enemy.d 2007-09-19 22:07:12.000000000 +0200
+@@ -142,13 +142,14 @@
+ float speed;
+ Vector[] pt;
+ if (!mv.withdraw) {
+- pt = mv.pattern.point[barragePtnIdx];
+- if (!pt) {
++// pt = mv.pattern.point[barragePtnIdx];
++// if (!pt)
++ {
+ pt = mv.pattern.point[PointsMovePattern.BASIC_PATTERN_IDX];
+ speed = mv.pattern.speed[PointsMovePattern.BASIC_PATTERN_IDX];
+- } else {
+- speed = mv.pattern.speed[barragePtnIdx];
+- }
++ }// else {
++// speed = mv.pattern.speed[barragePtnIdx];
++// }
+ if (!mv.reachFirstPointFirst)
+ speed *= 3;
+ else if (!mv.reachFirstPoint)
+@@ -272,7 +273,7 @@
+ if (attackPtnIdx >= af.attackPeriod.length)
+ attackPtnIdx = 0;
+ if (!mv.moveBullet) {
+- if (mv.pattern.point[barragePtnIdx])
++// if (mv.pattern.point[barragePtnIdx])
+ movePatternChanged();
+ }
+ } else if (fireCnt < af.breakPeriod[attackPtnIdx]) {
+@@ -329,7 +330,7 @@
+ if (ep.shield <= 0) {
+ if (ep.spec.damageToMainBody > 0) {
+ parts[0].shield -= ep.spec.damageToMainBody;
+- particles.add(5, pos, 0, PI * 2, 0.1, parts[0].spec.size / 4, Particle.TypeName.SMOKE);
++ particles.add(5, pos, 0, PI * 2, 0.1, parts[0].spec.sizeof / 4, Particle.TypeName.SMOKE);
+ }
+ manager.addScore(ep.spec.tumikiSet.score, p);
+ if (ep.firstShield <= 1)
+diff -Naur tf/src/abagames/tf/enemyspec.d tf-gentoo/src/abagames/tf/enemyspec.d
+--- tf/src/abagames/tf/enemyspec.d 2004-05-14 23:35:38.000000000 +0200
++++ tf-gentoo/src/abagames/tf/enemyspec.d 2007-09-19 22:07:12.000000000 +0200
+@@ -89,11 +89,10 @@
+ }
+
+ public static EnemySpec getInstance(char[] fileName) {
+- EnemySpec inst = instances[fileName];
++ EnemySpec inst;
+ if (!inst) {
+- Logger.info("Load enemy spec: " ~ fileName);
+- inst = new EnemySpec(fileName);
+- instances[fileName] = inst;
++ inst = new EnemySpec(fileName);
++ instances[fileName] = inst;
+ }
+ return inst;
+ }
+diff -Naur tf/src/abagames/tf/letterrender.d tf-gentoo/src/abagames/tf/letterrender.d
+--- tf/src/abagames/tf/letterrender.d 2004-05-14 23:35:38.000000000 +0200
++++ tf-gentoo/src/abagames/tf/letterrender.d 2007-09-19 22:07:12.000000000 +0200
+@@ -32,7 +32,7 @@
+ return s * LETTER_HEIGHT;
+ }
+
+- private static void drawLetter(int n, float x, float y, float s, float d, int c) {
++ public static void drawLetter(int n, float x, float y, float s, float d, int c) {
+ glPushMatrix();
+ glTranslatef(x, y, 0);
+ glScalef(s, s, s);
+diff -Naur tf/src/abagames/tf/prefmanager.d tf-gentoo/src/abagames/tf/prefmanager.d
+--- tf/src/abagames/tf/prefmanager.d 2004-05-14 23:35:38.000000000 +0200
++++ tf-gentoo/src/abagames/tf/prefmanager.d 2007-09-19 22:07:12.000000000 +0200
+@@ -37,6 +37,11 @@
+ auto File fd = new File;
+ try {
+ int ver;
++ // if (exists(PREF_FILE) == 0)
++{
++ init();
++ save();
++ }
+ fd.open(PREF_FILE);
+ fd.read(ver);
+ if (ver != VERSION_NUM)
+@@ -66,7 +71,7 @@
+ break;
+ if (i >= RANKING_NUM)
+ return;
+- for (int j = RANKING_NUM - 1; j > i; j--)
++ for (int j = RANKING_NUM - 1; j > i; j--)
+ ranking[j] = ranking[j - 1];
+ ranking[i] = new RankingItem(sc, st);
+ }
+diff -Naur tf/src/abagames/tf/ship.d tf-gentoo/src/abagames/tf/ship.d
+--- tf/src/abagames/tf/ship.d 2004-05-15 16:46:52.000000000 +0200
++++ tf-gentoo/src/abagames/tf/ship.d 2007-09-19 22:07:12.000000000 +0200
+@@ -70,7 +70,7 @@
+ bool btnPrsd;
+ bool pullIn;
+
+- public static this() {
++ public this() {
+ rand = new Rand;
+ }
+
+diff -Naur tf/src/abagames/tf/tumikiset.d tf-gentoo/src/abagames/tf/tumikiset.d
+--- tf/src/abagames/tf/tumikiset.d 2004-05-14 23:35:38.000000000 +0200
++++ tf-gentoo/src/abagames/tf/tumikiset.d 2007-09-19 22:07:12.000000000 +0200
+@@ -6,7 +6,8 @@
+ module abagames.tf.tumikiset;
+
+ private import std.string;
+-private import std.math;
++private import std.math;
++private import std.cstream;
+ private import abagames.util.vector;
+ private import abagames.util.csv;
+ private import abagames.util.iterator;
+@@ -32,19 +33,19 @@
+ static const char[] TUMIKI_DIR_NAME = "tumiki";
+ static const float BULLET_SPEED_RATIO = 1.2;
+ static int[char[]] shapeStr;
+- static char[][] SHAPE_STR =
++ static char[][] SHAPE_STR =
+ ["s", "ul", "ur", "dr", "dl", "u", "r", "d", "l", "pu", "pdr", "pr", "pur", "pd", "pf"];
+ static int[char[]] colorStr;
+- static char[][] COLOR_STR =
++ static char[][] COLOR_STR =
+ ["r", "g", "b", "y", "p", "a", "w", "gr"];
+ static int[char[]] bulletShapeStr;
+- static char[][] BULLET_SHAPE_STR =
++ static char[][] BULLET_SHAPE_STR =
+ ["b", "a", "r"];
+ static int[char[]] bulletColorStr;
+- static char[][] BULLET_COLOR_STR =
++ static char[][] BULLET_COLOR_STR =
+ ["r", "a", "p"];
+
+- public static this() {
++ public static void randInit() {
+ int i = 0;
+ foreach (char[] s; SHAPE_STR) {
+ shapeStr[s] = i;
+@@ -61,7 +62,8 @@
+ i++;
+ }
+ i = 0;
+- foreach (char[] s; BULLET_COLOR_STR) {
++ foreach (char[] s; BULLET_COLOR_STR) {
++ derr.writeLine("> s: " ~ std.string.toString(s));
+ bulletColorStr[s] = i;
+ i++;
+ }
+@@ -75,7 +77,8 @@
+ // [BulletML, rank, speed]],
+ // (end when BulletML == e, shape == e)(set a empty barrage when shape == s),
+ // ],
+- private this(char[][] data) {
++ public this(char[][] data) {
++ randInit();
+ sizeXm = sizeYm = float.max;
+ sizeXp = sizeYp = float.min;
+ StringIterator si = new StringIterator(data);
+@@ -87,9 +90,11 @@
+ if (!si.hasNext)
+ break;
+ char[] v = si.next;
+- int shape = shapeStr[v];
++ int shape;
++ try { shape = shapeStr[v]; } catch (Exception e) {}
+ v = si.next;
+- int color = colorStr[v];
++ int color;
++ try { color = colorStr[v]; } catch (Exception e) {}
+ float x = atof(si.next);
+ float y = atof(si.next);
+ float sizex = atof(si.next);
+@@ -111,9 +116,11 @@
+ ti.addBarrage(new Barrage);
+ continue;
+ }
+- int shape = bulletShapeStr[v];
++ int shape;
++ try { shape = bulletShapeStr[v]; } catch (Exception e) {}
+ v = si.next;
+- int color = bulletColorStr[v];
++ int color;
++ try { color = bulletColorStr[v]; } catch (Exception e) {}
+ float size = atof(si.next);
+ float yReverse = atof(si.next);
+ int prevWait = atoi(si.next);
+@@ -136,14 +143,15 @@
+ }
+
+ // Initialize TumikiSet from the file.
+- private this(char[] fileName) {
++ public this(char[] fileName) {
++ randInit();
+ Logger.info("Load tumiki set: " ~ fileName);
+ char[][] data = CSVTokenizer.readFile(TUMIKI_DIR_NAME ~ "/" ~ fileName);
+ this(data);
+ }
+
+ public static TumikiSet getInstance(char[] fileName) {
+- TumikiSet inst = instances[fileName];
++ TumikiSet inst; // = instances[fileName];
+ if (!inst) {
+ inst = new TumikiSet(fileName);
+ instances[fileName] = inst;
+diff -Naur tf/src/abagames/util/logger.d tf-gentoo/src/abagames/util/logger.d
+--- tf/src/abagames/util/logger.d 2004-05-14 23:35:38.000000000 +0200
++++ tf-gentoo/src/abagames/util/logger.d 2007-09-19 22:07:12.000000000 +0200
+@@ -5,7 +5,7 @@
+ */
+ module abagames.util.logger;
+
+-private import std.stream;
++private import std.cstream;
+ private import std.string;
+
+ /**
+@@ -53,27 +53,27 @@
+ public class Logger {
+
+ public static void info(char[] msg) {
+- stderr.writeLine("Info: " ~ msg);
++ derr.writeLine("Info: " ~ msg);
+ }
+
+ public static void info(int n) {
+- stderr.writeLine("Info: " ~ std.string.toString(n));
++ derr.writeLine("Info: " ~ std.string.toString(n));
+ }
+
+ public static void info(float n) {
+- stderr.writeLine("Info: -" ~ std.string.toString(n));
++ derr.writeLine("Info: -" ~ std.string.toString(n));
+ }
+
+ public static void error(char[] msg) {
+- stderr.writeLine("Error: " ~ msg);
++ derr.writeLine("Error: " ~ msg);
+ }
+
+ public static void error(Exception e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ derr.writeLine("Error: " ~ e.toString());
+ }
+
+ public static void error(Error e) {
+- stderr.writeLine("Error: " ~ e.toString());
++ derr.writeLine("Error: " ~ e.toString());
+ if (e.next)
+ error(e.next);
+ }
+diff -Naur tf/src/dirent.d tf-gentoo/src/dirent.d
+--- tf/src/dirent.d 1970-01-01 01:00:00.000000000 +0100
++++ tf-gentoo/src/dirent.d 2007-09-19 22:07:12.000000000 +0200
+@@ -0,0 +1,10 @@
++import std.string;
++
++extern (C) {
++ alias void DIR;
++ alias void dirent;
++ DIR* opendir(char* name);
++ dirent* readdir(DIR* dir);
++ int closedir(DIR* dir);
++ char* readdir_filename(DIR* ent);
++}
diff --git a/games-action/tumikifighters/files/tumikifighters.png b/games-action/tumikifighters/files/tumikifighters.png
new file mode 100644
index 0000000..9a49061
--- /dev/null
+++ b/games-action/tumikifighters/files/tumikifighters.png
Binary files differ
diff --git a/games-action/tumikifighters/metadata.xml b/games-action/tumikifighters/metadata.xml
new file mode 100644
index 0000000..4e4714e
--- /dev/null
+++ b/games-action/tumikifighters/metadata.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+<maintainer>
+ <email>frostworks@gmx.de</email>
+ <name>Marcel Unbehaun</name>
+</maintainer>
+<herd>games</herd>
+</pkgmetadata>
diff --git a/games-action/tumikifighters/tumikifighters-0.2.ebuild b/games-action/tumikifighters/tumikifighters-0.2.ebuild
new file mode 100644
index 0000000..bf83e45
--- /dev/null
+++ b/games-action/tumikifighters/tumikifighters-0.2.ebuild
@@ -0,0 +1,63 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: $
+
+EAPI="2"
+
+inherit d-games
+
+MY_PN=tf
+MY_PV=${PV//./_}
+
+DESCRIPTION="Stick more enemies and become much stronger. Sticky 2D shooter, 'TUMIKI Fighters'. "
+HOMEPAGE="http://www.asahi-net.or.jp/~cs8k-cyu/windows/tf_e.html"
+SRC_URI="http://www.asahi-net.or.jp/~cs8k-cyu/windows/${MY_PN}${MY_PV}.zip"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+IUSE=""
+
+RDEPEND="media-libs/libsdl
+ media-libs/mesa
+ media-libs/sdl-mixer
+ dev-libs/bulletss"
+DEPEND="${RDEPEND}"
+
+S=${WORKDIR}/${MY_PN}
+
+src_prepare(){
+ epatch "${FILESDIR}"/${P}.diff
+ sed -i \
+ -e 's:"\(sounds/[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/util/sdl/sound.d \
+ -e 's:"\(barrage[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tf/barragemanager.d \
+ -e 's:"\(enemy[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tf/enemyspec.d \
+ -e 's:"\(field[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tf/field.d \
+ -e 's:"\(stage[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tf/stagemanager.d \
+ -e 's:"\(tumiki[^"]*\)":"'${GAMES_DATADIR}'/'${PN}'/\1":g' -i src/abagames/tf/tumikiset.d \
+ -e 's:"\(tf.prf[^"]*\)":"'${GAMES_STATEDIR}'/\1":g' -i src/abagames/tf/prefmanager.d \
+ || die "sed failed"
+}
+
+src_install() {
+ dogamesbin ${PN}
+
+ if [ ! -e "${GAMES_STATEDIR}"/tf.prf ]; then
+ dodir "${GAMES_STATEDIR}"
+ touch ${D}/"${GAMES_STATEDIR}"/tf.prf
+ fi
+
+ local datadir="${GAMES_DATADIR}"/${PN}
+ dodir ${datadir}
+ insinto "${GAMES_DATADIR}"/${PN}
+ doins -r barrage enemy field sounds stage tumiki || die
+ newicon "${FILESDIR}"/${PN}.png ${PN}.png
+ make_desktop_entry ${PN} ${PN}
+ dodoc readme*
+ prepgamesdirs
+}
+
+pkg_postinst() {
+ chmod 660 "${GAMES_STATEDIR}"/tf.prf
+ games_pkg_postinst
+}
diff --git a/games-action/valandrick/Manifest b/games-action/valandrick/Manifest
new file mode 100644
index 0000000..2541531
--- /dev/null
+++ b/games-action/valandrick/Manifest
@@ -0,0 +1,5 @@
+AUX valandrick-0.1a.diff 24651 RMD160 7116f7e289afa887b1cab80e8753be1d558ad44a SHA1 e578f26d0911adad9dee8ef578552522edc9f395 SHA256 3bd698849b0a60816e28ac9b2b4da8eb7c8809bf5a5871e35c522c814efe95b8
+AUX valandrick.png 1633 RMD160 7ca0c402f06f089fc8e22d2abd2bfcb7b840e6f4 SHA1 efd86c12c89f1dcae8bfd9e6a93fe77d0c9452fc SHA256 870a5ea2bcc266cf34a69904205cd682943e053207b1856bd01c115045c2462f
+DIST vr0_1a.zip 2146246 RMD160 79eb44602d2c2ad276023cc8d5dec1d3c6f3f149 SHA1 3712c889e5097eb83e44f7c40ee7549815a900e9 SHA256 e167c6dcfb4a7d6f26e42deeebef1c224e1e5a38a51d067710585c956af554c4
+EBUILD valandrick-0.1a.ebuild 1489 RMD160 f2f8be8be817e75a682dec3f910cf019b9d10e39 SHA1 0356940d3dc93a11ab69b7402a175e1b637fbc35 SHA256 f33a24d99a3efc841c1567eb429a0cc886427be79e8c46d017ce7ae0d56d2c3a
+MISC metadata.xml 249 RMD160 220cde0fc1a8d7d355705f0f6772bd8d77cdc17a SHA1 34b33eb8d24cd8bfef2ddfb8e80334fd77cc9488 SHA256 3875fd5008d7f5bfe7f3cf7bf330c209a5034f5988d37c1699fb3be35a7be906
diff --git a/games-action/valandrick/files/digest-valandrick-0.1a b/games-action/valandrick/files/digest-valandrick-0.1a
new file mode 100644
index 0000000..76a781b
--- /dev/null
+++ b/games-action/valandrick/files/digest-valandrick-0.1a
@@ -0,0 +1,3 @@
+MD5 92f794ed144bd73c8c350de69505914f vr0_1a.zip 2146246
+RMD160 79eb44602d2c2ad276023cc8d5dec1d3c6f3f149 vr0_1a.zip 2146246
+SHA256 e167c6dcfb4a7d6f26e42deeebef1c224e1e5a38a51d067710585c956af554c4 vr0_1a.zip 2146246
diff --git a/games-action/valandrick/files/valandrick-0.1a.diff b/games-action/valandrick/files/valandrick-0.1a.diff
new file mode 100644
index 0000000..a08cd86
--- /dev/null
+++ b/games-action/valandrick/files/valandrick-0.1a.diff
@@ -0,0 +1,785 @@
+diff -Naur vr/import/opengl.d vr-gentoo/import/opengl.d
+--- vr/import/opengl.d 2005-03-14 01:15:04.000000000 +0100
++++ vr-gentoo/import/opengl.d 2007-09-20 08:40:47.000000000 +0200
+@@ -1,10 +1,4 @@
+-version (Win32) {
+- private import std.c.windows.windows;
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ alias uint GLenum;
+ alias ubyte GLboolean;
+@@ -59,6 +53,7 @@
+ const uint GL_VIEWPORT_BIT = 0x00000800;
+ const uint GL_TRANSFORM_BIT = 0x00001000;
+ const uint GL_ENABLE_BIT = 0x00002000;
++const uint GL_UNSIGNED_INT_8_8_8_8_REV = 0x8367;
+ const uint GL_COLOR_BUFFER_BIT = 0x00004000;
+ const uint GL_HINT_BIT = 0x00008000;
+ const uint GL_EVAL_BIT = 0x00010000;
+@@ -1116,7 +1111,7 @@
+ /*************************************************************/
+
+ void /*APIENTRY*/glAccum (GLenum op, GLfloat value);
+-void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf ref);
++void /*APIENTRY*/glAlphaFunc (GLenum func, GLclampf);
+ GLboolean /*APIENTRY*/glAreTexturesResident (GLsizei n, GLuint *textures, GLboolean *residences);
+ void /*APIENTRY*/glArrayElement (GLint i);
+ void /*APIENTRY*/glBegin (GLenum mode);
+@@ -1369,7 +1364,7 @@
+ void /*APIENTRY*/glScissor (GLint x, GLint y, GLsizei width, GLsizei height);
+ void /*APIENTRY*/glSelectBuffer (GLsizei size, GLuint *buffer);
+ void /*APIENTRY*/glShadeModel (GLenum mode);
+-void /*APIENTRY*/glStencilFunc (GLenum func, GLint ref, GLuint mask);
++void /*APIENTRY*/glStencilFunc (GLenum func, GLint, GLuint mask);
+ void /*APIENTRY*/glStencilMask (GLuint mask);
+ void /*APIENTRY*/glStencilOp (GLenum fail, GLenum zfail, GLenum zpass);
+ void /*APIENTRY*/glTexCoord1d (GLdouble s);
+diff -Naur vr/import/openglu.d vr-gentoo/import/openglu.d
+--- vr/import/openglu.d 2005-03-14 01:15:04.000000000 +0100
++++ vr-gentoo/import/openglu.d 2007-09-20 08:40:52.000000000 +0200
+@@ -1,11 +1,6 @@
+ import opengl;
+
+-version (Win32) {
+- extern(Windows):
+-}
+-version (linux) {
+ extern(C):
+-}
+
+ GLubyte* gluErrorString (
+ GLenum errCode);
+diff -Naur vr/import/SDL.d vr-gentoo/import/SDL.d
+--- vr/import/SDL.d 2005-03-14 01:15:04.000000000 +0100
++++ vr-gentoo/import/SDL.d 2007-09-20 08:40:21.000000000 +0200
+@@ -20,18 +20,28 @@
+ slouken@devolution.com
+ */
+
+-import SDL_types;
+-import SDL_getenv;
+-import SDL_error;
+-import SDL_rwops;
+-import SDL_timer;
+-import SDL_audio;
+-import SDL_cdrom;
+-import SDL_joystick;
+-import SDL_events;
+-import SDL_video;
+-import SDL_byteorder;
+-import SDL_Version;
++public import SDL_keysym_;
++public import SDL_version_;
++public import SDL_active;
++public import SDL_audio;
++public import SDL_byteorder;
++public import SDL_cdrom;
++public import SDL_copying;
++public import SDL_endian;
++public import SDL_error;
++public import SDL_events;
++public import SDL_getenv;
++public import SDL_joystick;
++public import SDL_keyboard;
++public import SDL_mouse;
++public import SDL_mutex;
++public import SDL_quit;
++public import SDL_rwops;
++public import SDL_syswm;
++public import SDL_thread;
++public import SDL_timer;
++public import SDL_types;
++public import SDL_video;
+
+ extern(C):
+
+@@ -73,20 +83,3 @@
+ */
+ void SDL_Quit();
+
+-/+
+-void SDL_SetModuleHandle(void *hInst);
+-extern(Windows) void* GetModuleHandle(char*);
+-
+-static this()
+-{
+- /* Load SDL dynamic link library */
+- if (SDL_Init(SDL_INIT_NOPARACHUTE) < 0)
+- throw new Error("Error loading SDL");
+- SDL_SetModuleHandle(GetModuleHandle(null));
+-}
+-
+-static ~this()
+-{
+- SDL_Quit();
+-}
+-+/
+diff -Naur vr/import/SDL_events.d vr-gentoo/import/SDL_events.d
+--- vr/import/SDL_events.d 2005-03-14 01:15:04.000000000 +0100
++++ vr-gentoo/import/SDL_events.d 2007-09-20 08:40:21.000000000 +0200
+@@ -304,8 +304,8 @@
+ If 'state' is set to SDL_QUERY, SDL_EventState() w