summaryrefslogtreecommitdiff
path: root/games/xjig/files/patch-objects.C
diff options
context:
space:
mode:
authorAdam Weinberger <adamw@FreeBSD.org>2014-07-28 19:39:50 +0000
committerAdam Weinberger <adamw@FreeBSD.org>2014-07-28 19:39:50 +0000
commitd9616e5a763d1ab83ebac479e3b2222db5c3f87f (patch)
treea08c8f6002f7c1660aaa80e0f9cf61cd9d71151c /games/xjig/files/patch-objects.C
parent- Update to 1.9, announce message: (diff)
Rename all 10,000 games/ patch-xy patches to reflect the files they modify.
Notes
Notes: svn path=/head/; revision=363239
Diffstat (limited to 'games/xjig/files/patch-objects.C')
-rw-r--r--games/xjig/files/patch-objects.C60
1 files changed, 60 insertions, 0 deletions
diff --git a/games/xjig/files/patch-objects.C b/games/xjig/files/patch-objects.C
new file mode 100644
index 000000000000..c05d5e3e760f
--- /dev/null
+++ b/games/xjig/files/patch-objects.C
@@ -0,0 +1,60 @@
+--- objects.C.orig Wed Jul 24 15:06:28 1996
++++ objects.C Tue Apr 7 15:34:33 1998
+@@ -533,28 +533,30 @@
+ }
+
+ #define DATA_TYPE CARD32
+-#define DATA_PAD 4
+ void PixmapPiece::CreateTilemap32() {
+ # include "rotate.H"
+ }
+ #undef DATA_TYPE
+-#undef DATA_PAD
++
++#define CARD24 long
++
++#define DATA_TYPE CARD24
++void PixmapPiece::CreateTilemap24() {
++# include "rotate.H"
++}
++#undef DATA_TYPE
+
+ #define DATA_TYPE CARD16
+-#define DATA_PAD 2
+ void PixmapPiece::CreateTilemap16() {
+ # include "rotate.H"
+ }
+ #undef DATA_TYPE
+-#undef DATA_PAD
+
+ #define DATA_TYPE CARD8
+-#define DATA_PAD 1
+ void PixmapPiece::CreateTilemap8() {
+ # include "rotate.H"
+ }
+ #undef DATA_TYPE
+-#undef DATA_PAD
+
+
+ void PixmapPiece::DirectionChanged() {
+@@ -573,10 +575,16 @@
+ XPix(wcenter.X())-offx, YPix(wcenter.Y())-offy, width, height, 0, 0 );
+ }
+ else {
+- switch(texture_mode) {
+- case 1: CreateTilemap8(); break;
+- case 2: CreateTilemap16(); break;
+- case 3: CreateTilemap32(); break;
++ extern int pixmap_depth;
++
++ switch(pixmap_depth) {
++ case 8: CreateTilemap8(); break;
++ case 16: CreateTilemap16(); break;
++ case 32: CreateTilemap32(); break;
++ case 24: CreateTilemap24(); break;
++ default:
++ fprintf(stderr,"unhandled depth = %d\n",pixmap_depth);
++ exit(1);
+ }
+ }
+ }