From 2859b647026af1a927d1a74100f125bbc0f77db3 Mon Sep 17 00:00:00 2001 From: Max Horn Date: Sat, 22 Jul 2006 17:28:48 +0000 Subject: Fix struct packing issues (macros are not resolve in #pragma params, at least for GCC) svn-id: r23569 --- engines/sword1/mouse.h | 8 ++------ engines/sword1/object.h | 8 ++------ engines/sword1/router.h | 8 ++------ engines/sword1/sworddefs.h | 8 ++------ 4 files changed, 8 insertions(+), 24 deletions(-) (limited to 'engines/sword1') diff --git a/engines/sword1/mouse.h b/engines/sword1/mouse.h index 78833362df..c57cab8417 100644 --- a/engines/sword1/mouse.h +++ b/engines/sword1/mouse.h @@ -48,9 +48,7 @@ struct MouseObj { Object *compact; }; -#if defined(START_PACK_STRUCTS) -#pragma START_PACK_STRUCTS -#endif +#include // START STRUCT PACKING struct MousePtr { uint16 numFrames; @@ -61,9 +59,7 @@ struct MousePtr { uint8 dummyData[0x30]; }; -#if defined(END_PACK_STRUCTS) -#pragma END_PACK_STRUCTS -#endif +#include // END STRUCT PACKING class Logic; class Menu; diff --git a/engines/sword1/object.h b/engines/sword1/object.h index be1d6017ee..4ab4b735a3 100644 --- a/engines/sword1/object.h +++ b/engines/sword1/object.h @@ -32,9 +32,7 @@ namespace Sword1 { #define O_GRID_SIZE 200 #define EXTRA_GRID_SIZE 20 -#if defined(START_PACK_STRUCTS) -#pragma START_PACK_STRUCTS -#endif +#include // START STRUCT PACKING struct OEventSlot { //receiving event list in the compact - int32 o_event; //array of these with O_TOTAL_EVENTS elements @@ -120,9 +118,7 @@ struct Object { // mega size = 12340 bytes (+ 8 byte offset table + 20 byte header = 12368) }; -#if defined(END_PACK_STRUCTS) -#pragma END_PACK_STRUCTS -#endif +#include // END STRUCT PACKING } // End of namespace Sword1 diff --git a/engines/sword1/router.h b/engines/sword1/router.h index 9847cee499..12b8714860 100644 --- a/engines/sword1/router.h +++ b/engines/sword1/router.h @@ -27,9 +27,7 @@ namespace Sword1 { -#if defined(START_PACK_STRUCTS) -#pragma START_PACK_STRUCTS -#endif +#include // START STRUCT PACKING struct BarData { int16 x1; @@ -53,9 +51,7 @@ struct NodeData { int16 dist; }; -#if defined(END_PACK_STRUCTS) -#pragma END_PACK_STRUCTS -#endif +#include // END STRUCT PACKING struct FloorData { int32 nbars; diff --git a/engines/sword1/sworddefs.h b/engines/sword1/sworddefs.h index 600dfc668a..b060796655 100644 --- a/engines/sword1/sworddefs.h +++ b/engines/sword1/sworddefs.h @@ -89,9 +89,7 @@ namespace Sword1 { #define MAX_text_obs 2 //text compacts #define TEXT_sect 149 //text compacts exist in section 149, probably after all the megas -#if defined(START_PACK_STRUCTS) -#pragma START_PACK_STRUCTS -#endif +#include // START STRUCT PACKING struct Header { char type[6]; @@ -134,9 +132,7 @@ struct WalkGridHeader { int32 numNodes; }; -#if defined(END_PACK_STRUCTS) -#pragma END_PACK_STRUCTS -#endif +#include // END STRUCT PACKING enum fileTypes { TYPE_CD1 = 0, -- cgit v1.2.3