# Copyright (C) 2006, by Miriam Ruiz <little_miry@yahoo.es>
# Distributed under the same license as the game. See debian/copyright.  

diff -ruN holotz-castle-1.3.8.orig/src/HCCharacter.cpp holotz-castle-1.3.8.new/src/HCCharacter.cpp
--- holotz-castle-1.3.8.orig/src/HCCharacter.cpp	2006-01-20 13:59:38.000000000 +0100
+++ holotz-castle-1.3.8.new/src/HCCharacter.cpp	2006-09-23 15:58:27.000000000 +0200
@@ -873,10 +873,10 @@
 u32 HCCharacter::Load(JRW &file)
 {
 	if (0 == file.ReadLE32(&subtype) ||
-			0 == file.ReadLE32((u32 *)&pos.x) ||
-			0 == file.ReadLE32((u32 *)&pos.y) ||
-			0 == file.ReadLE32((u32 *)&vMax.x) ||
-			0 == file.ReadLE32((u32 *)&vMax.y) ||
+			0 == file.ReadLE32(&pos.x) ||
+			0 == file.ReadLE32(&pos.y) ||
+			0 == file.ReadLE32(&vMax.x) ||
+			0 == file.ReadLE32(&vMax.y) ||
 			0 == file.ReadLE32(&maxJumpRows))
 	{
 		fprintf(stderr, "Error reading character's common parameters.\n");
@@ -891,10 +891,10 @@
 u32 HCCharacter::Save(JRW &file)
 {
 	if (0 == file.WriteLE32(&subtype) ||
-			0 == file.WriteLE32((u32 *)&pos.x) ||
-			0 == file.WriteLE32((u32 *)&pos.y) ||
-			0 == file.WriteLE32((u32 *)&vMax.x) ||
-			0 == file.WriteLE32((u32 *)&vMax.y) ||
+			0 == file.WriteLE32(&pos.x) ||
+			0 == file.WriteLE32(&pos.y) ||
+			0 == file.WriteLE32(&vMax.x) ||
+			0 == file.WriteLE32(&vMax.y) ||
 			0 == file.WriteLE32(&maxJumpRows))
 	{
 		fprintf(stderr, "Error writing character's common parameters.\n");
diff -ruN holotz-castle-1.3.8.orig/src/HCLevel.cpp holotz-castle-1.3.8.new/src/HCLevel.cpp
--- holotz-castle-1.3.8.orig/src/HCLevel.cpp	2006-01-20 13:59:38.000000000 +0100
+++ holotz-castle-1.3.8.new/src/HCLevel.cpp	2006-09-23 15:58:27.000000000 +0200
@@ -406,7 +406,7 @@
 
 		for (s32 i = 0; i < numEnemies; ++i)
 		{
-			if (0 != file.ReadLE32((s32 *)&enemyType))
+			if (0 != file.ReadLE32(&enemyType))
 			{
         // Lets the file at ist original position
         file.Seek(-4, SEEK_CUR);
diff -ruN holotz-castle-1.3.8.orig/src/HCMap.cpp holotz-castle-1.3.8.new/src/HCMap.cpp
--- holotz-castle-1.3.8.orig/src/HCMap.cpp	2006-01-20 13:59:38.000000000 +0100
+++ holotz-castle-1.3.8.new/src/HCMap.cpp	2006-09-23 15:58:27.000000000 +0200
@@ -387,7 +387,7 @@
 	Destroy();
 
 	// Loads the number of rows and cols, etc.
-	if (0 == f.ReadLE32((u32 *)&gravity) ||
+	if (0 == f.ReadLE32(&gravity) ||
 			0 == f.ReadLE32(&rows) ||
 			0 == f.ReadLE32(&cols) ||
 			0 == f.ReadLE32(&exitRow) ||
@@ -472,7 +472,7 @@
 u32 HCMap::Save(JRW &f)
 {
 	// Saves the number of rows and cols, etc.
-	if (0 == f.WriteLE32((u32 *)&gravity) ||
+	if (0 == f.WriteLE32(&gravity) ||
 			0 == f.WriteLE32(&rows) ||
 			0 == f.WriteLE32(&cols) ||
 			0 == f.WriteLE32(&exitRow) ||
diff -ruN holotz-castle-1.3.8.orig/src/HCObject.cpp holotz-castle-1.3.8.new/src/HCObject.cpp
--- holotz-castle-1.3.8.orig/src/HCObject.cpp	2006-01-20 13:59:38.000000000 +0100
+++ holotz-castle-1.3.8.new/src/HCObject.cpp	2006-09-23 15:58:27.000000000 +0200
@@ -82,8 +82,8 @@
 u32 HCObject::Load(JRW &file)
 {
 	if (0 == file.ReadLE32(&subtype) ||
-			0 == file.ReadLE32((u32 *)&pos.x) ||
-			0 == file.ReadLE32((u32 *)&pos.y))
+			0 == file.ReadLE32(&pos.x) ||
+			0 == file.ReadLE32(&pos.y))
 	{
 		fprintf(stderr, "Error loading the object.\n");
 			
@@ -98,8 +98,8 @@
 u32 HCObject::Save(JRW &file)
 {
 	if (0 == file.WriteLE32(&subtype) ||
-			0 == file.WriteLE32((u32 *)&pos.x) ||
-			0 == file.WriteLE32((u32 *)&pos.y))
+			0 == file.WriteLE32(&pos.x) ||
+			0 == file.WriteLE32(&pos.y))
 	{
 		fprintf(stderr, "Error saving the object.\n");
 			
diff -ruN holotz-castle-1.3.8.orig/src/HCRope.cpp holotz-castle-1.3.8.new/src/HCRope.cpp
--- holotz-castle-1.3.8.orig/src/HCRope.cpp	2006-01-20 13:59:38.000000000 +0100
+++ holotz-castle-1.3.8.new/src/HCRope.cpp	2006-09-23 15:58:27.000000000 +0200
@@ -127,12 +127,12 @@
 
 u32 HCRope::Load(JRW &file)
 {
-	if (0 == file.ReadLE32((u32 *)&period) ||
+	if (0 == file.ReadLE32(&period) ||
 			0 == file.ReadLE32(&amplitude) ||
 			0 == file.ReadLE32(&length) ||
 			0 == file.ReadLE32(&subtype) ||
-			0 == file.ReadLE32((u32 *)&pos.x) ||
-			0 == file.ReadLE32((u32 *)&pos.y))
+			0 == file.ReadLE32(&pos.x) ||
+			0 == file.ReadLE32(&pos.y))
 	{
 		fprintf(stderr, "Error reading rope parameters.\n");
 		
@@ -161,12 +161,12 @@
 
 u32 HCRope::Save(JRW &file)
 {
-	if (0 == file.WriteLE32((u32 *)&period) ||
+	if (0 == file.WriteLE32(&period) ||
 			0 == file.WriteLE32(&amplitude) ||
 			0 == file.WriteLE32(&length) ||
 			0 == file.WriteLE32(&subtype) ||
-			0 == file.WriteLE32((u32 *)&pos.x) ||
-			0 == file.WriteLE32((u32 *)&pos.y))
+			0 == file.WriteLE32(&pos.x) ||
+			0 == file.WriteLE32(&pos.y))
 	{
 		fprintf(stderr, "Error writing rope parameters.\n");
 		
