Репозиторий Sisyphus
Последнее обновление: 1 октября 2023 | Пакетов: 18631 | Посещений: 37509259
en ru br
Репозитории ALT
5.1: 0.92-alt1
4.1: 0.91-alt1.qa1
www.altlinux.org/Changes

Группа :: Игры/Аркады
Пакет: tecnoballz

 Главная   Изменения   Спек   Патчи   Sources   Загрузить   Gear   Bugs and FR  Repocop 

Патч: tecnoballz-0.91-64-bit.patch
Скачать


--- tecnoballz-0.91/src/fond_ecran.cc~	2007-03-25 22:56:14.000000000 +0200
+++ tecnoballz-0.91/src/fond_ecran.cc	2007-03-25 22:56:14.000000000 +0200
@@ -133,8 +133,8 @@
 	// display background map 
 	//###############################################################
 	Sint32 src_X = 0;
-	Sint32 h = (Sint32)ecran;	//use pointer address as random value
-	Sint32 k = (Sint32)fonds;	//use pointer address as random value
+	Sint32 h = (Sint32)((long)ecran);	//use pointer address as random value
+	Sint32 k = (Sint32)((long)fonds);	//use pointer address as random value
 	Sint32 nline;
 	if(mVert > 0)
 		nline = mVert;
--- tecnoballz-0.91/src/mentatCode.cc~	2007-03-25 22:58:22.000000000 +0200
+++ tecnoballz-0.91/src/mentatCode.cc	2007-03-25 22:58:22.000000000 +0200
@@ -85,7 +85,7 @@
 {
 	if(is_verbose)
 		printf("mentatCode::first_init() [START]\n");
-	hasard_val = (Sint32)first_init;
+	hasard_val = ((Sint32)(long)first_init);
 	memGestion = new RAM_killer();
 	memGestion->initialise(8000);
 	num_erreur = memGestion->retour_err();
@@ -336,16 +336,16 @@
 		printf("==6 ptScoreTab\n");
 	delete ptScoreTab;
 	if(is_verbose)
-		printf("==7 ecran_gere %x\n", (Sint32)ecran_gere);
+		printf("==7 ecran_gere %p\n", ecran_gere);
 	delete ecran_gere;
 #ifndef SOUNDISOFF
 	if(is_verbose)
-		printf("==8 audiomixer %x\n", (Sint32)ptAudiomix);
+		printf("==8 audiomixer %p\n", ptAudiomix);
 	delete ptAudiomix;
 #endif
 	delete pRessource;
 	if(is_verbose)
-		printf("==9 memGestion %x \n", (Sint32)memGestion);
+		printf("==9 memGestion %p \n", memGestion);
 	delete memGestion;
 	return num_erreur;
 }
--- tecnoballz-0.91/src/RAM_killer.cc~	2007-03-25 23:51:56.000000000 +0200
+++ tecnoballz-0.91/src/RAM_killer.cc	2007-03-25 23:52:44.000000000 +0200
@@ -139,8 +139,8 @@
 	}
 	if(adres)
 	{	adrNoFound++;
-		fprintf(stderr, "RAM_killer::liberation() : %i) address %x not found\n",
-			adrNoFound, (Sint32)adres);
+		fprintf(stderr, "RAM_killer::liberation() : %i) address %p not found\n",
+			adrNoFound, adres);
 	}
 }
 
@@ -155,8 +155,8 @@
 		{	char* adres = memPT->adresseMem;
 			if(adres)
 			{	fprintf(stderr,
-					"RAM_killer::libereTout() : addr:%x; size:%i; id:%x\n",
-					(Sint32)memPT->adresseMem, memPT->taille_mem,
+					"RAM_killer::libereTout() : addr:%p; size:%i; id:%x\n",
+					memPT->adresseMem, memPT->taille_mem,
 					(Sint32)memPT->identifier);
 				free(adres);	//release memory
 				octetTotal -= memPT->taille_mem;
@@ -166,8 +166,7 @@
 			} 
 		}
 		fprintf(stderr,
-			"RAM_killer::libereTout() : remain 10 not released zones\n",
-			mem_nombre);
+			"RAM_killer::libereTout() : remain 10 not released zones\n");
 	}
  	if (adrNoFound)
 		fprintf(stderr,
--- tecnoballz-0.91/src/tecno_boui.cc~	2007-03-25 23:54:57.000000000 +0200
+++ tecnoballz-0.91/src/tecno_boui.cc	2007-03-25 23:54:57.000000000 +0200
@@ -63,7 +63,7 @@
 			{	if(!over_brick(position_x, position_y))
 				{	flag_actif = 1;
 					Sint32 *monPT = ghost_bobs + (hasard_val & 31);
-					hasard_val += (Sint32)this;
+					hasard_val += (Sint32)((long)this);
 					Sint32 k = *monPT;
 					miniOffset = k;
 					animOffset = k;
@@ -190,7 +190,7 @@
 	i *= 2;
 	i &= 31;
 	atom_traje = i;
-	hasard_val += (Sint32)this;
+	hasard_val += (Sint32)((long)this);
 	
 	
 	i = 4 * resolution;
--- tecnoballz-0.91/src/ze_magneye.cc~	2007-03-26 00:16:00.000000000 +0200
+++ tecnoballz-0.91/src/ze_magneye.cc	2007-03-26 00:16:00.000000000 +0200
@@ -69,7 +69,7 @@
 	for(Sint32 i = 0; i < objetTotal; i++)
 	{	techno_eye *ptEye = objetListe[i];
 		ptEye->centerPosx = Xcoordinat[hval & 31]  * resolution;
-		hval += (Sint32)ptEye;
+		hval += (Sint32)((long)ptEye);
 		ptEye->centerPosy = Ycoordinat[hval & 31]  * resolution;
 		hval += keyGestion->sourisGetY();
 		ptEye->finishPosx = Xcoordinat[hval & 31]  * resolution;
--- tecnoballz-0.91/src/zeNewBalls.cc~	2007-03-26 00:21:14.000000000 +0200
+++ tecnoballz-0.91/src/zeNewBalls.cc	2007-03-26 00:21:14.000000000 +0200
@@ -416,7 +416,7 @@
 			{	j = balle->directBall;	//ball is moving
 				if(j > 64)
 				{	fprintf(stderr,
-						"zeNewBalls::vitus_move() balle->directBall = %ld\n",
+						"zeNewBalls::vitus_move() balle->directBall = %d\n",
 						j);
 					j = 60;
 				}
@@ -488,7 +488,7 @@
 			{	j = balle->directBall;	//ball is moving
 				if(j > 64)
 				{	fprintf(stderr,
-						"zeNewBalls::vitus_move() balle->directBall = %ld\n",
+						"zeNewBalls::vitus_move() balle->directBall = %d\n",
 						j);
 					j = 60;
 				}
@@ -628,8 +628,8 @@
 					j = balle->directBall;
 					//(char *)monPT += j;
 					monPT = (Sint32 *)((char *)monPT + j); 
-					printf("monPT = %x / bumpX->rebonds_GD = %x / *monPT = %i\n",
-						(Sint32)monPT, (Sint32)bumpX->rebonds_GD, *monPT);
+					printf("monPT = %p / bumpX->rebonds_GD = %p / *monPT = %i\n",
+						monPT, bumpX->rebonds_GD, *monPT);
 					
 					printf("%i %i\n", bumpX->rebonds_GD[16], bumpX->rebonds_GD[64]);
 					j = 60;
--- tecnoballz-0.91/src/tecno_gads.cc~	2007-03-26 14:11:25.000000000 +0200
+++ tecnoballz-0.91/src/tecno_gads.cc	2007-03-26 14:11:25.000000000 +0200
@@ -71,7 +71,7 @@
 	const Sint16 *p = gagdetBrik + nuGad;
 	if (*p < 0)
 	{	fprintf(stderr,
-			"tecno_gads::nouveauGad() : nuGad = %ld, no used ! \n", nuGad);
+			"tecno_gads::nouveauGad() : nuGad = %d, no used ! \n", nuGad);
 		return;
 	}
 	flag_actif = 1;
@@ -103,7 +103,7 @@
 	const Sint16 *p = gagdetBrik + nuGad;
 	if (*p < 0)
 	{	fprintf(stderr,
-			"tecno_gads::nouveauGad() : nuGad = %ld, no used ! \n", nuGad);
+			"tecno_gads::nouveauGad() : nuGad = %d, no used ! \n", nuGad);
 		return;
 	}
 	flag_actif = 1;
@@ -135,7 +135,7 @@
 	const Sint16 *p = gagdetBrik + nuGad;
 	if (*p < 0)
 	{	fprintf(stderr,
-			"tecno_gads::nouveauGad() : nuGad = %ld, no used ! \n", nuGad);
+			"tecno_gads::nouveauGad() : nuGad = %d, no used ! \n", nuGad);
 		return;
 	}
 	flag_actif = 1;
@@ -166,7 +166,7 @@
 	const Sint16 *p = gagdetBrik + nuGad;
 	if (*p < 0)
 	{	fprintf(stderr,
-			"tecno_gads::nouveauGad() : nuGad = %ld, no used ! \n", nuGad);
+			"tecno_gads::nouveauGad() : nuGad = %d, no used ! \n", nuGad);
 		return;
 	}
 	flag_actif = 1;
@@ -199,7 +199,7 @@
 	const Sint16 *p = gagdetGuar + nuGad;
 	if (*p < 0)
 	{	fprintf(stderr,
-			"tecno_gads::nouveauGad() : nuGad = %ld, no used ! \n", nuGad);
+			"tecno_gads::nouveauGad() : nuGad = %d, no used ! \n", nuGad);
 		return;
 	}
 	flag_actif = 1;
--- tecnoballz-0.91/src/scrolledit.cc~	2007-03-26 14:10:19.000000000 +0200
+++ tecnoballz-0.91/src/scrolledit.cc	2007-03-26 14:10:19.000000000 +0200
@@ -657,7 +657,7 @@
 			table += (brush_posx / defilement->motiflarge);
 
 			printf("scrolledit::brush_draw() : (table - carteFirst):%i /  i:%i\n",
-				(table - defilement->carteFirst), i);
+				(int)(table - defilement->carteFirst), i);
 			
 			
 			for(i = 0; i < brushHeigh; i++)
--- tecnoballz-0.91/src/configfile.cc~	2007-03-26 14:09:34.000000000 +0200
+++ tecnoballz-0.91/src/configfile.cc	2007-03-26 14:09:34.000000000 +0200
@@ -82,7 +82,7 @@
 {
 	fprintf(stdout, "  <config info>\n"
 			"- optionfull : %i\n- audioactif: %i\n- resolution:%i\n"
-		"- is_verbose: %i\n hardChoice : %i\n lang:%s\n", 
+		"- is_verbose: %i\n hardChoice : %i\n", 
 		ecran_hard::optionfull, audiomixer::audioactif, resolution, is_verbose, hardChoice);
 }
 
--- tecnoballz-0.91/src/BOB_killer.cc~	2007-03-26 14:26:38.000000000 +0200
+++ tecnoballz-0.91/src/BOB_killer.cc	2007-03-26 14:34:17.000000000 +0200
@@ -271,18 +271,18 @@
 	// reserve la table de pointeur sur les tables d'affichage
 
 	// tables of offsets and counters (words and bytes)
-	BOBtableP1 = (Sint16 **)(memGestion->reserveMem(sizeof(Sint32) * animationN, 0x424F4250));
+	BOBtableP1 = (Sint16 **)(memGestion->reserveMem(sizeof(long) * animationN, 0x424F4250));
 	error_init(memGestion->retour_err());
 	if(erreur_num) return erreur_num;
 
 	// tables of data (pixels of the sprite)
-	BOBtableP2 = (char **)(memGestion->reserveMem(sizeof(Sint32) * animationN, 0x424F4250));
+	BOBtableP2 = (char **)(memGestion->reserveMem(sizeof(long) * animationN, 0x424F4250));
 	error_init(memGestion->retour_err());
 	if(erreur_num) return erreur_num;
 
 	// tables of offsets and counters (byte peer byte)
 	if(fTableByte) 
-	{	BOBtableP3 = (Sint16 **)(memGestion->reserveMem(sizeof(Sint32) * animationN, 0x424F4250));
+	{	BOBtableP3 = (Sint16 **)(memGestion->reserveMem(sizeof(long) * animationN, 0x424F4250));
 		error_init(memGestion->retour_err());
 		if(erreur_num) return erreur_num;
 	}	
@@ -357,7 +357,7 @@
 	// table giving address of each BOBs into BOBs page 
 	//###################################################################
 	adresseTAB = (char **)
-		(memGestion->reserveMem(sizeof(Sint32) * animationN, 0x424F4250));
+		(memGestion->reserveMem(sizeof(long) * animationN, 0x424F4250));
 	error_init(memGestion->retour_err());
 	if(erreur_num) return erreur_num;
 	offsetSrce = image->GFX_modulo(BOBlargeur);
--- tecnoballz-0.91.orig/src/audiomixer.cc	2005-03-01 15:15:08.000000000 +0100
+++ tecnoballz-0.91/src/audiomixer.cc	2007-03-26 15:26:51.000000000 +0200
@@ -309,6 +309,18 @@
 	}
 }
 
+/* LALALA dirty dirty dirty, in playModule() below we want to access the
+   pointer to the mikmod struct in the PRIVATE / layout not exported Mix_Music
+   struct returned by Mix_LoadMUS. In order todo this in a portable way, we
+   declare part of that struct ourselves here */
+extern "C" {
+	struct _Mix_Music {
+		Mix_MusicType type;
+		MODULE *module;
+		/* more stuff we're not interested in */
+	};
+}
+
 //------------------------------------------------------------------------------
 // play a module
 // input => audio	: 1 = sound actif
@@ -349,8 +362,7 @@
 			SDL_GetError());
 		return (erreur_num = E_SDLMIXER);
 	}
-	Sint32 *p = (Sint32 *)pMixmodule;
-	ptModAmiga = (MODULE *)p[1];
+	ptModAmiga = pMixmodule->module;
 
 
 	//###################################################################
 
дизайн и разработка: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
текущий майнтейнер: Michael Shigorin