CnC_Remastered_Collection

Command and Conquer: Red Alert
Log | Files | Refs | README | LICENSE

BDATA.CPP (200432B)


      1 //
      2 // Copyright 2020 Electronic Arts Inc.
      3 //
      4 // TiberianDawn.DLL and RedAlert.dll and corresponding source code is free 
      5 // software: you can redistribute it and/or modify it under the terms of 
      6 // the GNU General Public License as published by the Free Software Foundation, 
      7 // either version 3 of the License, or (at your option) any later version.
      8 
      9 // TiberianDawn.DLL and RedAlert.dll and corresponding source code is distributed 
     10 // in the hope that it will be useful, but with permitted additional restrictions 
     11 // under Section 7 of the GPL. See the GNU General Public License in LICENSE.TXT 
     12 // distributed with this program. You should have received a copy of the 
     13 // GNU General Public License along with permitted additional restrictions 
     14 // with this program. If not, see https://github.com/electronicarts/CnC_Remastered_Collection
     15 
     16 /* $Header: /CounterStrike/BDATA.CPP 2     3/03/97 10:37p Joe_bostic $ */
     17 /***********************************************************************************************
     18  ***              C O N F I D E N T I A L  ---  W E S T W O O D  S T U D I O S               ***
     19  ***********************************************************************************************
     20  *                                                                                             *
     21  *                 Project Name : Command & Conquer                                            *
     22  *                                                                                             *
     23  *                    File Name : BDATA.CPP                                                    *
     24  *                                                                                             *
     25  *                   Programmer : Joe L. Bostic                                                *
     26  *                                                                                             *
     27  *                   Start Date : September 10, 1993                                           *
     28  *                                                                                             *
     29  *                  Last Update : October 2, 1996 [JLB]                                        *
     30  *                                                                                             *
     31  *---------------------------------------------------------------------------------------------*
     32  * Functions:                                                                                  *
     33  *   BuildingTypeClass::As_Reference -- Fetches reference to the building type specified.      *
     34  *   BuildingTypeClass::Bib_And_Offset -- Determines the bib and appropriate cell offset.      *
     35  *   BuildingTypeClass::BuildingTypeClass -- This is the constructor for the building types.   *
     36  *   BuildingTypeClass::Coord_Fixup -- Adjusts coordinate to be legal for assignment.          *
     37  *   BuildingTypeClass::Cost_Of -- Fetches the cost of this building.                          *
     38  *   BuildingTypeClass::Create_And_Place -- Creates and places a building object onto the map. *
     39  *   BuildingTypeClass::Create_One_Of -- Creates a building of this type.                      *
     40  *   BuildingTypeClass::Dimensions -- Fetches the pixel dimensions of the building.            *
     41  *   BuildingTypeClass::Display -- Renders a generic view of building.                         *
     42  *   BuildingTypeClass::Flush_For_Placement -- Tries to clear placement area for this building *
     43  *   BuildingTypeClass::Full_Name -- Fetches the name to give this building.                   *
     44  *   BuildingTypeClass::Height -- Determines the height of the building in icons.              *
     45  *   BuildingTypeClass::Init -- Performs theater specific initialization.                      *
     46  *   BuildingTypeClass::Init_Anim -- Initialize an animation control for a building.           *
     47  *   BuildingTypeClass::Init_Heap -- Initialize the heap as necessary for the building type obj*
     48  *   BuildingTypeClass::Max_Pips -- Determines the maximum pips to display.                    *
     49  *   BuildingTypeClass::Occupy_List -- Fetches the occupy list for the building.               *
     50  *   BuildingTypeClass::One_Time -- Performs special one time action for buildings.            *
     51  *   BuildingTypeClass::Overlap_List -- Fetches the overlap list for the building.             *
     52  *   BuildingTypeClass::Prep_For_Add -- Prepares scenario editor for adding an object.         *
     53  *   BuildingTypeClass::Raw_Cost -- Fetches the raw (base) cost of this building type.         *
     54  *   BuildingTypeClass::Read_INI -- Fetch building type data from the INI database.            *
     55  *   BuildingTypeClass::Width -- Determines width of building in icons.                        *
     56  *   BuildingTypeClass::operator delete -- Deletes a building type object from the special heap*
     57  *   BuildingTypeClass::operator new -- Allocates a building type object from the special heap.*
     58  * - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - */
     59 
     60 #include	"function.h"
     61 
     62 
     63 #define FATSHIP
     64 
     65 #define	MCW	MAP_CELL_W
     66 
     67 #define XYCELL(x,y)	(y*MAP_CELL_W+x)
     68 static short const ExitPyle[] = {
     69 	XYCELL(1,2),
     70 	XYCELL(2,2),
     71 	XYCELL(0,2),
     72 	XYCELL(-1,2),
     73 	XYCELL(-1,-1),
     74 	XYCELL(0,-1),
     75 	XYCELL(1,-1),
     76 	XYCELL(2,-1),
     77 	XYCELL(2,-1),
     78 	XYCELL(-1,0),
     79 	XYCELL(2,0),
     80 	XYCELL(2,1),
     81 	XYCELL(-1,1),
     82 	REFRESH_EOL
     83 };
     84 
     85 static short const ExitSub[] = {
     86 	XYCELL( 0, 2),
     87 	XYCELL( 2, 2),
     88 	XYCELL(-1, 2),
     89 	XYCELL( 1, 2),
     90 	XYCELL( 3, 2)
     91 };
     92 
     93 static short const ExitWeap[] = {
     94 	XYCELL(1,2),
     95 	XYCELL(-1,3),
     96 	XYCELL(0,3),
     97 	XYCELL(1,3),
     98 	XYCELL(-2,3),
     99 	XYCELL(2,3),
    100 	REFRESH_EOL
    101 };
    102 
    103 static short const ComList[] = {0, 1, MCW, MCW+1, REFRESH_EOL};
    104 static short const List000111111[] = {(MCW*1), (MCW*1)+1, (MCW*1)+2, (MCW*2), (MCW*2)+1, (MCW*2)+2, REFRESH_EOL};
    105 static short const List0010[] = {MCW, REFRESH_EOL};
    106 static short const List0011[] = {(MCW*1), (MCW*1)+1, REFRESH_EOL};
    107 static short const List010111100[] = {1, (MCW*1), (MCW*1)+1, (MCW*1)+2, (MCW*2), REFRESH_EOL};
    108 static short const List0111[] = {1, (MCW*1), (MCW*1)+1, REFRESH_EOL};
    109 static short const List1000[] = {0, REFRESH_EOL};
    110 static short const List101000011[] = {0, 2, (MCW*2)+1, (MCW*2)+2, REFRESH_EOL};
    111 static short const List1100[] = {0, 1, REFRESH_EOL};
    112 static short const List1101[] = {0, 1, (MCW*1)+1, REFRESH_EOL};
    113 static short const List11[] = {0, 1, REFRESH_EOL};
    114 static short const List12[] = {MCW, REFRESH_EOL};
    115 static short const List1[] = {0, REFRESH_EOL};
    116 static short const List21[] = {0, 1, REFRESH_EOL};
    117 static short const List22[] = {0, 1, MCW, MCW+1, REFRESH_EOL};
    118 static short const List22_0011[] = {MCW, MCW+1, REFRESH_EOL};
    119 static short const List22_1100[] = {0, 1, REFRESH_EOL};
    120 static short const List2[] = {0, 1, MCW+1, MCW, REFRESH_EOL};
    121 static short const List32[] = {0, 1, 2, MCW, MCW+1, MCW+2, REFRESH_EOL};
    122 //static short const List42[] = {0, 1, 2, 3, MCW, MCW+1, MCW+2, MCW+3, REFRESH_EOL};
    123 static short const ListFix[] = {1, MCW, MCW+1, MCW+2, MCW+MCW+1, REFRESH_EOL};
    124 static short const ListWeap[] = {0, 1, 2, (MCW*1), (MCW*1)+1, (MCW*1)+2, REFRESH_EOL};
    125 static short const ListWestwood[] = {1, 2, 3, MCW+1, MCW+2, MCW+3, REFRESH_EOL};
    126 static short const OListSAM[] = {-MCW, -(MCW-1), REFRESH_EOL};
    127 #ifdef FATSHIP
    128 static short const ListSPen[] = {0, 1, 2, MCW, MCW+1, MCW+2, MCW+MCW, MCW+MCW+1, MCW+MCW+2, REFRESH_EOL};
    129 static short const OListSPen[] = {REFRESH_EOL};
    130 #else
    131 static short const ListSPen[] = {1, MCW, MCW+1, MCW+2, MCW+MCW+1, REFRESH_EOL};
    132 static short const OListSPen[] = {0, 2, MCW+MCW, MCW+MCW+2, REFRESH_EOL};
    133 #endif
    134 static short const OListWestwood[] = {0, MCW, REFRESH_EOL};
    135 static short const StoreList[] = {0, REFRESH_EOL};
    136 
    137 static short const ListFactory[] = {0, 1, 2, (MCW*1), (MCW*1)+1, (MCW*1)+2, (MCW*2), (MCW*2)+1, (MCW*2)+2, REFRESH_EOL};
    138 
    139 static short const OListFix[] = {0, 2, MCW+MCW, MCW+MCW+2, REFRESH_EOL};
    140 static short const OListWeap[] = {REFRESH_EOL};
    141 static short const OComList[] = {1, REFRESH_EOL};
    142 static short const OList12[] = {0, REFRESH_EOL};
    143 static short const OListTmpl[] = {0, 1, 2, REFRESH_EOL};
    144 
    145 
    146 /***************************************************************************
    147 */
    148 static BuildingTypeClass const ClassBarrel(
    149 	STRUCT_BARREL,
    150 	TXT_BARREL,						// NAME:			Short name of the structure.
    151 	"BARL",							// NAME:			Short name of the structure.
    152 	FACING_NONE,					// Foundation direction from center of building.
    153 	XYP_COORD(0,0),				// Exit point for produced units.
    154 	REMAP_ALTERNATE,				// Sidebar remap logic.
    155 	0x0000,							//	Vertical offset.
    156 	0x0000,							// Primary weapon offset along turret centerline.
    157 	0x0000,							// Primary weapon lateral offset along turret centerline.
    158 		false,						// Is this building a fake (decoy?)
    159 		false,						// Animation rate is regulated for constant speed?
    160 		true,							// Always use the given name for the building?
    161 		false,						// Is this a wall type structure?
    162 		true,							// Simple (one frame) damage imagery?
    163 		true,							// Is it invisible to radar?
    164 		true,							// Can the player select this?
    165 		true,							// Is this a legal target for attack or move?
    166 		true,							// Is this an insignificant building?
    167 		false,						// Theater specific graphic image?
    168 		false,						// Does it have a rotating turret?
    169 		false,						// Can the building be color remapped to indicate owner?
    170 	RTTI_NONE,						// The object type produced at this factory.
    171 	DIR_N,							// Starting idle frame to match construction.
    172 	BSIZE_11, 						// SIZE:			Building size.
    173 	NULL,								// Preferred exit cell list.
    174 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    175 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    176 );
    177 
    178 static BuildingTypeClass const ClassBarrel3(
    179 	STRUCT_BARREL3,
    180 	TXT_BARREL,						// NAME:			Short name of the structure.
    181 	"BRL3",							// NAME:			Short name of the structure.
    182 	FACING_NONE,					// Foundation direction from center of building.
    183 	XYP_COORD(0,0),				// Exit point for produced units.
    184 	REMAP_ALTERNATE,				// Sidebar remap logic.
    185 	0x0000,							//	Vertical offset.
    186 	0x0000,							// Primary weapon offset along turret centerline.
    187 	0x0000,							// Primary weapon lateral offset along turret centerline.
    188 		false,						// Is this building a fake (decoy?)
    189 		false,						// Animation rate is regulated for constant speed?
    190 		true,							// Always use the given name for the building?
    191 		false,						// Is this a wall type structure?
    192 		true,							// Simple (one frame) damage imagery?
    193 		true,							// Is it invisible to radar?
    194 		false,						// Can the player select this?
    195 		true,							// Is this a legal target for attack or move?
    196 		true,							// Is this an insignificant building?
    197 		false,						// Theater specific graphic image?
    198 		false,						// Does it have a rotating turret?
    199 		false,						// Can the building be color remapped to indicate owner?
    200 	RTTI_NONE,						// The object type produced at this factory.
    201 	DIR_N,							// Starting idle frame to match construction.
    202 	BSIZE_11, 						// SIZE:			Building size.
    203 	NULL,								// Preferred exit cell list.
    204 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    205 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    206 );
    207 
    208 static BuildingTypeClass const ClassAVMine(
    209 	STRUCT_AVMINE,
    210 	TXT_AVMINE,						// NAME:			Short name of the structure.
    211 	"MINV",							// NAME:			Short name of the structure.
    212 	FACING_NONE,					// Foundation direction from center of building.
    213 	XYP_COORD(0,0),				// Exit point for produced units.
    214 	REMAP_NORMAL,					// Sidebar remap logic.
    215 	0x0000,							//	Vertical offset.
    216 	0x0000,							// Primary weapon offset along turret centerline.
    217 	0x0000,							// Primary weapon lateral offset along turret centerline.
    218 		false,						// Is this building a fake (decoy?)
    219 		false,						// Animation rate is regulated for constant speed?
    220 		false,						// Always use the given name for the building?
    221 		false,						// Is this a wall type structure?
    222 		true,							// Simple (one frame) damage imagery?
    223 		true,							// Is it invisible to radar?
    224 		false,						// Can the player select this?
    225 		false,						// Is this a legal target for attack or move?
    226 		true,							// Is this an insignificant building?
    227 		false,						// Theater specific graphic image?
    228 		false,						// Does it have a rotating turret?
    229 		true,							// Can the building be color remapped to indicate owner?
    230 	RTTI_NONE,						// The object type produced at this factory.
    231 	DIR_N,							// Starting idle frame to match construction.
    232 	BSIZE_11, 						// SIZE:			Building size.
    233 	NULL,								// Preferred exit cell list.
    234 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    235 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    236 );
    237 
    238 static BuildingTypeClass const ClassAPMine(
    239 	STRUCT_APMINE,
    240 	TXT_APMINE,						// NAME:			Short name of the structure.
    241 	"MINP",							// NAME:			Short name of the structure.
    242 	FACING_NONE,					// Foundation direction from center of building.
    243 	XYP_COORD(0,0),				// Exit point for produced units.
    244 	REMAP_NORMAL,					// Sidebar remap logic.
    245 	0x0000,							//	Vertical offset.
    246 	0x0000,							// Primary weapon offset along turret centerline.
    247 	0x0000,							// Primary weapon lateral offset along turret centerline.
    248 		false,						// Is this building a fake (decoy?)
    249 		false,						// Animation rate is regulated for constant speed?
    250 		false,						// Always use the given name for the building?
    251 		false,						// Is this a wall type structure?
    252 		true,							// Simple (one frame) damage imagery?
    253 		true,							// Is it invisible to radar?
    254 		false,						// Can the player select this?
    255 		false,						// Is this a legal target for attack or move?
    256 		true,							// Is this an insignificant building?
    257 		false,						// Theater specific graphic image?
    258 		false,						// Does it have a rotating turret?
    259 		true,							// Can the building be color remapped to indicate owner?
    260 	RTTI_NONE,						// The object type produced at this factory.
    261 	DIR_N,							// Starting idle frame to match construction.
    262 	BSIZE_11, 						// SIZE:			Building size.
    263 	NULL,								// Preferred exit cell list.
    264 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    265 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    266 );
    267 
    268 static BuildingTypeClass const ClassIronCurtain(
    269 	STRUCT_IRON_CURTAIN,
    270 	TXT_IRON_CURTAIN,				// NAME:			Short name of the structure.
    271 	"IRON",							// NAME:			Short name of the structure.
    272 	FACING_S,						// Foundation direction from center of building.
    273 	XYP_COORD(0,0),				// Exit point for produced units.
    274 	REMAP_ALTERNATE,				// Sidebar remap logic.
    275 	0x0000,							//	Vertical offset.
    276 	0x0000,							// Primary weapon offset along turret centerline.
    277 	0x0000,							// Primary weapon lateral offset along turret centerline.
    278 		false,						// Is this building a fake (decoy?)
    279 		true,							// Animation rate is regulated for constant speed?
    280 		false,						// Always use the given name for the building?
    281 		false,						// Is this a wall type structure?
    282 		true,							// Simple (one frame) damage imagery?
    283 		false,						// Is it invisible to radar?
    284 		true,							// Can the player select this?
    285 		true,							// Is this a legal target for attack or move?
    286 		false,						// Is this an insignificant building?
    287 		false,						// Theater specific graphic image?
    288 		false,						// Does it have a rotating turret?
    289 		true,							// Can the building be color remapped to indicate owner?
    290 	RTTI_NONE,						// The object type produced at this factory.
    291 	DIR_N,							// Starting idle frame to match construction.
    292 	BSIZE_22, 						// SIZE:			Building size.
    293 	NULL,								// Preferred exit cell list.
    294 	(short const *)List22_0011,// OCCUPYLIST:	List of active foundation squares.
    295 	(short const *)List22_1100	// OVERLAPLIST:List of overlap cell offset.
    296 );
    297 
    298 static BuildingTypeClass const ClassForwardCom(
    299 	STRUCT_FORWARD_COM,
    300 	TXT_FORWARD_COM,				// NAME:			Short name of the structure.
    301 	"FCOM",							// NAME:			Short name of the structure.
    302 	FACING_S,						// Foundation direction from center of building.
    303 	XYP_COORD(0,0),				// Exit point for produced units.
    304 	REMAP_ALTERNATE,				// Sidebar remap logic.
    305 	0x0000,							//	Vertical offset.
    306 	0x0000,							// Primary weapon offset along turret centerline.
    307 	0x0000,							// Primary weapon lateral offset along turret centerline.
    308 		false,						// Is this building a fake (decoy?)
    309 		true,							// Animation rate is regulated for constant speed?
    310 		false,						// Always use the given name for the building?
    311 		false,						// Is this a wall type structure?
    312 		true,							// Simple (one frame) damage imagery?
    313 		false,						// Is it invisible to radar?
    314 		true,							// Can the player select this?
    315 		true,							// Is this a legal target for attack or move?
    316 		false,						// Is this an insignificant building?
    317 		false,						// Theater specific graphic image?
    318 		false,						// Does it have a rotating turret?
    319 		true,							// Can the building be color remapped to indicate owner?
    320 	RTTI_NONE,						// The object type produced at this factory.
    321 	DIR_N,							// Starting idle frame to match construction.
    322 	BSIZE_22, 						// SIZE:			Building size.
    323 	NULL,								// Preferred exit cell list.
    324 	(short const *)List22_0011,// OCCUPYLIST:	List of active foundation squares.
    325 	(short const *)List22_1100	// OVERLAPLIST:List of overlap cell offset.
    326 );
    327 
    328 static BuildingTypeClass const ClassAdvancedTech(
    329 	STRUCT_ADVANCED_TECH,
    330 	TXT_ADVANCED_TECH,			// NAME:			Short name of the structure.
    331 	"ATEK",							// NAME:			Short name of the structure.
    332 	FACING_NONE,					// Foundation direction from center of building.
    333 	XYP_COORD(0,0),				// Exit point for produced units.
    334 	REMAP_ALTERNATE,				// Sidebar remap logic.
    335 	0x0000,							//	Vertical offset.
    336 	0x0000,							// Primary weapon offset along turret centerline.
    337 	0x0000,							// Primary weapon lateral offset along turret centerline.
    338 		false,						// Is this building a fake (decoy?)
    339 		true,							// Animation rate is regulated for constant speed?
    340 		false,						// Always use the given name for the building?
    341 		false,						// Is this a wall type structure?
    342 		true,							// Simple (one frame) damage imagery?
    343 		false,						// Is it invisible to radar?
    344 		true,							// Can the player select this?
    345 		true,							// Is this a legal target for attack or move?
    346 		false,						// Is this an insignificant building?
    347 		false,						// Theater specific graphic image?
    348 		false,						// Does it have a rotating turret?
    349 		true,							// Can the building be color remapped to indicate owner?
    350 	RTTI_NONE,						// The object type produced at this factory.
    351 	DIR_N,							// Starting idle frame to match construction.
    352 	BSIZE_22, 						// SIZE:			Building size.
    353 	NULL,								// Preferred exit cell list.
    354 	(short const *)List22,		// OCCUPYLIST:	List of active foundation squares.
    355 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    356 );
    357 
    358 static BuildingTypeClass const ClassChronosphere(
    359 	STRUCT_CHRONOSPHERE,
    360 	TXT_CHRONOSPHERE,				// NAME:			Short name of the structure.
    361 	"PDOX",							// NAME:			Short name of the structure.
    362 	FACING_NONE,					// Foundation direction from center of building.
    363 	XYP_COORD(0,0),				// Exit point for produced units.
    364 	REMAP_ALTERNATE,				// Sidebar remap logic.
    365 	0x0000,							//	Vertical offset.
    366 	0x0000,							// Primary weapon offset along turret centerline.
    367 	0x0000,							// Primary weapon lateral offset along turret centerline.
    368 		false,						// Is this building a fake (decoy?)
    369 		true,							// Animation rate is regulated for constant speed?
    370 		false,						// Always use the given name for the building?
    371 		false,						// Is this a wall type structure?
    372 		true,							// Simple (one frame) damage imagery?
    373 		false,						// Is it invisible to radar?
    374 		true,							// Can the player select this?
    375 		true,							// Is this a legal target for attack or move?
    376 		false,						// Is this an insignificant building?
    377 		false,						// Theater specific graphic image?
    378 		false,						// Does it have a rotating turret?
    379 		true,							// Can the building be color remapped to indicate owner?
    380 	RTTI_NONE,						// The object type produced at this factory.
    381 	DIR_N,							// Starting idle frame to match construction.
    382 	BSIZE_22, 						// SIZE:			Building size.
    383 	NULL,								// Preferred exit cell list.
    384 	(short const *)List22,		// OCCUPYLIST:	List of active foundation squares.
    385 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    386 );
    387 
    388 static BuildingTypeClass const ClassWeapon(
    389 	STRUCT_WEAP,
    390 	TXT_WEAPON_FACTORY,			// NAME:			Short name of the structure.
    391 	"WEAP",							// NAME:			Short name of the structure.
    392 	FACING_NONE,					// Foundation direction from center of building.
    393 	XY_Coord(CELL_LEPTON_W+(CELL_LEPTON_W/2), CELL_LEPTON_H),			// Exit point for produced units.
    394 	REMAP_ALTERNATE,				// Sidebar remap logic.
    395 	0x0000,							//	Vertical offset.
    396 	0x0000,							// Primary weapon offset along turret centerline.
    397 	0x0000,							// Primary weapon lateral offset along turret centerline.
    398 		false,						// Is this building a fake (decoy?)
    399 		false,						// Animation rate is regulated for constant speed?
    400 		false,						// Always use the given name for the building?
    401 		false,						// Is this a wall type structure?
    402 		false,						// Simple (one frame) damage imagery?
    403 		false,						// Is it invisible to radar?
    404 		true,							// Can the player select this?
    405 		true,							// Is this a legal target for attack or move?
    406 		false,						// Is this an insignificant building?
    407 		false,						// Theater specific graphic image?
    408 		false,						// Does it have a rotating turret?
    409 		true,							// Can the building be color remapped to indicate owner?
    410 	RTTI_UNITTYPE,					// The object type produced at this factory.
    411 	DIR_N,							// Starting idle frame to match construction.
    412 	BSIZE_32, 						// SIZE:			Building size.
    413 	(short const *)ExitWeap,	// Preferred exit cell list.
    414 	(short const *)ListWeap,	// OCCUPYLIST:	List of active foundation squares.
    415 	(short const *)OListWeap	// OVERLAPLIST:List of overlap cell offset.
    416 );
    417 
    418 static BuildingTypeClass const ClassShipYard(
    419 	STRUCT_SHIP_YARD,
    420 	TXT_SHIP_YARD,					// NAME:			Short name of the structure.
    421 	"SYRD",							// NAME:			Short name of the structure.
    422 	FACING_NONE,					// Foundation direction from center of building.
    423 	XYP_COORD(22+(CELL_PIXEL_W/2), ((CELL_PIXEL_H*2)-(CELL_PIXEL_H/2))),			// Exit point for produced units.
    424 	REMAP_ALTERNATE,				// Sidebar remap logic.
    425 	0x0000,							//	Vertical offset.
    426 	0x0000,							// Primary weapon offset along turret centerline.
    427 	0x0000,							// Primary weapon lateral offset along turret centerline.
    428 		false,						// Is this building a fake (decoy?)
    429 		false,						// Animation rate is regulated for constant speed?
    430 		false,						// Always use the given name for the building?
    431 		false,						// Is this a wall type structure?
    432 		false,						// Simple (one frame) damage imagery?
    433 		false,						// Is it invisible to radar?
    434 		true,							// Can the player select this?
    435 		true,							// Is this a legal target for attack or move?
    436 		false,						// Is this an insignificant building?
    437 		false,						// Theater specific graphic image?
    438 		false,						// Does it have a rotating turret?
    439 		true,							// Can the building be color remapped to indicate owner?
    440 	RTTI_VESSELTYPE,				// The object type produced at this factory.
    441 	DIR_N,							// Starting idle frame to match construction.
    442 	BSIZE_33, 						// SIZE:			Building size.
    443 	NULL,								// Preferred exit cell list.
    444 	(short const *)ListSPen,	// OCCUPYLIST:	List of active foundation squares.
    445 	(short const *)OListSPen	// OVERLAPLIST:List of overlap cell offset.
    446 );
    447 
    448 static BuildingTypeClass const ClassSubPen(
    449 	STRUCT_SUB_PEN,
    450 	TXT_SUB_PEN,					// NAME:			Short name of the structure.
    451 	"SPEN",							// NAME:			Short name of the structure.
    452 	FACING_NONE,					// Foundation direction from center of building.
    453 	XYP_COORD(22+(CELL_PIXEL_W/2), ((CELL_PIXEL_H*2)-(CELL_PIXEL_H/2))),			// Exit point for produced units.
    454 	REMAP_ALTERNATE,				// Sidebar remap logic.
    455 	0x0000,							//	Vertical offset.
    456 	0x0000,							// Primary weapon offset along turret centerline.
    457 	0x0000,							// Primary weapon lateral offset along turret centerline.
    458 		false,						// Is this building a fake (decoy?)
    459 		false,						// Animation rate is regulated for constant speed?
    460 		false,						// Always use the given name for the building?
    461 		false,						// Is this a wall type structure?
    462 		false,						// Simple (one frame) damage imagery?
    463 		false,						// Is it invisible to radar?
    464 		true,							// Can the player select this?
    465 		true,							// Is this a legal target for attack or move?
    466 		false,						// Is this an insignificant building?
    467 		false,						// Theater specific graphic image?
    468 		false,						// Does it have a rotating turret?
    469 		true,							// Can the building be color remapped to indicate owner?
    470 	RTTI_VESSELTYPE,				// The object type produced at this factory.
    471 	DIR_N,							// Starting idle frame to match construction.
    472 	BSIZE_33, 						// SIZE:			Building size.
    473 	(short const *)ExitSub,		// Preferred exit cell list.
    474 	(short const *)ListSPen,	// OCCUPYLIST:	List of active foundation squares.
    475 	(short const *)OListSPen	// OVERLAPLIST:List of overlap cell offset.
    476 );
    477 
    478 static BuildingTypeClass const ClassPillbox(
    479 	STRUCT_PILLBOX,
    480 	TXT_PILLBOX,					// NAME:			Short name of the structure.
    481 	"PBOX",							// NAME:			Short name of the structure.
    482 	FACING_NONE,					// Foundation direction from center of building.
    483 	XYP_COORD(0,0),				// Exit point for produced units.
    484 	REMAP_ALTERNATE,				// Sidebar remap logic.
    485 	0x0010,							//	Vertical offset.
    486 	0x0040,							// Primary weapon offset along turret centerline.
    487 	0x0000,							// Primary weapon lateral offset along turret centerline.
    488 		false,						// Is this building a fake (decoy?)
    489 		false,						// Animation rate is regulated for constant speed?
    490 		false,						// Always use the given name for the building?
    491 		false,						// Is this a wall type structure?
    492 		true,							// Simple (one frame) damage imagery?
    493 		false,						// Is it invisible to radar?
    494 		true,							// Can the player select this?
    495 		true,							// Is this a legal target for attack or move?
    496 		false,						// Is this an insignificant building?
    497 		false,						// Theater specific graphic image?
    498 		false,						// Does it have a rotating turret?
    499 		true,							// Can the building be color remapped to indicate owner?
    500 	RTTI_NONE,						// The object type produced at this factory.
    501 	DIR_N,							// Starting idle frame to match construction.
    502 	BSIZE_11, 						// SIZE:			Building size.
    503 	NULL,								// Preferred exit cell list.
    504 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    505 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    506 );
    507 
    508 static BuildingTypeClass const ClassCamoPillbox(
    509 	STRUCT_CAMOPILLBOX,
    510 	TXT_CAMOPILLBOX,				// NAME:			Short name of the structure.
    511 	"HBOX",							// NAME:			Short name of the structure.
    512 	FACING_NONE,					// Foundation direction from center of building.
    513 	XYP_COORD(0,0),				// Exit point for produced units.
    514 	REMAP_ALTERNATE,				// Sidebar remap logic.
    515 	0x0010,							//	Vertical offset.
    516 	0x0040,							// Primary weapon offset along turret centerline.
    517 	0x0000,							// Primary weapon lateral offset along turret centerline.
    518 		false,						// Is this building a fake (decoy?)
    519 		false,						// Animation rate is regulated for constant speed?
    520 		false,						// Always use the given name for the building?
    521 		false,						// Is this a wall type structure?
    522 		true,							// Simple (one frame) damage imagery?
    523 		false,						// Is it invisible to radar?
    524 		true,							// Can the player select this?
    525 		true,							// Is this a legal target for attack or move?
    526 		false,						// Is this an insignificant building?
    527 		true,							// Theater specific graphic image?
    528 		false,						// Does it have a rotating turret?
    529 		true,							// Can the building be color remapped to indicate owner?
    530 	RTTI_NONE,						// The object type produced at this factory.
    531 	DIR_N,							// Starting idle frame to match construction.
    532 	BSIZE_11, 						// SIZE:			Building size.
    533 	NULL,								// Preferred exit cell list.
    534 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    535 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    536 );
    537 
    538 static BuildingTypeClass const ClassTesla(
    539 	STRUCT_TESLA,
    540 	TXT_TESLA,						// NAME:			Short name of the structure.
    541 	"TSLA",							// NAME:			Short name of the structure.
    542 	FACING_S,						// Foundation direction from center of building.
    543 	XYP_COORD(0,0),				// Exit point for produced units.
    544 	REMAP_ALTERNATE,				// Sidebar remap logic.
    545 	0x00C8,							//	Vertical offset.
    546 	0x0000,							// Primary weapon offset along turret centerline.
    547 	0x0000,							// Primary weapon lateral offset along turret centerline.
    548 		false,						// Is this building a fake (decoy?)
    549 		false,						// Animation rate is regulated for constant speed?
    550 		false,						// Always use the given name for the building?
    551 		false,						// Is this a wall type structure?
    552 		false,						// Simple (one frame) damage imagery?
    553 		false,						// Is it invisible to radar?
    554 		true,							// Can the player select this?
    555 		true,							// Is this a legal target for attack or move?
    556 		false,						// Is this an insignificant building?
    557 		false,						// Theater specific graphic image?
    558 		false,						// Does it have a rotating turret?
    559 		true,							// Can the building be color remapped to indicate owner?
    560 	RTTI_NONE,						// The object type produced at this factory.
    561 	DIR_N,							// Starting idle frame to match construction.
    562 	BSIZE_12, 						// SIZE:			Building size.
    563 	NULL,								// Preferred exit cell list.
    564 	(short const *)List12,		// OCCUPYLIST:	List of active foundation squares.
    565 	(short const *)OList12		// OVERLAPLIST:List of overlap cell offset.
    566 );
    567 
    568 static BuildingTypeClass const ClassTurret(
    569 	STRUCT_TURRET,
    570 	TXT_TURRET,						// NAME:			Short name of the structure.
    571 	"GUN",							// NAME:			Short name of the structure.
    572 	FACING_NONE,					// Foundation direction from center of building.
    573 	XYP_COORD(0,0),				// Exit point for produced units.
    574 	REMAP_ALTERNATE,				// Sidebar remap logic.
    575 	0x0030,							//	Vertical offset.
    576 	0x0080,							// Primary weapon offset along turret centerline.
    577 	0x0000,							// Primary weapon lateral offset along turret centerline.
    578 		false,						// Is this building a fake (decoy?)
    579 		false,						// Animation rate is regulated for constant speed?
    580 		false,						// Always use the given name for the building?
    581 		false,						// Is this a wall type structure?
    582 		false,						// Simple (one frame) damage imagery?
    583 		false,						// Is it invisible to radar?
    584 		true,							// Can the player select this?
    585 		true,							// Is this a legal target for attack or move?
    586 		false,						// Is this an insignificant building?
    587 		false,						// Theater specific graphic image?
    588 		true,							// Does it have a rotating turret?
    589 		true,							// Can the building be color remapped to indicate owner?
    590 	RTTI_NONE,						// The object type produced at this factory.
    591 	(DirType)208,					// Starting idle frame to match construction.
    592 	BSIZE_11, 						// SIZE:			Building size.
    593 	NULL,								// Preferred exit cell list.
    594 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    595 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    596 );
    597 
    598 static BuildingTypeClass const ClassAAGun(
    599 	STRUCT_AAGUN,
    600 	TXT_AAGUN,						// NAME:			Short name of the structure.
    601 	"AGUN",							// NAME:			Short name of the structure.
    602 	FACING_S,						// Foundation direction from center of building.
    603 	XYP_COORD(0,0),				// Exit point for produced units.
    604 	REMAP_ALTERNATE,				// Sidebar remap logic.
    605 	0x0000,							//	Vertical offset.
    606 	0x0000,							// Primary weapon offset along turret centerline.
    607 	0x0000,							// Primary weapon lateral offset along turret centerline.
    608 		false,						// Is this building a fake (decoy?)
    609 		false,						// Animation rate is regulated for constant speed?
    610 		false,						// Always use the given name for the building?
    611 		false,						// Is this a wall type structure?
    612 		false,						// Simple (one frame) damage imagery?
    613 		false,						// Is it invisible to radar?
    614 		true,							// Can the player select this?
    615 		true,							// Is this a legal target for attack or move?
    616 		false,						// Is this an insignificant building?
    617 		false,						// Theater specific graphic image?
    618 		true,							// Does it have a rotating turret?
    619 		true,							// Can the building be color remapped to indicate owner?
    620 	RTTI_NONE,						// The object type produced at this factory.
    621 	DIR_NE,							// Starting idle frame to match construction.
    622 	BSIZE_12, 						// SIZE:			Building size.
    623 	NULL,								// Preferred exit cell list.
    624 	(short const *)List12,		// OCCUPYLIST:	List of active foundation squares.
    625 	(short const *)OList12		// OVERLAPLIST:List of overlap cell offset.
    626 );
    627 
    628 static BuildingTypeClass const ClassFlameTurret(
    629 	STRUCT_FLAME_TURRET,
    630 	TXT_FLAME_TURRET,				// NAME:			Short name of the structure.
    631 	"FTUR",							// NAME:			Short name of the structure.
    632 	FACING_NONE,					// Foundation direction from center of building.
    633 	XYP_COORD(0,0),				// Exit point for produced units.
    634 	REMAP_ALTERNATE,				// Sidebar remap logic.
    635 	0x0000,							//	Vertical offset.
    636 	0x0000,							// Primary weapon offset along turret centerline.
    637 	0x0000,							// Primary weapon lateral offset along turret centerline.
    638 		false,						// Is this building a fake (decoy?)
    639 		false,						// Animation rate is regulated for constant speed?
    640 		false,						// Always use the given name for the building?
    641 		false,						// Is this a wall type structure?
    642 		true,							// Simple (one frame) damage imagery?
    643 		false,						// Is it invisible to radar?
    644 		true,							// Can the player select this?
    645 		true,							// Is this a legal target for attack or move?
    646 		false,						// Is this an insignificant building?
    647 		false,						// Theater specific graphic image?
    648 		false,						// Does it have a rotating turret?
    649 		true,							// Can the building be color remapped to indicate owner?
    650 	RTTI_NONE,						// The object type produced at this factory.
    651 	DIR_N,							// Starting idle frame to match construction.
    652 	BSIZE_11, 						// SIZE:			Building size.
    653 	NULL,								// Preferred exit cell list.
    654 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
    655 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    656 );
    657 
    658 static BuildingTypeClass const ClassConst(
    659 	STRUCT_CONST,
    660 	TXT_CONST_YARD,				// NAME:			Short name of the structure.
    661 	"FACT",							// NAME:			Short name of the structure.
    662 	FACING_NONE,					// Foundation direction from center of building.
    663 	XYP_COORD(0,0),				// Exit point for produced units.
    664 	REMAP_ALTERNATE,				// Sidebar remap logic.
    665 	0x0000,							//	Vertical offset.
    666 	0x0000,							// Primary weapon offset along turret centerline.
    667 	0x0000,							// Primary weapon lateral offset along turret centerline.
    668 		false,						// Is this building a fake (decoy?)
    669 		false,						// Animation rate is regulated for constant speed?
    670 		false,						// Always use the given name for the building?
    671 		false,						// Is this a wall type structure?
    672 		false,						// Simple (one frame) damage imagery?
    673 		false,						// Is it invisible to radar?
    674 		true,							// Can the player select this?
    675 		true,							// Is this a legal target for attack or move?
    676 		false,						// Is this an insignificant building?
    677 		false,						// Theater specific graphic image?
    678 		false,						// Does it have a rotating turret?
    679 		true,							// Can the building be color remapped to indicate owner?
    680 	RTTI_BUILDINGTYPE,			// The object type produced at this factory.
    681 	DIR_N,							// Starting idle frame to match construction.
    682 	BSIZE_33, 						// SIZE:			Building size.
    683 	NULL,								// Preferred exit cell list.
    684 	(short const *)ListFactory,// OCCUPYLIST:	List of active foundation squares.
    685 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    686 );
    687 
    688 static BuildingTypeClass const ClassFakeConst(
    689 	STRUCT_FAKECONST,
    690 	TXT_FAKE_CONST,				// NAME:			Short name of the structure.
    691 	"FACF",							// NAME:			Short name of the structure.
    692 	FACING_NONE,					// Foundation direction from center of building.
    693 	XYP_COORD(0,0),				// Exit point for produced units.
    694 	REMAP_ALTERNATE,				// Sidebar remap logic.
    695 	0x0000,							//	Vertical offset.
    696 	0x0000,							// Primary weapon offset along turret centerline.
    697 	0x0000,							// Primary weapon lateral offset along turret centerline.
    698 		true,							// Is this building a fake (decoy?)
    699 		false,						// Animation rate is regulated for constant speed?
    700 		false,						// Always use the given name for the building?
    701 		false,						// Is this a wall type structure?
    702 		false,						// Simple (one frame) damage imagery?
    703 		false,						// Is it invisible to radar?
    704 		true,							// Can the player select this?
    705 		true,							// Is this a legal target for attack or move?
    706 		false,						// Is this an insignificant building?
    707 		false,						// Theater specific graphic image?
    708 		false,						// Does it have a rotating turret?
    709 		true,							// Can the building be color remapped to indicate owner?
    710 	RTTI_NONE,						// The object type produced at this factory.
    711 	DIR_N,							// Starting idle frame to match construction.
    712 	BSIZE_33, 						// SIZE:			Building size.
    713 	NULL,								// Preferred exit cell list.
    714 	(short const *)ListFactory,// OCCUPYLIST:	List of active foundation squares.
    715 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    716 );
    717 
    718 static BuildingTypeClass const ClassFakeWeapon(
    719 	STRUCT_FAKEWEAP,
    720 	TXT_FAKE_WEAP,					// NAME:			Short name of the structure.
    721 	"WEAF",							// NAME:			Short name of the structure.
    722 	FACING_NONE,					// Foundation direction from center of building.
    723 	XYP_COORD(10+(CELL_PIXEL_W/2), ((CELL_PIXEL_H*3)-(CELL_PIXEL_H/2))-21),			// Exit point for produced units.
    724 	REMAP_ALTERNATE,				// Sidebar remap logic.
    725 	0x0000,							//	Vertical offset.
    726 	0x0000,							// Primary weapon offset along turret centerline.
    727 	0x0000,							// Primary weapon lateral offset along turret centerline.
    728 		true,							// Is this building a fake (decoy?)
    729 		false,						// Animation rate is regulated for constant speed?
    730 		false,						// Always use the given name for the building?
    731 		false,						// Is this a wall type structure?
    732 		false,						// Simple (one frame) damage imagery?
    733 		false,						// Is it invisible to radar?
    734 		true,							// Can the player select this?
    735 		true,							// Is this a legal target for attack or move?
    736 		false,						// Is this an insignificant building?
    737 		false,						// Theater specific graphic image?
    738 		false,						// Does it have a rotating turret?
    739 		true,							// Can the building be color remapped to indicate owner?
    740 	RTTI_NONE,						// The object type produced at this factory.
    741 	DIR_N,							// Starting idle frame to match construction.
    742 	BSIZE_32, 						// SIZE:			Building size.
    743 	(short const *)ExitWeap,	// Preferred exit cell list.
    744 	(short const *)ListWeap,	// OCCUPYLIST:	List of active foundation squares.
    745 	(short const *)OListWeap	// OVERLAPLIST:List of overlap cell offset.
    746 );
    747 
    748 static BuildingTypeClass const ClassRefinery(
    749 	STRUCT_REFINERY,
    750 	TXT_REFINERY,					// NAME:			Short name of the structure.
    751 	"PROC",							// NAME:			Short name of the structure.
    752 	FACING_NONE,					// Foundation direction from center of building.
    753 	XYP_COORD(0,0),				// Exit point for produced units.
    754 	REMAP_ALTERNATE,				// Sidebar remap logic.
    755 	0x0000,							//	Vertical offset.
    756 	0x0000,							// Primary weapon offset along turret centerline.
    757 	0x0000,							// Primary weapon lateral offset along turret centerline.
    758 		false,						// Is this building a fake (decoy?)
    759 		false,						// Animation rate is regulated for constant speed?
    760 		false,						// Always use the given name for the building?
    761 		false,						// Is this a wall type structure?
    762 		false,						// Simple (one frame) damage imagery?
    763 		false,						// Is it invisible to radar?
    764 		true,							// Can the player select this?
    765 		true,							// Is this a legal target for attack or move?
    766 		false,						// Is this an insignificant building?
    767 		false,						// Theater specific graphic image?
    768 		false,						// Does it have a rotating turret?
    769 		true,							// Can the building be color remapped to indicate owner?
    770 	RTTI_NONE,						// The object type produced at this factory.
    771 	DIR_N,							// Starting idle frame to match construction.
    772 	BSIZE_33, 						// SIZE:			Building size.
    773 	NULL,								// Preferred exit cell list.
    774 	(short const *)List010111100,	// OCCUPYLIST:	List of active foundation squares.
    775 	(short const *)List101000011	// OVERLAPLIST:List of overlap cell offset.
    776 );
    777 
    778 static BuildingTypeClass const ClassStorage(
    779 	STRUCT_STORAGE,
    780 	TXT_STORAGE,					// NAME:			Short name of the structure.
    781 	"SILO",							// NAME:			Short name of the structure.
    782 	FACING_NONE,					// Foundation direction from center of building.
    783 	XYP_COORD(0,0),				// Exit point for produced units.
    784 	REMAP_ALTERNATE,				// Sidebar remap logic.
    785 	0x0000,							//	Vertical offset.
    786 	0x0000,							// Primary weapon offset along turret centerline.
    787 	0x0000,							// Primary weapon lateral offset along turret centerline.
    788 		false,						// Is this building a fake (decoy?)
    789 		false,						// Animation rate is regulated for constant speed?
    790 		false,						// Always use the given name for the building?
    791 		false,						// Is this a wall type structure?
    792 		true,							// Simple (one frame) damage imagery?
    793 		false,						// Is it invisible to radar?
    794 		true,							// Can the player select this?
    795 		true,							// Is this a legal target for attack or move?
    796 		false,						// Is this an insignificant building?
    797 		false,						// Theater specific graphic image?
    798 		false,						// Does it have a rotating turret?
    799 		true,							// Can the building be color remapped to indicate owner?
    800 	RTTI_NONE,						// The object type produced at this factory.
    801 	DIR_N,							// Starting idle frame to match construction.
    802 	BSIZE_11, 						// SIZE:			Building size.
    803 	NULL,								// Preferred exit cell list.
    804 	(short const *)StoreList,	// OCCUPYLIST:	List of active foundation squares.
    805 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    806 );
    807 
    808 static BuildingTypeClass const ClassHelipad(
    809 	STRUCT_HELIPAD,
    810 	TXT_HELIPAD,					// NAME:			Short name of the structure.
    811 	"HPAD",							// NAME:			Short name of the structure.
    812 	FACING_NONE,					// Foundation direction from center of building.
    813 	XYP_COORD(0,0),				// Exit point for produced units.
    814 	REMAP_ALTERNATE,				// Sidebar remap logic.
    815 	0x0000,							//	Vertical offset.
    816 	0x0000,							// Primary weapon offset along turret centerline.
    817 	0x0000,							// Primary weapon lateral offset along turret centerline.
    818 		false,						// Is this building a fake (decoy?)
    819 		false,						// Animation rate is regulated for constant speed?
    820 		false,						// Always use the given name for the building?
    821 		false,						// Is this a wall type structure?
    822 		false,						// Simple (one frame) damage imagery?
    823 		false,						// Is it invisible to radar?
    824 		true,							// Can the player select this?
    825 		true,							// Is this a legal target for attack or move?
    826 		false,						// Is this an insignificant building?
    827 		false,						// Theater specific graphic image?
    828 		false,						// Does it have a rotating turret?
    829 		true,							// Can the building be color remapped to indicate owner?
    830 	RTTI_AIRCRAFTTYPE,			// The object type produced at this factory.
    831 	DIR_N,							// Starting idle frame to match construction.
    832 	BSIZE_22, 						// SIZE:			Building size.
    833 	NULL,								// Preferred exit cell list.
    834 	(short const *)List2,		// OCCUPYLIST:	List of active foundation squares.
    835 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    836 );
    837 
    838 static BuildingTypeClass const ClassCommand(
    839 	STRUCT_RADAR,
    840 	TXT_COMMAND,					// NAME:			Short name of the structure.
    841 	"DOME",							// NAME:			Short name of the structure.
    842 	FACING_NONE,					// Foundation direction from center of building.
    843 	XYP_COORD(0,0),				// Exit point for produced units.
    844 	REMAP_ALTERNATE,				// Sidebar remap logic.
    845 	0x0000,							//	Vertical offset.
    846 	0x0000,							// Primary weapon offset along turret centerline.
    847 	0x0000,							// Primary weapon lateral offset along turret centerline.
    848 		false,						// Is this building a fake (decoy?)
    849 		true,							// Animation rate is regulated for constant speed?
    850 		false,						// Always use the given name for the building?
    851 		false,						// Is this a wall type structure?
    852 		false,						// Simple (one frame) damage imagery?
    853 		false,						// Is it invisible to radar?
    854 		true,							// Can the player select this?
    855 		true,							// Is this a legal target for attack or move?
    856 		false,						// Is this an insignificant building?
    857 		false,						// Theater specific graphic image?
    858 		false,						// Does it have a rotating turret?
    859 		true,							// Can the building be color remapped to indicate owner?
    860 	RTTI_NONE,						// The object type produced at this factory.
    861 	DIR_N,							// Starting idle frame to match construction.
    862 	BSIZE_22, 						// SIZE:			Building size.
    863 	NULL,								// Preferred exit cell list.
    864 	(short const *)ComList,		// OCCUPYLIST:	List of active foundation squares.
    865 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    866 );
    867 
    868 static BuildingTypeClass const ClassGapGenerator(
    869 	STRUCT_GAP,
    870 	TXT_GAP_GENERATOR,			// NAME:			Short name of the structure.
    871 	"GAP",							// NAME:			Short name of the structure.
    872 	FACING_S,						// Foundation direction from center of building.
    873 	XYP_COORD(0,0),				// Exit point for produced units.
    874 	REMAP_ALTERNATE,				// Sidebar remap logic.
    875 	0x0000,							//	Vertical offset.
    876 	0x0000,							// Primary weapon offset along turret centerline.
    877 	0x0000,							// Primary weapon lateral offset along turret centerline.
    878 		false,						// Is this building a fake (decoy?)
    879 		true,							// Animation rate is regulated for constant speed?
    880 		false,						// Always use the given name for the building?
    881 		false,						// Is this a wall type structure?
    882 		false,						// Simple (one frame) damage imagery?
    883 		false,						// Is it invisible to radar?
    884 		true,							// Can the player select this?
    885 		true,							// Is this a legal target for attack or move?
    886 		false,						// Is this an insignificant building?
    887 		false,						// Theater specific graphic image?
    888 		false,						// Does it have a rotating turret?
    889 		true,							// Can the building be color remapped to indicate owner?
    890 	RTTI_NONE,						// The object type produced at this factory.
    891 	DIR_N,							// Starting idle frame to match construction.
    892 	BSIZE_12, 						// SIZE:			Building size.
    893 	NULL,								// Preferred exit cell list.
    894 	(short const *)List0010,	// OCCUPYLIST:	List of active foundation squares.
    895 	(short const *)List1			// OVERLAPLIST:List of overlap cell offset.
    896 );
    897 
    898 static BuildingTypeClass const ClassSAM(
    899 	STRUCT_SAM,
    900 	TXT_SAM,							// NAME:			Short name of the structure.
    901 	"SAM",							// NAME:			Short name of the structure.
    902 	FACING_NONE,					// Foundation direction from center of building.
    903 	XYP_COORD(0,0),				// Exit point for produced units.
    904 	REMAP_ALTERNATE,				// Sidebar remap logic.
    905 	0x0030,							//	Vertical offset.
    906 	0x0080,							// Primary weapon offset along turret centerline.
    907 	0x0000,							// Primary weapon lateral offset along turret centerline.
    908 		false,						// Is this building a fake (decoy?)
    909 		false,						// Animation rate is regulated for constant speed?
    910 		false,						// Always use the given name for the building?
    911 		false,						// Is this a wall type structure?
    912 		false,						// Simple (one frame) damage imagery?
    913 		false,						// Is it invisible to radar?
    914 		true,							// Can the player select this?
    915 		true,							// Is this a legal target for attack or move?
    916 		false,						// Is this an insignificant building?
    917 		false,						// Theater specific graphic image?
    918 		true,							// Does it have a rotating turret?
    919 		true,							// Can the building be color remapped to indicate owner?
    920 	RTTI_NONE,						// The object type produced at this factory.
    921 	DIR_N,							// Starting idle frame to match construction.
    922 	BSIZE_21, 						// SIZE:			Building size.
    923 	NULL,								// Preferred exit cell list.
    924 	(short const *)List21,		// OCCUPYLIST:	List of active foundation squares.
    925 	(short const *)OListSAM		// OVERLAPLIST:List of overlap cell offset.
    926 );
    927 
    928 static BuildingTypeClass const ClassMissileSilo(
    929 	STRUCT_MSLO,
    930 	TXT_MSLO,						// NAME:			Short name of the structure.
    931 	"MSLO",							// NAME:			Short name of the structure.
    932 	FACING_NONE,					// Foundation direction from center of building.
    933 	XYP_COORD(0,0),				// Exit point for produced units.
    934 	REMAP_ALTERNATE,				// Sidebar remap logic.
    935 	0x0000,							//	Vertical offset.
    936 	0x0000,							// Primary weapon offset along turret centerline.
    937 	0x0000,							// Primary weapon lateral offset along turret centerline.
    938 		false,						// Is this building a fake (decoy?)
    939 		true,							// Animation rate is regulated for constant speed?
    940 		false,						// Always use the given name for the building?
    941 		false,						// Is this a wall type structure?
    942 		false,						// Simple (one frame) damage imagery?
    943 		false,						// Is it invisible to radar?
    944 		true,							// Can the player select this?
    945 		true,							// Is this a legal target for attack or move?
    946 		false,						// Is this an insignificant building?
    947 		true,							// Theater specific graphic image?
    948 		false,						// Does it have a rotating turret?
    949 		true,							// Can the building be color remapped to indicate owner?
    950 	RTTI_NONE,						// The object type produced at this factory.
    951 	DIR_N,							// Starting idle frame to match construction.
    952 	BSIZE_21, 						// SIZE:			Building size.
    953 	NULL,								// Preferred exit cell list.
    954 	(short const *)List21,		// OCCUPYLIST:	List of active foundation squares.
    955 	(short const *)OListSAM		// OVERLAPLIST:List of overlap cell offset.
    956 );
    957 
    958 static BuildingTypeClass const ClassAirStrip(
    959 	STRUCT_AIRSTRIP,
    960 	TXT_AIRSTRIP,					// NAME:			Short name of the structure.
    961 	"AFLD",							// NAME:			Short name of the structure.
    962 	FACING_S,						// Foundation direction from center of building.
    963 	XYP_COORD(0,0),				// Exit point for produced units.
    964 	REMAP_ALTERNATE,				// Sidebar remap logic.
    965 	0x0000,							//	Vertical offset.
    966 	0x0000,							// Primary weapon offset along turret centerline.
    967 	0x0000,							// Primary weapon lateral offset along turret centerline.
    968 		false,						// Is this building a fake (decoy?)
    969 		true,							// Animation rate is regulated for constant speed?
    970 		false,						// Always use the given name for the building?
    971 		false,						// Is this a wall type structure?
    972 		false,						// Simple (one frame) damage imagery?
    973 		false,						// Is it invisible to radar?
    974 		true,							// Can the player select this?
    975 		true,							// Is this a legal target for attack or move?
    976 		false,						// Is this an insignificant building?
    977 		false,						// Theater specific graphic image?
    978 		false,						// Does it have a rotating turret?
    979 		true,							// Can the building be color remapped to indicate owner?
    980 	RTTI_AIRCRAFTTYPE,			// The object type produced at this factory.
    981 	DIR_N,							// Starting idle frame to match construction.
    982 	BSIZE_32, 						// SIZE:			Building size.
    983 	NULL,								// Preferred exit cell list.
    984 	(short const *)List32,		// OCCUPYLIST:	List of active foundation squares.
    985 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
    986 );
    987 
    988 static BuildingTypeClass const ClassPower(
    989 	STRUCT_POWER,
    990 	TXT_POWER,						// NAME:			Short name of the structure.
    991 	"POWR",							// NAME:			Short name of the structure.
    992 	FACING_S,						// Foundation direction from center of building.
    993 	XYP_COORD(0,0),				// Exit point for produced units.
    994 	REMAP_ALTERNATE,				// Sidebar remap logic.
    995 	0x0000,							//	Vertical offset.
    996 	0x0000,							// Primary weapon offset along turret centerline.
    997 	0x0000,							// Primary weapon lateral offset along turret centerline.
    998 		false,						// Is this building a fake (decoy?)
    999 		true,							// Animation rate is regulated for constant speed?
   1000 		false,						// Always use the given name for the building?
   1001 		false,						// Is this a wall type structure?
   1002 		true,							// Simple (one frame) damage imagery?
   1003 		false,						// Is it invisible to radar?
   1004 		true,							// Can the player select this?
   1005 		true,							// Is this a legal target for attack or move?
   1006 		false,						// Is this an insignificant building?
   1007 		false,						// Theater specific graphic image?
   1008 		false,						// Does it have a rotating turret?
   1009 		true,							// Can the building be color remapped to indicate owner?
   1010 	RTTI_NONE,						// The object type produced at this factory.
   1011 	DIR_N,							// Starting idle frame to match construction.
   1012 	BSIZE_22, 						// SIZE:			Building size.
   1013 	NULL,								// Preferred exit cell list.
   1014 	(short const *)List22,		// OCCUPYLIST:	List of active foundation squares.
   1015 	(short const *)List22_1100	// OVERLAPLIST:List of overlap cell offset.
   1016 );
   1017 
   1018 static BuildingTypeClass const ClassAdvancedPower(
   1019 	STRUCT_ADVANCED_POWER,
   1020 	TXT_ADVANCED_POWER,			// NAME:			Short name of the structure.
   1021 	"APWR",							// NAME:			Short name of the structure.
   1022 	FACING_S,						// Foundation direction from center of building.
   1023 	XYP_COORD(0,0),				// Exit point for produced units.
   1024 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1025 	0x0000,							//	Vertical offset.
   1026 	0x0000,							// Primary weapon offset along turret centerline.
   1027 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1028 		false,						// Is this building a fake (decoy?)
   1029 		true,							// Animation rate is regulated for constant speed?
   1030 		false,						// Always use the given name for the building?
   1031 		false,						// Is this a wall type structure?
   1032 		true,							// Simple (one frame) damage imagery?
   1033 		false,						// Is it invisible to radar?
   1034 		true,							// Can the player select this?
   1035 		true,							// Is this a legal target for attack or move?
   1036 		false,						// Is this an insignificant building?
   1037 		false,						// Theater specific graphic image?
   1038 		false,						// Does it have a rotating turret?
   1039 		true,							// Can the building be color remapped to indicate owner?
   1040 	RTTI_NONE,						// The object type produced at this factory.
   1041 	DIR_N,							// Starting idle frame to match construction.
   1042 	BSIZE_33, 						// SIZE:			Building size.
   1043 	NULL,								// Preferred exit cell list.
   1044 	(short const *)List000111111,	// OCCUPYLIST:	List of active foundation squares.
   1045 	(short const *)OListTmpl	// OVERLAPLIST:List of overlap cell offset.
   1046 );
   1047 
   1048 static BuildingTypeClass const ClassSovietTech(
   1049 	STRUCT_SOVIET_TECH,
   1050 	TXT_SOVIET_TECH,				// NAME:			Short name of the structure.
   1051 	"STEK",							// NAME:			Short name of the structure.
   1052 	FACING_S,						// Foundation direction from center of building.
   1053 	XYP_COORD(0,0),				// Exit point for produced units.
   1054 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1055 	0x0000,							//	Vertical offset.
   1056 	0x0000,							// Primary weapon offset along turret centerline.
   1057 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1058 		false,						// Is this building a fake (decoy?)
   1059 		true,							// Animation rate is regulated for constant speed?
   1060 		false,						// Always use the given name for the building?
   1061 		false,						// Is this a wall type structure?
   1062 		true,							// Simple (one frame) damage imagery?
   1063 		false,						// Is it invisible to radar?
   1064 		true,							// Can the player select this?
   1065 		true,							// Is this a legal target for attack or move?
   1066 		false,						// Is this an insignificant building?
   1067 		false,						// Theater specific graphic image?
   1068 		false,						// Does it have a rotating turret?
   1069 		true,							// Can the building be color remapped to indicate owner?
   1070 	RTTI_NONE,						// The object type produced at this factory.
   1071 	DIR_N,							// Starting idle frame to match construction.
   1072 	BSIZE_33, 						// SIZE:			Building size.
   1073 	NULL,								// Preferred exit cell list.
   1074 	(short const *)List000111111,	// OCCUPYLIST:	List of active foundation squares.
   1075 	(short const *)OListTmpl	// OVERLAPLIST:List of overlap cell offset.
   1076 );
   1077 
   1078 static BuildingTypeClass const ClassHospital(
   1079 	STRUCT_HOSPITAL,
   1080 	TXT_HOSPITAL,					// NAME:			Short name of the structure.
   1081 	"HOSP",							// NAME:			Short name of the structure.
   1082 	FACING_NONE,					// Foundation direction from center of building.
   1083 	XYP_COORD(0,0),				// Exit point for produced units.
   1084 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1085 	0x0000,							//	Vertical offset.
   1086 	0x0000,							// Primary weapon offset along turret centerline.
   1087 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1088 		false,						// Is this building a fake (decoy?)
   1089 		true,							// Animation rate is regulated for constant speed?
   1090 		false,						// Always use the given name for the building?
   1091 		false,						// Is this a wall type structure?
   1092 		false,						// Simple (one frame) damage imagery?
   1093 		false,						// Is it invisible to radar?
   1094 		true,							// Can the player select this?
   1095 		true,							// Is this a legal target for attack or move?
   1096 		false,						// Is this an insignificant building?
   1097 		false,						// Theater specific graphic image?
   1098 		false,						// Does it have a rotating turret?
   1099 		true,							// Can the building be color remapped to indicate owner?
   1100 	RTTI_NONE,						// The object type produced at this factory.
   1101 	DIR_N,							// Starting idle frame to match construction.
   1102 	BSIZE_22, 						// SIZE:			Building size.
   1103 	NULL,								// Preferred exit cell list.
   1104 	(short const *)List2,		// OCCUPYLIST:	List of active foundation squares.
   1105 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1106 );
   1107 
   1108 static BuildingTypeClass const ClassBioLab(
   1109 	STRUCT_BIO_LAB,
   1110 	TXT_BIO_LAB,					// NAME:			Short name of the structure.
   1111 	"BIO",							// NAME:			Short name of the structure.
   1112 	FACING_NONE,					// Foundation direction from center of building.
   1113 	XYP_COORD(0,0),				// Exit point for produced units.
   1114 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1115 	0x0000,							//	Vertical offset.
   1116 	0x0000,							// Primary weapon offset along turret centerline.
   1117 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1118 		false,						// Is this building a fake (decoy?)
   1119 		true,							// Animation rate is regulated for constant speed?
   1120 		true,							// Always use the given name for the building?
   1121 		false,						// Is this a wall type structure?
   1122 		false,						// Simple (one frame) damage imagery?
   1123 		false,						// Is it invisible to radar?
   1124 		true,							// Can the player select this?
   1125 		true,							// Is this a legal target for attack or move?
   1126 		false,						// Is this an insignificant building?
   1127 		false,						// Theater specific graphic image?
   1128 		false,						// Does it have a rotating turret?
   1129 		true,							// Can the building be color remapped to indicate owner?
   1130 	RTTI_NONE,						// The object type produced at this factory.
   1131 	DIR_N,							// Starting idle frame to match construction.
   1132 	BSIZE_22, 						// SIZE:			Building size.
   1133 	NULL,								// Preferred exit cell list.
   1134 	(short const *)List2,		// OCCUPYLIST:	List of active foundation squares.
   1135 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1136 );
   1137 
   1138 static BuildingTypeClass const ClassBarracks(
   1139 	STRUCT_BARRACKS,
   1140 	TXT_BARRACKS,					// NAME:			Short name of the structure.
   1141 	"BARR",							// NAME:			Short name of the structure.
   1142 	FACING_NONE,					// Foundation direction from center of building.
   1143 //	XYP_COORD(24,47),				// Exit point for produced units.
   1144 	XYP_COORD(18,47),				// Exit point for produced units.
   1145 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1146 	0x0000,							//	Vertical offset.
   1147 	0x0000,							// Primary weapon offset along turret centerline.
   1148 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1149 		false,						// Is this building a fake (decoy?)
   1150 		true,							// Animation rate is regulated for constant speed?
   1151 		false,						// Always use the given name for the building?
   1152 		false,						// Is this a wall type structure?
   1153 		false,						// Simple (one frame) damage imagery?
   1154 		false,						// Is it invisible to radar?
   1155 		true,							// Can the player select this?
   1156 		true,							// Is this a legal target for attack or move?
   1157 		false,						// Is this an insignificant building?
   1158 		false,						// Theater specific graphic image?
   1159 		false,						// Does it have a rotating turret?
   1160 		true,							// Can the building be color remapped to indicate owner?
   1161 	RTTI_INFANTRYTYPE,			// The object type produced at this factory.
   1162 	DIR_N,							// Starting idle frame to match construction.
   1163 	BSIZE_22, 						// SIZE:			Building size.
   1164 	(short const *)ExitPyle,	// Preferred exit cell list.
   1165 	(short const *)List22,		// OCCUPYLIST:	List of active foundation squares.
   1166 	NULL								// OVERLAPLIST:List of overlap cell offset.
   1167 );
   1168 
   1169 static BuildingTypeClass const ClassTent(
   1170 	STRUCT_TENT,
   1171 	TXT_BARRACKS,					// NAME:			Short name of the structure.
   1172 	"TENT",							// NAME:			Short name of the structure.
   1173 	FACING_NONE,					// Foundation direction from center of building.
   1174 	XYP_COORD(24,47),				// Exit point for produced units.
   1175 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1176 	0x0000,							//	Vertical offset.
   1177 	0x0000,							// Primary weapon offset along turret centerline.
   1178 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1179 		false,						// Is this building a fake (decoy?)
   1180 		true,							// Animation rate is regulated for constant speed?
   1181 		false,						// Always use the given name for the building?
   1182 		false,						// Is this a wall type structure?
   1183 		false,						// Simple (one frame) damage imagery?
   1184 		false,						// Is it invisible to radar?
   1185 		true,							// Can the player select this?
   1186 		true,							// Is this a legal target for attack or move?
   1187 		false,						// Is this an insignificant building?
   1188 		false,						// Theater specific graphic image?
   1189 		false,						// Does it have a rotating turret?
   1190 		true,							// Can the building be color remapped to indicate owner?
   1191 	RTTI_INFANTRYTYPE,			// The object type produced at this factory.
   1192 	DIR_N,							// Starting idle frame to match construction.
   1193 	BSIZE_22, 						// SIZE:			Building size.
   1194 	(short const *)ExitPyle,	// Preferred exit cell list.
   1195 	(short const *)List22,		// OCCUPYLIST:	List of active foundation squares.
   1196 	NULL								// OVERLAPLIST:List of overlap cell offset.
   1197 );
   1198 
   1199 static BuildingTypeClass const ClassKennel(
   1200 	STRUCT_KENNEL,
   1201 	TXT_KENNEL,						// NAME:			Short name of the structure.
   1202 	"KENN",							// NAME:			Short name of the structure.
   1203 	FACING_NONE,					// Foundation direction from center of building.
   1204 	XYP_COORD(8,16),				// Exit point for produced units.
   1205 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1206 	0x0000,							//	Vertical offset.
   1207 	0x0000,							// Primary weapon offset along turret centerline.
   1208 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1209 		false,						// Is this building a fake (decoy?)
   1210 		true,							// Animation rate is regulated for constant speed?
   1211 		false,						// Always use the given name for the building?
   1212 		false,						// Is this a wall type structure?
   1213 		false,						// Simple (one frame) damage imagery?
   1214 		false,						// Is it invisible to radar?
   1215 		true,							// Can the player select this?
   1216 		true,							// Is this a legal target for attack or move?
   1217 		false,						// Is this an insignificant building?
   1218 		false,						// Theater specific graphic image?
   1219 		false,						// Does it have a rotating turret?
   1220 		true,							// Can the building be color remapped to indicate owner?
   1221 	RTTI_INFANTRYTYPE,			// The object type produced at this factory.
   1222 	DIR_N,							// Starting idle frame to match construction.
   1223 	BSIZE_11, 						// SIZE:			Building size.
   1224 	NULL,								// Preferred exit cell list.
   1225 //	(short const *)ExitPyle,	// Preferred exit cell list.
   1226 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1227 	NULL								// OVERLAPLIST:List of overlap cell offset.
   1228 );
   1229 
   1230 static BuildingTypeClass const ClassFakeShipYard(
   1231 	STRUCT_FAKE_YARD,
   1232 	TXT_FAKE_YARD,					// NAME:			Short name of the structure.
   1233 	"SYRF",							// NAME:			Short name of the structure.
   1234 	FACING_NONE,					// Foundation direction from center of building.
   1235 	XYP_COORD(22+(CELL_PIXEL_W/2), ((CELL_PIXEL_H*2)-(CELL_PIXEL_H/2))),			// Exit point for produced units.
   1236 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1237 	0x0000,							//	Vertical offset.
   1238 	0x0000,							// Primary weapon offset along turret centerline.
   1239 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1240 		true,							// Is this building a fake (decoy?)
   1241 		false,						// Animation rate is regulated for constant speed?
   1242 		false,						// Always use the given name for the building?
   1243 		false,						// Is this a wall type structure?
   1244 		false,						// Simple (one frame) damage imagery?
   1245 		false,						// Is it invisible to radar?
   1246 		true,							// Can the player select this?
   1247 		true,							// Is this a legal target for attack or move?
   1248 		false,						// Is this an insignificant building?
   1249 		false,						// Theater specific graphic image?
   1250 		false,						// Does it have a rotating turret?
   1251 		true,							// Can the building be color remapped to indicate owner?
   1252 	RTTI_NONE,						// The object type produced at this factory.
   1253 	DIR_N,							// Starting idle frame to match construction.
   1254 	BSIZE_33, 						// SIZE:			Building size.
   1255 	(short const *)ExitWeap,	// Preferred exit cell list.
   1256 	(short const *)ListSPen,	// OCCUPYLIST:	List of active foundation squares.
   1257 	(short const *)OListSPen	// OVERLAPLIST:List of overlap cell offset.
   1258 );
   1259 
   1260 static BuildingTypeClass const ClassFakeSubPen(
   1261 	STRUCT_FAKE_PEN,
   1262 	TXT_FAKE_PEN,					// NAME:			Short name of the structure.
   1263 	"SPEF",							// NAME:			Short name of the structure.
   1264 	FACING_NONE,					// Foundation direction from center of building.
   1265 	XYP_COORD(22+(CELL_PIXEL_W/2), ((CELL_PIXEL_H*2)-(CELL_PIXEL_H/2))),			// Exit point for produced units.
   1266 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1267 	0x0000,							//	Vertical offset.
   1268 	0x0000,							// Primary weapon offset along turret centerline.
   1269 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1270 		true,							// Is this building a fake (decoy?)
   1271 		false,						// Animation rate is regulated for constant speed?
   1272 		false,						// Always use the given name for the building?
   1273 		false,						// Is this a wall type structure?
   1274 		false,						// Simple (one frame) damage imagery?
   1275 		false,						// Is it invisible to radar?
   1276 		true,							// Can the player select this?
   1277 		true,							// Is this a legal target for attack or move?
   1278 		false,						// Is this an insignificant building?
   1279 		false,						// Theater specific graphic image?
   1280 		false,						// Does it have a rotating turret?
   1281 		true,							// Can the building be color remapped to indicate owner?
   1282 	RTTI_NONE,						// The object type produced at this factory.
   1283 	DIR_N,							// Starting idle frame to match construction.
   1284 	BSIZE_33, 						// SIZE:			Building size.
   1285 	(short const *)ExitSub,		// Preferred exit cell list.
   1286 	(short const *)ListSPen,	// OCCUPYLIST:	List of active foundation squares.
   1287 	(short const *)OListSPen	// OVERLAPLIST:List of overlap cell offset.
   1288 );
   1289 
   1290 static BuildingTypeClass const ClassFakeCommand(
   1291 	STRUCT_FAKE_RADAR,
   1292 	TXT_FAKE_RADAR,				// NAME:			Short name of the structure.
   1293 	"DOMF",							// NAME:			Short name of the structure.
   1294 	FACING_NONE,					// Foundation direction from center of building.
   1295 	XYP_COORD(0,0),				// Exit point for produced units.
   1296 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1297 	0x0000,							//	Vertical offset.
   1298 	0x0000,							// Primary weapon offset along turret centerline.
   1299 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1300 		true,							// Is this building a fake (decoy?)
   1301 		true,							// Animation rate is regulated for constant speed?
   1302 		false,						// Always use the given name for the building?
   1303 		false,						// Is this a wall type structure?
   1304 		false,						// Simple (one frame) damage imagery?
   1305 		false,						// Is it invisible to radar?
   1306 		true,							// Can the player select this?
   1307 		true,							// Is this a legal target for attack or move?
   1308 		false,						// Is this an insignificant building?
   1309 		false,						// Theater specific graphic image?
   1310 		false,						// Does it have a rotating turret?
   1311 		true,							// Can the building be color remapped to indicate owner?
   1312 	RTTI_NONE,						// The object type produced at this factory.
   1313 	DIR_N,							// Starting idle frame to match construction.
   1314 	BSIZE_22, 						// SIZE:			Building size.
   1315 	NULL,								// Preferred exit cell list.
   1316 	(short const *)ComList,		// OCCUPYLIST:	List of active foundation squares.
   1317 	(short const *)OComList		// OVERLAPLIST:List of overlap cell offset.
   1318 );
   1319 
   1320 static BuildingTypeClass const ClassRepair(
   1321 	STRUCT_REPAIR,
   1322 	TXT_FIX_IT,						// NAME:			Short name of the structure.
   1323 	"FIX",							// NAME:			Short name of the structure.
   1324 	FACING_NONE,					// Foundation direction from center of building.
   1325 	XYP_COORD(0,0),				// Exit point for produced units.
   1326 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1327 	0x0000,							//	Vertical offset.
   1328 	0x0000,							// Primary weapon offset along turret centerline.
   1329 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1330 		false,						// Is this building a fake (decoy?)
   1331 		true,							// Animation rate is regulated for constant speed?
   1332 		false,						// Always use the given name for the building?
   1333 		false,						// Is this a wall type structure?
   1334 		false,						// Simple (one frame) damage imagery?
   1335 		false,						// Is it invisible to radar?
   1336 		true,							// Can the player select this?
   1337 		true,							// Is this a legal target for attack or move?
   1338 		false,						// Is this an insignificant building?
   1339 		false,						// Theater specific graphic image?
   1340 		false,						// Does it have a rotating turret?
   1341 		true,							// Can the building be color remapped to indicate owner?
   1342 	RTTI_NONE,						// The object type produced at this factory.
   1343 	DIR_N,							// Starting idle frame to match construction.
   1344 	BSIZE_33, 						// SIZE:			Building size.
   1345 	NULL,								// Preferred exit cell list.
   1346 	(short const *)ListFix,		// OCCUPYLIST:	List of active foundation squares.
   1347 	(short const *)OListFix		// OVERLAPLIST:List of overlap cell offset.
   1348 );
   1349 
   1350 static BuildingTypeClass const ClassV01(
   1351 	STRUCT_V01,
   1352 	TXT_CIV1,						// NAME:			Short name of the structure.
   1353 	"V01",							// NAME:			Short name of the structure.
   1354 	FACING_S,						// Foundation direction from center of building.
   1355 	XYP_COORD(0,0),				// Exit point for produced units.
   1356 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1357 	0x0000,							//	Vertical offset.
   1358 	0x0000,							// Primary weapon offset along turret centerline.
   1359 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1360 		false,						// Is this building a fake (decoy?)
   1361 		true,							// Animation rate is regulated for constant speed?
   1362 		true,							// Always use the given name for the building?
   1363 		false,						// Is this a wall type structure?
   1364 		true,							// Simple (one frame) damage imagery?
   1365 		true,							// Is it invisible to radar?
   1366 		true,							// Can the player select this?
   1367 		true,							// Is this a legal target for attack or move?
   1368 		true,							// Is this an insignificant building?
   1369 		true,							// Theater specific graphic image?
   1370 		false,						// Does it have a rotating turret?
   1371 		false,						// Can the building be color remapped to indicate owner?
   1372 	RTTI_NONE,						// The object type produced at this factory.
   1373 	DIR_N,							// Starting idle frame to match construction.
   1374 	BSIZE_22, 						// SIZE: Building size.
   1375 	NULL,								// Preferred exit cell list.
   1376 	(short const *)List0011,	// OCCUPYLIST:	List of active foundation squares.
   1377 	(short const *)List1100		// OVERLAPLIST:List of overlap cell offset.
   1378 );
   1379 
   1380 static BuildingTypeClass const ClassV02(
   1381 	STRUCT_V02,
   1382 	TXT_CIV2,						// NAME:			Short name of the structure.
   1383 	"V02",							// NAME:			Short name of the structure.
   1384 	FACING_S,						// Foundation direction from center of building.
   1385 	XYP_COORD(0,0),				// Exit point for produced units.
   1386 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1387 	0x0000,							//	Vertical offset.
   1388 	0x0000,							// Primary weapon offset along turret centerline.
   1389 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1390 		false,						// Is this building a fake (decoy?)
   1391 		true,							// Animation rate is regulated for constant speed?
   1392 		true,							// Always use the given name for the building?
   1393 		false,						// Is this a wall type structure?
   1394 		true,							// Simple (one frame) damage imagery?
   1395 		true,							// Is it invisible to radar?
   1396 		true,							// Can the player select this?
   1397 		true,							// Is this a legal target for attack or move?
   1398 		true,							// Is this an insignificant building?
   1399 		true,							// Theater specific graphic image?
   1400 		false,						// Does it have a rotating turret?
   1401 		false,						// Can the building be color remapped to indicate owner?
   1402 	RTTI_NONE,						// The object type produced at this factory.
   1403 	DIR_N,							// Starting idle frame to match construction.
   1404 	BSIZE_22, 						// SIZE:			Building size.
   1405 	NULL,								// Preferred exit cell list.
   1406 	(short const *)List0011,	// OCCUPYLIST:	List of active foundation squares.
   1407 	(short const *)List1100		// OVERLAPLIST:List of overlap cell offset.
   1408 );
   1409 
   1410 static BuildingTypeClass const ClassV03(
   1411 	STRUCT_V03,
   1412 	TXT_CIV3,						// NAME:			Short name of the structure.
   1413 	"V03",							// NAME:			Short name of the structure.
   1414 	FACING_S,						// Foundation direction from center of building.
   1415 	XYP_COORD(0,0),				// Exit point for produced units.
   1416 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1417 	0x0000,							//	Vertical offset.
   1418 	0x0000,							// Primary weapon offset along turret centerline.
   1419 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1420 		false,						// Is this building a fake (decoy?)
   1421 		true,							// Animation rate is regulated for constant speed?
   1422 		true,							// Always use the given name for the building?
   1423 		false,						// Is this a wall type structure?
   1424 		true,							// Simple (one frame) damage imagery?
   1425 		true,							// Is it invisible to radar?
   1426 		true,							// Can the player select this?
   1427 		true,							// Is this a legal target for attack or move?
   1428 		true,							// Is this an insignificant building?
   1429 		true,							// Theater specific graphic image?
   1430 		false,						// Does it have a rotating turret?
   1431 		false,						// Can the building be color remapped to indicate owner?
   1432 	RTTI_NONE,						// The object type produced at this factory.
   1433 	DIR_N,							// Starting idle frame to match construction.
   1434 	BSIZE_22, 						// SIZE:			Building size.
   1435 	NULL,								// Preferred exit cell list.
   1436 	(short const *)List0111,	// OCCUPYLIST:	List of active foundation squares.
   1437 	(short const *)List1000		// OVERLAPLIST:List of overlap cell offset.
   1438 );
   1439 
   1440 static BuildingTypeClass const ClassV04(
   1441 	STRUCT_V04,
   1442 	TXT_CIV4,						// NAME:			Short name of the structure.
   1443 	"V04",							// NAME:			Short name of the structure.
   1444 	FACING_S,						// Foundation direction from center of building.
   1445 	XYP_COORD(0,0),				// Exit point for produced units.
   1446 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1447 	0x0000,							//	Vertical offset.
   1448 	0x0000,							// Primary weapon offset along turret centerline.
   1449 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1450 		false,						// Is this building a fake (decoy?)
   1451 		true,							// Animation rate is regulated for constant speed?
   1452 		true,							// Always use the given name for the building?
   1453 		false,						// Is this a wall type structure?
   1454 		true,							// Simple (one frame) damage imagery?
   1455 		true,							// Is it invisible to radar?
   1456 		true,							// Can the player select this?
   1457 		true,							// Is this a legal target for attack or move?
   1458 		true,							// Is this an insignificant building?
   1459 		true,							// Theater specific graphic image?
   1460 		false,						// Does it have a rotating turret?
   1461 		false,						// Can the building be color remapped to indicate owner?
   1462 	RTTI_NONE,						// The object type produced at this factory.
   1463 	DIR_N,							// Starting idle frame to match construction.
   1464 	BSIZE_22, 						// SIZE:			Building size.
   1465 	NULL,								// Preferred exit cell list.
   1466 	(short const *)List0011,	// OCCUPYLIST:	List of active foundation squares.
   1467 	(short const *)List1100		// OVERLAPLIST:List of overlap cell offset.
   1468 );
   1469 
   1470 static BuildingTypeClass const ClassV05(
   1471 	STRUCT_V05,
   1472 	TXT_CIV5,						// NAME:			Short name of the structure.
   1473 	"V05",							// NAME:			Short name of the structure.
   1474 	FACING_NONE,					// Foundation direction from center of building.
   1475 	XYP_COORD(0,0),				// Exit point for produced units.
   1476 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1477 	0x0000,							//	Vertical offset.
   1478 	0x0000,							// Primary weapon offset along turret centerline.
   1479 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1480 		false,						// Is this building a fake (decoy?)
   1481 		true,							// Animation rate is regulated for constant speed?
   1482 		true,							// Always use the given name for the building?
   1483 		false,						// Is this a wall type structure?
   1484 		true,							// Simple (one frame) damage imagery?
   1485 		true,							// Is it invisible to radar?
   1486 		true,							// Can the player select this?
   1487 		true,							// Is this a legal target for attack or move?
   1488 		true,							// Is this an insignificant building?
   1489 		true,							// Theater specific graphic image?
   1490 		false,						// Does it have a rotating turret?
   1491 		false,						// Can the building be color remapped to indicate owner?
   1492 	RTTI_NONE,						// The object type produced at this factory.
   1493 	DIR_N,							// Starting idle frame to match construction.
   1494 	BSIZE_21, 						// SIZE:			Building size.
   1495 	NULL,								// Preferred exit cell list.
   1496 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   1497 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1498 );
   1499 
   1500 static BuildingTypeClass const ClassV06(
   1501 	STRUCT_V06,
   1502 	TXT_CIV6,						// NAME:			Short name of the structure.
   1503 	"V06",							// NAME:			Short name of the structure.
   1504 	FACING_NONE,					// Foundation direction from center of building.
   1505 	XYP_COORD(0,0),				// Exit point for produced units.
   1506 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1507 	0x0000,							//	Vertical offset.
   1508 	0x0000,							// Primary weapon offset along turret centerline.
   1509 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1510 		false,						// Is this building a fake (decoy?)
   1511 		true,							// Animation rate is regulated for constant speed?
   1512 		true,							// Always use the given name for the building?
   1513 		false,						// Is this a wall type structure?
   1514 		true,							// Simple (one frame) damage imagery?
   1515 		true,							// Is it invisible to radar?
   1516 		true,							// Can the player select this?
   1517 		true,							// Is this a legal target for attack or move?
   1518 		true,							// Is this an insignificant building?
   1519 		true,							// Theater specific graphic image?
   1520 		false,						// Does it have a rotating turret?
   1521 		false,						// Can the building be color remapped to indicate owner?
   1522 	RTTI_NONE,						// The object type produced at this factory.
   1523 	DIR_N,							// Starting idle frame to match construction.
   1524 	BSIZE_21, 						// SIZE:			Building size.
   1525 	NULL,								// Preferred exit cell list.
   1526 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   1527 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1528 );
   1529 
   1530 static BuildingTypeClass const ClassV07(
   1531 	STRUCT_V07,
   1532 	TXT_CIV7,						// NAME:			Short name of the structure.
   1533 	"V07",							// NAME:			Short name of the structure.
   1534 	FACING_NONE,					// Foundation direction from center of building.
   1535 	XYP_COORD(0,0),				// Exit point for produced units.
   1536 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1537 	0x0000,							//	Vertical offset.
   1538 	0x0000,							// Primary weapon offset along turret centerline.
   1539 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1540 		false,						// Is this building a fake (decoy?)
   1541 		true,							// Animation rate is regulated for constant speed?
   1542 		true,							// Always use the given name for the building?
   1543 		false,						// Is this a wall type structure?
   1544 		true,							// Simple (one frame) damage imagery?
   1545 		true,							// Is it invisible to radar?
   1546 		true,							// Can the player select this?
   1547 		true,							// Is this a legal target for attack or move?
   1548 		true,							// Is this an insignificant building?
   1549 		true,							// Theater specific graphic image?
   1550 		false,						// Does it have a rotating turret?
   1551 		false,						// Can the building be color remapped to indicate owner?
   1552 	RTTI_NONE,						// The object type produced at this factory.
   1553 	DIR_N,							// Starting idle frame to match construction.
   1554 	BSIZE_21, 						// SIZE:			Building size.
   1555 	NULL,								// Preferred exit cell list.
   1556 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   1557 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1558 );
   1559 
   1560 static BuildingTypeClass const ClassV08(
   1561 	STRUCT_V08,
   1562 	TXT_CIV8,						// NAME:			Short name of the structure.
   1563 	"V08",							// NAME:			Short name of the structure.
   1564 	FACING_NONE,					// Foundation direction from center of building.
   1565 	XYP_COORD(0,0),				// Exit point for produced units.
   1566 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1567 	0x0000,							//	Vertical offset.
   1568 	0x0000,							// Primary weapon offset along turret centerline.
   1569 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1570 		false,						// Is this building a fake (decoy?)
   1571 		true,							// Animation rate is regulated for constant speed?
   1572 		true,							// Always use the given name for the building?
   1573 		false,						// Is this a wall type structure?
   1574 		true,							// Simple (one frame) damage imagery?
   1575 		true,							// Is it invisible to radar?
   1576 		true,							// Can the player select this?
   1577 		true,							// Is this a legal target for attack or move?
   1578 		true,							// Is this an insignificant building?
   1579 		true,							// Theater specific graphic image?
   1580 		false,						// Does it have a rotating turret?
   1581 		false,						// Can the building be color remapped to indicate owner?
   1582 	RTTI_NONE,						// The object type produced at this factory.
   1583 	DIR_N,							// Starting idle frame to match construction.
   1584 	BSIZE_11, 						// SIZE:			Building size.
   1585 	NULL,								// Preferred exit cell list.
   1586 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1587 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1588 );
   1589 
   1590 static BuildingTypeClass const ClassV09(
   1591 	STRUCT_V09,
   1592 	TXT_CIV9,						// NAME:			Short name of the structure.
   1593 	"V09",							// NAME:			Short name of the structure.
   1594 	FACING_NONE,					// Foundation direction from center of building.
   1595 	XYP_COORD(0,0),				// Exit point for produced units.
   1596 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1597 	0x0000,							//	Vertical offset.
   1598 	0x0000,							// Primary weapon offset along turret centerline.
   1599 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1600 		false,						// Is this building a fake (decoy?)
   1601 		true,							// Animation rate is regulated for constant speed?
   1602 		true,							// Always use the given name for the building?
   1603 		false,						// Is this a wall type structure?
   1604 		true,							// Simple (one frame) damage imagery?
   1605 		true,							// Is it invisible to radar?
   1606 		true,							// Can the player select this?
   1607 		true,							// Is this a legal target for attack or move?
   1608 		true,							// Is this an insignificant building?
   1609 		true,							// Theater specific graphic image?
   1610 		false,						// Does it have a rotating turret?
   1611 		false,						// Can the building be color remapped to indicate owner?
   1612 	RTTI_NONE,						// The object type produced at this factory.
   1613 	DIR_N,							// Starting idle frame to match construction.
   1614 	BSIZE_11, 						// SIZE:			Building size.
   1615 	NULL,								// Preferred exit cell list.
   1616 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1617 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1618 );
   1619 
   1620 static BuildingTypeClass const ClassV10(
   1621 	STRUCT_V10,
   1622 	TXT_CIV10,						// NAME:			Short name of the structure.
   1623 	"V10",							// NAME:			Short name of the structure.
   1624 	FACING_NONE,					// Foundation direction from center of building.
   1625 	XYP_COORD(0,0),				// Exit point for produced units.
   1626 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1627 	0x0000,							//	Vertical offset.
   1628 	0x0000,							// Primary weapon offset along turret centerline.
   1629 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1630 		false,						// Is this building a fake (decoy?)
   1631 		true,							// Animation rate is regulated for constant speed?
   1632 		true,							// Always use the given name for the building?
   1633 		false,						// Is this a wall type structure?
   1634 		true,							// Simple (one frame) damage imagery?
   1635 		true,							// Is it invisible to radar?
   1636 		true,							// Can the player select this?
   1637 		true,							// Is this a legal target for attack or move?
   1638 		true,							// Is this an insignificant building?
   1639 		true,							// Theater specific graphic image?
   1640 		false,						// Does it have a rotating turret?
   1641 		false,						// Can the building be color remapped to indicate owner?
   1642 	RTTI_NONE,						// The object type produced at this factory.
   1643 	DIR_N,							// Starting idle frame to match construction.
   1644 	BSIZE_11, 						// SIZE:			Building size.
   1645 	NULL,								// Preferred exit cell list.
   1646 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1647 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1648 );
   1649 
   1650 static BuildingTypeClass const ClassV11(
   1651 	STRUCT_V11,
   1652 	TXT_CIV11,						// NAME:			Short name of the structure.
   1653 	"V11",							// NAME:			Short name of the structure.
   1654 	FACING_NONE,					// Foundation direction from center of building.
   1655 	XYP_COORD(0,0),				// Exit point for produced units.
   1656 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1657 	0x0000,							//	Vertical offset.
   1658 	0x0000,							// Primary weapon offset along turret centerline.
   1659 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1660 		false,						// Is this building a fake (decoy?)
   1661 		true,							// Animation rate is regulated for constant speed?
   1662 		true,							// Always use the given name for the building?
   1663 		false,						// Is this a wall type structure?
   1664 		true,							// Simple (one frame) damage imagery?
   1665 		true,							// Is it invisible to radar?
   1666 		true,							// Can the player select this?
   1667 		true,							// Is this a legal target for attack or move?
   1668 		true,							// Is this an insignificant building?
   1669 		true,							// Theater specific graphic image?
   1670 		false,						// Does it have a rotating turret?
   1671 		false,						// Can the building be color remapped to indicate owner?
   1672 	RTTI_NONE,						// The object type produced at this factory.
   1673 	DIR_N,							// Starting idle frame to match construction.
   1674 	BSIZE_11, 						// SIZE:			Building size.
   1675 	NULL,								// Preferred exit cell list.
   1676 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1677 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1678 );
   1679 
   1680 static BuildingTypeClass const ClassV12(
   1681 	STRUCT_V12,
   1682 	TXT_CIV12,						// NAME:			Short name of the structure.
   1683 	"V12",							// NAME:			Short name of the structure.
   1684 	FACING_NONE,					// Foundation direction from center of building.
   1685 	XYP_COORD(0,0),				// Exit point for produced units.
   1686 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1687 	0x0000,							//	Vertical offset.
   1688 	0x0000,							// Primary weapon offset along turret centerline.
   1689 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1690 		false,						// Is this building a fake (decoy?)
   1691 		true,							// Animation rate is regulated for constant speed?
   1692 		true,							// Always use the given name for the building?
   1693 		false,						// Is this a wall type structure?
   1694 		true,							// Simple (one frame) damage imagery?
   1695 		true,							// Is it invisible to radar?
   1696 		true,							// Can the player select this?
   1697 		true,							// Is this a legal target for attack or move?
   1698 		true,							// Is this an insignificant building?
   1699 		true,							// Theater specific graphic image?
   1700 		false,						// Does it have a rotating turret?
   1701 		false,						// Can the building be color remapped to indicate owner?
   1702 	RTTI_NONE,						// The object type produced at this factory.
   1703 	DIR_N,							// Starting idle frame to match construction.
   1704 	BSIZE_11, 						// SIZE:			Building size.
   1705 	NULL,								// Preferred exit cell list.
   1706 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1707 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1708 );
   1709 
   1710 static BuildingTypeClass const ClassV13(
   1711 	STRUCT_V13,
   1712 	TXT_CIV13,						// NAME:			Short name of the structure.
   1713 	"V13",							// NAME:			Short name of the structure.
   1714 	FACING_NONE,					// Foundation direction from center of building.
   1715 	XYP_COORD(0,0),				// Exit point for produced units.
   1716 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1717 	0x0000,							//	Vertical offset.
   1718 	0x0000,							// Primary weapon offset along turret centerline.
   1719 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1720 		false,						// Is this building a fake (decoy?)
   1721 		true,							// Animation rate is regulated for constant speed?
   1722 		true,							// Always use the given name for the building?
   1723 		false,						// Is this a wall type structure?
   1724 		true,							// Simple (one frame) damage imagery?
   1725 		true,							// Is it invisible to radar?
   1726 		true,							// Can the player select this?
   1727 		true,							// Is this a legal target for attack or move?
   1728 		true,							// Is this an insignificant building?
   1729 		true,							// Theater specific graphic image?
   1730 		false,						// Does it have a rotating turret?
   1731 		false,						// Can the building be color remapped to indicate owner?
   1732 	RTTI_NONE,						// The object type produced at this factory.
   1733 	DIR_N,							// Starting idle frame to match construction.
   1734 	BSIZE_11, 						// SIZE:			Building size.
   1735 	NULL,								// Preferred exit cell list.
   1736 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1737 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1738 );
   1739 
   1740 static BuildingTypeClass const ClassV14(
   1741 	STRUCT_V14,
   1742 	TXT_CIV14,						// NAME:			Short name of the structure.
   1743 	"V14",							// NAME:			Short name of the structure.
   1744 	FACING_NONE,					// Foundation direction from center of building.
   1745 	XYP_COORD(0,0),				// Exit point for produced units.
   1746 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1747 	0x0000,							//	Vertical offset.
   1748 	0x0000,							// Primary weapon offset along turret centerline.
   1749 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1750 		false,						// Is this building a fake (decoy?)
   1751 		true,							// Animation rate is regulated for constant speed?
   1752 		true,							// Always use the given name for the building?
   1753 		false,						// Is this a wall type structure?
   1754 		true,							// Simple (one frame) damage imagery?
   1755 		true,							// Is it invisible to radar?
   1756 		true,							// Can the player select this?
   1757 		true,							// Is this a legal target for attack or move?
   1758 		true,							// Is this an insignificant building?
   1759 		true,							// Theater specific graphic image?
   1760 		false,						// Does it have a rotating turret?
   1761 		false,						// Can the building be color remapped to indicate owner?
   1762 	RTTI_NONE,						// The object type produced at this factory.
   1763 	DIR_N,							// Starting idle frame to match construction.
   1764 	BSIZE_11, 						// SIZE:			Building size.
   1765 	NULL,								// Preferred exit cell list.
   1766 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1767 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1768 );
   1769 
   1770 static BuildingTypeClass const ClassV15(
   1771 	STRUCT_V15,
   1772 	TXT_CIV15,						// NAME:			Short name of the structure.
   1773 	"V15",							// NAME:			Short name of the structure.
   1774 	FACING_NONE,					// Foundation direction from center of building.
   1775 	XYP_COORD(0,0),				// Exit point for produced units.
   1776 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1777 	0x0000,							//	Vertical offset.
   1778 	0x0000,							// Primary weapon offset along turret centerline.
   1779 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1780 		false,						// Is this building a fake (decoy?)
   1781 		true,							// Animation rate is regulated for constant speed?
   1782 		true,							// Always use the given name for the building?
   1783 		false,						// Is this a wall type structure?
   1784 		true,							// Simple (one frame) damage imagery?
   1785 		true,							// Is it invisible to radar?
   1786 		true,							// Can the player select this?
   1787 		true,							// Is this a legal target for attack or move?
   1788 		true,							// Is this an insignificant building?
   1789 		true,							// Theater specific graphic image?
   1790 		false,						// Does it have a rotating turret?
   1791 		false,						// Can the building be color remapped to indicate owner?
   1792 	RTTI_NONE,						// The object type produced at this factory.
   1793 	DIR_N,							// Starting idle frame to match construction.
   1794 	BSIZE_11, 						// SIZE:			Building size.
   1795 	NULL,								// Preferred exit cell list.
   1796 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1797 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1798 );
   1799 
   1800 static BuildingTypeClass const ClassV16(
   1801 	STRUCT_V16,
   1802 	TXT_CIV16,						// NAME:			Short name of the structure.
   1803 	"V16",							// NAME:			Short name of the structure.
   1804 	FACING_NONE,					// Foundation direction from center of building.
   1805 	XYP_COORD(0,0),				// Exit point for produced units.
   1806 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1807 	0x0000,							//	Vertical offset.
   1808 	0x0000,							// Primary weapon offset along turret centerline.
   1809 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1810 		false,						// Is this building a fake (decoy?)
   1811 		true,							// Animation rate is regulated for constant speed?
   1812 		true,							// Always use the given name for the building?
   1813 		false,						// Is this a wall type structure?
   1814 		true,							// Simple (one frame) damage imagery?
   1815 		true,							// Is it invisible to radar?
   1816 		true,							// Can the player select this?
   1817 		true,							// Is this a legal target for attack or move?
   1818 		true,							// Is this an insignificant building?
   1819 		true,							// Theater specific graphic image?
   1820 		false,						// Does it have a rotating turret?
   1821 		false,						// Can the building be color remapped to indicate owner?
   1822 	RTTI_NONE,						// The object type produced at this factory.
   1823 	DIR_N,							// Starting idle frame to match construction.
   1824 	BSIZE_11, 						// SIZE:			Building size.
   1825 	NULL,								// Preferred exit cell list.
   1826 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1827 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1828 );
   1829 
   1830 static BuildingTypeClass const ClassV17(
   1831 	STRUCT_V17,
   1832 	TXT_CIV17,						// NAME:			Short name of the structure.
   1833 	"V17",							// NAME:			Short name of the structure.
   1834 	FACING_NONE,					// Foundation direction from center of building.
   1835 	XYP_COORD(0,0),				// Exit point for produced units.
   1836 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1837 	0x0000,							//	Vertical offset.
   1838 	0x0000,							// Primary weapon offset along turret centerline.
   1839 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1840 		false,						// Is this building a fake (decoy?)
   1841 		true,							// Animation rate is regulated for constant speed?
   1842 		true,							// Always use the given name for the building?
   1843 		false,						// Is this a wall type structure?
   1844 		true,							// Simple (one frame) damage imagery?
   1845 		true,							// Is it invisible to radar?
   1846 		true,							// Can the player select this?
   1847 		true,							// Is this a legal target for attack or move?
   1848 		true,							// Is this an insignificant building?
   1849 		true,							// Theater specific graphic image?
   1850 		false,						// Does it have a rotating turret?
   1851 		false,						// Can the building be color remapped to indicate owner?
   1852 	RTTI_NONE,						// The object type produced at this factory.
   1853 	DIR_N,							// Starting idle frame to match construction.
   1854 	BSIZE_11, 						// SIZE:			Building size.
   1855 	NULL,								// Preferred exit cell list.
   1856 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1857 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1858 );
   1859 
   1860 static BuildingTypeClass const ClassV18(
   1861 	STRUCT_V18,
   1862 	TXT_CIV18,						// NAME:			Short name of the structure.
   1863 	"V18",							// NAME:			Short name of the structure.
   1864 	FACING_NONE,					// Foundation direction from center of building.
   1865 	XYP_COORD(0,0),				// Exit point for produced units.
   1866 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1867 	0x0000,							//	Vertical offset.
   1868 	0x0000,							// Primary weapon offset along turret centerline.
   1869 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1870 		false,						// Is this building a fake (decoy?)
   1871 		true,							// Animation rate is regulated for constant speed?
   1872 		true,							// Always use the given name for the building?
   1873 		false,						// Is this a wall type structure?
   1874 		true,							// Simple (one frame) damage imagery?
   1875 		true,							// Is it invisible to radar?
   1876 		true,							// Can the player select this?
   1877 		true,							// Is this a legal target for attack or move?
   1878 		true,							// Is this an insignificant building?
   1879 		true,							// Theater specific graphic image?
   1880 		false,						// Does it have a rotating turret?
   1881 		false,						// Can the building be color remapped to indicate owner?
   1882 	RTTI_NONE,						// The object type produced at this factory.
   1883 	DIR_N,							// Starting idle frame to match construction.
   1884 	BSIZE_11, 						// SIZE:			Building size.
   1885 	NULL,								// Preferred exit cell list.
   1886 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1887 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1888 );
   1889 
   1890 static BuildingTypeClass const ClassV19(
   1891 	STRUCT_PUMP,
   1892 	TXT_PUMP,						// NAME:			Short name of the structure.
   1893 	"V19",							// NAME:			Short name of the structure.
   1894 	FACING_NONE,					// Foundation direction from center of building.
   1895 	XYP_COORD(0,0),				// Exit point for produced units.
   1896 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1897 	0x0000,							//	Vertical offset.
   1898 	0x0000,							// Primary weapon offset along turret centerline.
   1899 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1900 		false,						// Is this building a fake (decoy?)
   1901 		true,							// Animation rate is regulated for constant speed?
   1902 		true,							// Always use the given name for the building?
   1903 		false,						// Is this a wall type structure?
   1904 		false,						// Simple (one frame) damage imagery?
   1905 		false,						// Is it invisible to radar?
   1906 		true,							// Can the player select this?
   1907 		true,							// Is this a legal target for attack or move?
   1908 		false,						// Is this an insignificant building?
   1909 		false,						// Theater specific graphic image?
   1910 		false,						// Does it have a rotating turret?
   1911 		false,						// Can the building be color remapped to indicate owner?
   1912 	RTTI_NONE,						// The object type produced at this factory.
   1913 	DIR_N,							// Starting idle frame to match construction.
   1914 	BSIZE_11, 						// SIZE:			Building size.
   1915 	NULL,								// Preferred exit cell list.
   1916 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   1917 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   1918 );
   1919 
   1920 static BuildingTypeClass const ClassV20(
   1921 	STRUCT_V20,
   1922 	TXT_CIV20,						// NAME:			Short name of the structure.
   1923 	"V20",							// NAME:			Short name of the structure.
   1924 	FACING_S,						// Foundation direction from center of building.
   1925 	XYP_COORD(0,0),				// Exit point for produced units.
   1926 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1927 	0x0000,							//	Vertical offset.
   1928 	0x0000,							// Primary weapon offset along turret centerline.
   1929 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1930 		false,						// Is this building a fake (decoy?)
   1931 		true,							// Animation rate is regulated for constant speed?
   1932 		true,							// Always use the given name for the building?
   1933 		false,						// Is this a wall type structure?
   1934 		false,						// Simple (one frame) damage imagery?
   1935 		false,						// Is it invisible to radar?
   1936 		true,							// Can the player select this?
   1937 		true,							// Is this a legal target for attack or move?
   1938 		false,						// Is this an insignificant building?
   1939 		true,							// Theater specific graphic image?
   1940 		false,						// Does it have a rotating turret?
   1941 		false,						// Can the building be color remapped to indicate owner?
   1942 	RTTI_NONE,						// The object type produced at this factory.
   1943 	DIR_N,							// Starting idle frame to match construction.
   1944 	BSIZE_22, 						// SIZE:			Building size.
   1945 	NULL,								// Preferred exit cell list.
   1946 	(short const *)List0011,	// OCCUPYLIST:	List of active foundation squares.
   1947 	(short const *)List1100		// OVERLAPLIST:List of overlap cell offset.
   1948 );
   1949 
   1950 static BuildingTypeClass const ClassV21(
   1951 	STRUCT_V21,
   1952 	TXT_CIV21,						// NAME:			Short name of the structure.
   1953 	"V21",							// NAME:			Short name of the structure.
   1954 	FACING_NONE,					// Foundation direction from center of building.
   1955 	XYP_COORD(0,0),				// Exit point for produced units.
   1956 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1957 	0x0000,							//	Vertical offset.
   1958 	0x0000,							// Primary weapon offset along turret centerline.
   1959 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1960 		false,						// Is this building a fake (decoy?)
   1961 		true,							// Animation rate is regulated for constant speed?
   1962 		true,							// Always use the given name for the building?
   1963 		false,						// Is this a wall type structure?
   1964 		false,						// Simple (one frame) damage imagery?
   1965 		false,						// Is it invisible to radar?
   1966 		true,							// Can the player select this?
   1967 		true,							// Is this a legal target for attack or move?
   1968 		false,						// Is this an insignificant building?
   1969 		true,							// Theater specific graphic image?
   1970 		false,						// Does it have a rotating turret?
   1971 		false,						// Can the building be color remapped to indicate owner?
   1972 	RTTI_NONE,						// The object type produced at this factory.
   1973 	DIR_N,							// Starting idle frame to match construction.
   1974 	BSIZE_22, 						// SIZE:			Building size.
   1975 	NULL,								// Preferred exit cell list.
   1976 	(short const *)List1101,	// OCCUPYLIST:	List of active foundation squares.
   1977 	(short const *)List0010		// OVERLAPLIST:List of overlap cell offset.
   1978 );
   1979 
   1980 static BuildingTypeClass const ClassV22(
   1981 	STRUCT_V22,
   1982 	TXT_CIV22,						// NAME:			Short name of the structure.
   1983 	"V22",							// NAME:			Short name of the structure.
   1984 	FACING_NONE,					// Foundation direction from center of building.
   1985 	XYP_COORD(0,0),				// Exit point for produced units.
   1986 	REMAP_ALTERNATE,				// Sidebar remap logic.
   1987 	0x0000,							//	Vertical offset.
   1988 	0x0000,							// Primary weapon offset along turret centerline.
   1989 	0x0000,							// Primary weapon lateral offset along turret centerline.
   1990 		false,						// Is this building a fake (decoy?)
   1991 		true,							// Animation rate is regulated for constant speed?
   1992 		true,							// Always use the given name for the building?
   1993 		false,						// Is this a wall type structure?
   1994 		false,						// Simple (one frame) damage imagery?
   1995 		false,						// Is it invisible to radar?
   1996 		true,							// Can the player select this?
   1997 		true,							// Is this a legal target for attack or move?
   1998 		false,						// Is this an insignificant building?
   1999 		true,							// Theater specific graphic image?
   2000 		false,						// Does it have a rotating turret?
   2001 		false,						// Can the building be color remapped to indicate owner?
   2002 	RTTI_NONE,						// The object type produced at this factory.
   2003 	DIR_N,							// Starting idle frame to match construction.
   2004 	BSIZE_21, 						// SIZE:			Building size.
   2005 	NULL,								// Preferred exit cell list.
   2006 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2007 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2008 );
   2009 
   2010 static BuildingTypeClass const ClassV23(
   2011 	STRUCT_V23,
   2012 	TXT_CIV23,						// NAME:			Short name of the structure.
   2013 	"V23",							// NAME:			Short name of the structure.
   2014 	FACING_NONE,					// Foundation direction from center of building.
   2015 	XYP_COORD(0,0),				// Exit point for produced units.
   2016 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2017 	0x0000,							//	Vertical offset.
   2018 	0x0000,							// Primary weapon offset along turret centerline.
   2019 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2020 		false,						// Is this building a fake (decoy?)
   2021 		true,							// Animation rate is regulated for constant speed?
   2022 		true,							// Always use the given name for the building?
   2023 		false,						// Is this a wall type structure?
   2024 		false,						// Simple (one frame) damage imagery?
   2025 		false,						// Is it invisible to radar?
   2026 		true,							// Can the player select this?
   2027 		true,							// Is this a legal target for attack or move?
   2028 		false,						// Is this an insignificant building?
   2029 		true,							// Theater specific graphic image?
   2030 		false,						// Does it have a rotating turret?
   2031 		false,						// Can the building be color remapped to indicate owner?
   2032 	RTTI_NONE,						// The object type produced at this factory.
   2033 	DIR_N,							// Starting idle frame to match construction.
   2034 	BSIZE_11, 						// SIZE:			Building size.
   2035 	NULL,								// Preferred exit cell list.
   2036 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2037 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2038 );
   2039 
   2040 static BuildingTypeClass const ClassV24(
   2041 	STRUCT_V24,
   2042 	TXT_CIV24,						// NAME:			Short name of the structure.
   2043 	"V24",							// NAME:			Short name of the structure.
   2044 	FACING_S,						// Foundation direction from center of building.
   2045 	XYP_COORD(0,0),				// Exit point for produced units.
   2046 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2047 	0x0000,							//	Vertical offset.
   2048 	0x0000,							// Primary weapon offset along turret centerline.
   2049 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2050 		false,						// Is this building a fake (decoy?)
   2051 		true,							// Animation rate is regulated for constant speed?
   2052 		true,							// Always use the given name for the building?
   2053 		false,						// Is this a wall type structure?
   2054 		true,							// Simple (one frame) damage imagery?
   2055 		false,						// Is it invisible to radar?
   2056 		true,							// Can the player select this?
   2057 		true,							// Is this a legal target for attack or move?
   2058 		false,						// Is this an insignificant building?
   2059 		true,							// Theater specific graphic image?
   2060 		false,						// Does it have a rotating turret?
   2061 		false,						// Can the building be color remapped to indicate owner?
   2062 	RTTI_NONE,						// The object type produced at this factory.
   2063 	DIR_N,							// Starting idle frame to match construction.
   2064 	BSIZE_22, 						// SIZE:			Building size.
   2065 	NULL,								// Preferred exit cell list.
   2066 	(short const *)List0011,	// OCCUPYLIST:	List of active foundation squares.
   2067 	(short const *)List1100		// OVERLAPLIST:List of overlap cell offset.
   2068 );
   2069 
   2070 static BuildingTypeClass const ClassV25(
   2071 	STRUCT_V25,
   2072 	TXT_CIV25,						// NAME:			Short name of the structure.
   2073 	"V25",							// NAME:			Short name of the structure.
   2074 	FACING_S,						// Foundation direction from center of building.
   2075 	XYP_COORD(0,0),				// Exit point for produced units.
   2076 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2077 	0x0000,							//	Vertical offset.
   2078 	0x0000,							// Primary weapon offset along turret centerline.
   2079 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2080 		false,						// Is this building a fake (decoy?)
   2081 		true,							// Animation rate is regulated for constant speed?
   2082 		true,							// Always use the given name for the building?
   2083 		false,						// Is this a wall type structure?
   2084 		true,							// Simple (one frame) damage imagery?
   2085 		false,						// Is it invisible to radar?
   2086 		true,							// Can the player select this?
   2087 		true,							// Is this a legal target for attack or move?
   2088 		false,						// Is this an insignificant building?
   2089 		true,							// Theater specific graphic image?
   2090 		false,						// Does it have a rotating turret?
   2091 		false,						// Can the building be color remapped to indicate owner?
   2092 	RTTI_NONE,						// The object type produced at this factory.
   2093 	DIR_N,							// Starting idle frame to match construction.
   2094 	BSIZE_22, 						// SIZE:			Building size.
   2095 	NULL,								// Preferred exit cell list.
   2096 	(short const *)List0111,	// OCCUPYLIST:	List of active foundation squares.
   2097 	(short const *)List1000		// OVERLAPLIST:List of overlap cell offset.
   2098 );
   2099 
   2100 static BuildingTypeClass const ClassV26(
   2101 	STRUCT_V26,
   2102 	TXT_CIV26,						// NAME:			Short name of the structure.
   2103 	"V26",							// NAME:			Short name of the structure.
   2104 	FACING_NONE,					// Foundation direction from center of building.
   2105 	XYP_COORD(0,0),				// Exit point for produced units.
   2106 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2107 	0x0000,							//	Vertical offset.
   2108 	0x0000,							// Primary weapon offset along turret centerline.
   2109 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2110 		false,						// Is this building a fake (decoy?)
   2111 		true,							// Animation rate is regulated for constant speed?
   2112 		true,							// Always use the given name for the building?
   2113 		false,						// Is this a wall type structure?
   2114 		true,							// Simple (one frame) damage imagery?
   2115 		false,						// Is it invisible to radar?
   2116 		true,							// Can the player select this?
   2117 		true,							// Is this a legal target for attack or move?
   2118 		false,						// Is this an insignificant building?
   2119 		true,							// Theater specific graphic image?
   2120 		false,						// Does it have a rotating turret?
   2121 		false,						// Can the building be color remapped to indicate owner?
   2122 	RTTI_NONE,						// The object type produced at this factory.
   2123 	DIR_N,							// Starting idle frame to match construction.
   2124 	BSIZE_21, 						// SIZE:			Building size.
   2125 	NULL,								// Preferred exit cell list.
   2126 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2127 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2128 );
   2129 
   2130 static BuildingTypeClass const ClassV27(
   2131 	STRUCT_V27,
   2132 	TXT_CIV27,						// NAME:			Short name of the structure.
   2133 	"V27",							// NAME:			Short name of the structure.
   2134 	FACING_NONE,					// Foundation direction from center of building.
   2135 	XYP_COORD(0,0),				// Exit point for produced units.
   2136 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2137 	0x0000,							//	Vertical offset.
   2138 	0x0000,							// Primary weapon offset along turret centerline.
   2139 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2140 		false,						// Is this building a fake (decoy?)
   2141 		true,							// Animation rate is regulated for constant speed?
   2142 		true,							// Always use the given name for the building?
   2143 		false,						// Is this a wall type structure?
   2144 		true,							// Simple (one frame) damage imagery?
   2145 		false,						// Is it invisible to radar?
   2146 		true,							// Can the player select this?
   2147 		true,							// Is this a legal target for attack or move?
   2148 		false,						// Is this an insignificant building?
   2149 		true,							// Theater specific graphic image?
   2150 		false,						// Does it have a rotating turret?
   2151 		false,						// Can the building be color remapped to indicate owner?
   2152 	RTTI_NONE,						// The object type produced at this factory.
   2153 	DIR_N,							// Starting idle frame to match construction.
   2154 	BSIZE_11, 						// SIZE:			Building size.
   2155 	NULL,								// Preferred exit cell list.
   2156 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2157 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2158 );
   2159 
   2160 static BuildingTypeClass const ClassV28(
   2161 	STRUCT_V28,
   2162 	TXT_CIV28,						// NAME:			Short name of the structure.
   2163 	"V28",							// NAME:			Short name of the structure.
   2164 	FACING_NONE,					// Foundation direction from center of building.
   2165 	XYP_COORD(0,0),				// Exit point for produced units.
   2166 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2167 	0x0000,							//	Vertical offset.
   2168 	0x0000,							// Primary weapon offset along turret centerline.
   2169 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2170 		false,						// Is this building a fake (decoy?)
   2171 		true,							// Animation rate is regulated for constant speed?
   2172 		true,							// Always use the given name for the building?
   2173 		false,						// Is this a wall type structure?
   2174 		true,							// Simple (one frame) damage imagery?
   2175 		false,						// Is it invisible to radar?
   2176 		true,							// Can the player select this?
   2177 		true,							// Is this a legal target for attack or move?
   2178 		false,						// Is this an insignificant building?
   2179 		true,							// Theater specific graphic image?
   2180 		false,						// Does it have a rotating turret?
   2181 		false,						// Can the building be color remapped to indicate owner?
   2182 	RTTI_NONE,						// The object type produced at this factory.
   2183 	DIR_N,							// Starting idle frame to match construction.
   2184 	BSIZE_11, 						// SIZE:			Building size.
   2185 	NULL,								// Preferred exit cell list.
   2186 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2187 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2188 );
   2189 
   2190 static BuildingTypeClass const ClassV29(
   2191 	STRUCT_V29,
   2192 	TXT_CIV29,						// NAME:			Short name of the structure.
   2193 	"V29",							// NAME:			Short name of the structure.
   2194 	FACING_NONE,					// Foundation direction from center of building.
   2195 	XYP_COORD(0,0),				// Exit point for produced units.
   2196 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2197 	0x0000,							//	Vertical offset.
   2198 	0x0000,							// Primary weapon offset along turret centerline.
   2199 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2200 		false,						// Is this building a fake (decoy?)
   2201 		true,							// Animation rate is regulated for constant speed?
   2202 		true,							// Always use the given name for the building?
   2203 		false,						// Is this a wall type structure?
   2204 		true,							// Simple (one frame) damage imagery?
   2205 		false,						// Is it invisible to radar?
   2206 		true,							// Can the player select this?
   2207 		true,							// Is this a legal target for attack or move?
   2208 		false,						// Is this an insignificant building?
   2209 		true,							// Theater specific graphic image?
   2210 		false,						// Does it have a rotating turret?
   2211 		false,						// Can the building be color remapped to indicate owner?
   2212 	RTTI_NONE,						// The object type produced at this factory.
   2213 	DIR_N,							// Starting idle frame to match construction.
   2214 	BSIZE_11, 						// SIZE:			Building size.
   2215 	NULL,								// Preferred exit cell list.
   2216 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2217 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2218 );
   2219 
   2220 static BuildingTypeClass const ClassV30(
   2221 	STRUCT_V30,
   2222 	TXT_CIV30,						// NAME:			Short name of the structure.
   2223 	"V30",							// NAME:			Short name of the structure.
   2224 	FACING_NONE,					// Foundation direction from center of building.
   2225 	XYP_COORD(0,0),				// Exit point for produced units.
   2226 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2227 	0x0000,							//	Vertical offset.
   2228 	0x0000,							// Primary weapon offset along turret centerline.
   2229 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2230 		false,						// Is this building a fake (decoy?)
   2231 		true,							// Animation rate is regulated for constant speed?
   2232 		true,							// Always use the given name for the building?
   2233 		false,						// Is this a wall type structure?
   2234 		true,							// Simple (one frame) damage imagery?
   2235 		false,						// Is it invisible to radar?
   2236 		true,							// Can the player select this?
   2237 		true,							// Is this a legal target for attack or move?
   2238 		false,						// Is this an insignificant building?
   2239 		true,							// Theater specific graphic image?
   2240 		false,						// Does it have a rotating turret?
   2241 		false,						// Can the building be color remapped to indicate owner?
   2242 	RTTI_NONE,						// The object type produced at this factory.
   2243 	DIR_N,							// Starting idle frame to match construction.
   2244 	BSIZE_21, 						// SIZE:			Building size.
   2245 	NULL,								// Preferred exit cell list.
   2246 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2247 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2248 );
   2249 
   2250 static BuildingTypeClass const ClassV31(
   2251 	STRUCT_V31,
   2252 	TXT_CIV31,						// NAME:			Short name of the structure.
   2253 	"V31",							// NAME:			Short name of the structure.
   2254 	FACING_NONE,					// Foundation direction from center of building.
   2255 	XYP_COORD(0,0),				// Exit point for produced units.
   2256 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2257 	0x0000,							//	Vertical offset.
   2258 	0x0000,							// Primary weapon offset along turret centerline.
   2259 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2260 		false,						// Is this building a fake (decoy?)
   2261 		true,							// Animation rate is regulated for constant speed?
   2262 		true,							// Always use the given name for the building?
   2263 		false,						// Is this a wall type structure?
   2264 		true,							// Simple (one frame) damage imagery?
   2265 		false,						// Is it invisible to radar?
   2266 		true,							// Can the player select this?
   2267 		true,							// Is this a legal target for attack or move?
   2268 		false,						// Is this an insignificant building?
   2269 		true,							// Theater specific graphic image?
   2270 		false,						// Does it have a rotating turret?
   2271 		false,						// Can the building be color remapped to indicate owner?
   2272 	RTTI_NONE,						// The object type produced at this factory.
   2273 	DIR_N,							// Starting idle frame to match construction.
   2274 	BSIZE_21, 						// SIZE:			Building size.
   2275 	NULL,								// Preferred exit cell list.
   2276 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2277 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2278 );
   2279 
   2280 static BuildingTypeClass const ClassV32(
   2281 	STRUCT_V32,
   2282 	TXT_CIV32,						// NAME:			Short name of the structure.
   2283 	"V32",							// NAME:			Short name of the structure.
   2284 	FACING_NONE,					// Foundation direction from center of building.
   2285 	XYP_COORD(0,0),				// Exit point for produced units.
   2286 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2287 	0x0000,							//	Vertical offset.
   2288 	0x0000,							// Primary weapon offset along turret centerline.
   2289 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2290 		false,						// Is this building a fake (decoy?)
   2291 		true,							// Animation rate is regulated for constant speed?
   2292 		true,							// Always use the given name for the building?
   2293 		false,						// Is this a wall type structure?
   2294 		true,							// Simple (one frame) damage imagery?
   2295 		false,						// Is it invisible to radar?
   2296 		true,							// Can the player select this?
   2297 		true,							// Is this a legal target for attack or move?
   2298 		false,						// Is this an insignificant building?
   2299 		true,							// Theater specific graphic image?
   2300 		false,						// Does it have a rotating turret?
   2301 		false,						// Can the building be color remapped to indicate owner?
   2302 	RTTI_NONE,						// The object type produced at this factory.
   2303 	DIR_N,							// Starting idle frame to match construction.
   2304 	BSIZE_21, 						// SIZE:			Building size.
   2305 	NULL,								// Preferred exit cell list.
   2306 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2307 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2308 );
   2309 
   2310 static BuildingTypeClass const ClassV33(
   2311 	STRUCT_V33,
   2312 	TXT_CIV33,						// NAME:			Short name of the structure.
   2313 	"V33",							// NAME:			Short name of the structure.
   2314 	FACING_NONE,					// Foundation direction from center of building.
   2315 	XYP_COORD(0,0),				// Exit point for produced units.
   2316 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2317 	0x0000,							//	Vertical offset.
   2318 	0x0000,							// Primary weapon offset along turret centerline.
   2319 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2320 		false,						// Is this building a fake (decoy?)
   2321 		true,							// Animation rate is regulated for constant speed?
   2322 		true,							// Always use the given name for the building?
   2323 		false,						// Is this a wall type structure?
   2324 		true,							// Simple (one frame) damage imagery?
   2325 		false,						// Is it invisible to radar?
   2326 		true,							// Can the player select this?
   2327 		true,							// Is this a legal target for attack or move?
   2328 		false,						// Is this an insignificant building?
   2329 		true,							// Theater specific graphic image?
   2330 		false,						// Does it have a rotating turret?
   2331 		false,						// Can the building be color remapped to indicate owner?
   2332 	RTTI_NONE,						// The object type produced at this factory.
   2333 	DIR_N,							// Starting idle frame to match construction.
   2334 	BSIZE_21, 						// SIZE:			Building size.
   2335 	NULL,								// Preferred exit cell list.
   2336 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2337 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2338 );
   2339 
   2340 static BuildingTypeClass const ClassV34(
   2341 	STRUCT_V34,
   2342 	TXT_CIV34,						// NAME:			Short name of the structure.
   2343 	"V34",							// NAME:			Short name of the structure.
   2344 	FACING_NONE,					// Foundation direction from center of building.
   2345 	XYP_COORD(0,0),				// Exit point for produced units.
   2346 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2347 	0x0000,							//	Vertical offset.
   2348 	0x0000,							// Primary weapon offset along turret centerline.
   2349 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2350 		false,						// Is this building a fake (decoy?)
   2351 		true,							// Animation rate is regulated for constant speed?
   2352 		true,							// Always use the given name for the building?
   2353 		false,						// Is this a wall type structure?
   2354 		true,							// Simple (one frame) damage imagery?
   2355 		false,						// Is it invisible to radar?
   2356 		true,							// Can the player select this?
   2357 		true,							// Is this a legal target for attack or move?
   2358 		false,						// Is this an insignificant building?
   2359 		true,							// Theater specific graphic image?
   2360 		false,						// Does it have a rotating turret?
   2361 		false,						// Can the building be color remapped to indicate owner?
   2362 	RTTI_NONE,						// The object type produced at this factory.
   2363 	DIR_N,							// Starting idle frame to match construction.
   2364 	BSIZE_11, 						// SIZE:			Building size.
   2365 	NULL,								// Preferred exit cell list.
   2366 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2367 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2368 );
   2369 
   2370 static BuildingTypeClass const ClassV35(
   2371 	STRUCT_V35,
   2372 	TXT_CIV35,						// NAME:			Short name of the structure.
   2373 	"V35",							// NAME:			Short name of the structure.
   2374 	FACING_NONE,					// Foundation direction from center of building.
   2375 	XYP_COORD(0,0),				// Exit point for produced units.
   2376 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2377 	0x0000,							//	Vertical offset.
   2378 	0x0000,							// Primary weapon offset along turret centerline.
   2379 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2380 		false,						// Is this building a fake (decoy?)
   2381 		true,							// Animation rate is regulated for constant speed?
   2382 		true,							// Always use the given name for the building?
   2383 		false,						// Is this a wall type structure?
   2384 		true,							// Simple (one frame) damage imagery?
   2385 		false,						// Is it invisible to radar?
   2386 		true,							// Can the player select this?
   2387 		true,							// Is this a legal target for attack or move?
   2388 		false,						// Is this an insignificant building?
   2389 		true,							// Theater specific graphic image?
   2390 		false,						// Does it have a rotating turret?
   2391 		false,						// Can the building be color remapped to indicate owner?
   2392 	RTTI_NONE,						// The object type produced at this factory.
   2393 	DIR_N,							// Starting idle frame to match construction.
   2394 	BSIZE_11, 						// SIZE:			Building size.
   2395 	NULL,								// Preferred exit cell list.
   2396 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2397 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2398 );
   2399 
   2400 static BuildingTypeClass const ClassV36(
   2401 	STRUCT_V36,
   2402 	TXT_CIV36,						// NAME:			Short name of the structure.
   2403 	"V36",							// NAME:			Short name of the structure.
   2404 	FACING_NONE,					// Foundation direction from center of building.
   2405 	XYP_COORD(0,0),				// Exit point for produced units.
   2406 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2407 	0x0000,							//	Vertical offset.
   2408 	0x0000,							// Primary weapon offset along turret centerline.
   2409 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2410 		false,						// Is this building a fake (decoy?)
   2411 		true,							// Animation rate is regulated for constant speed?
   2412 		true,							// Always use the given name for the building?
   2413 		false,						// Is this a wall type structure?
   2414 		true,							// Simple (one frame) damage imagery?
   2415 		false,						// Is it invisible to radar?
   2416 		true,							// Can the player select this?
   2417 		true,							// Is this a legal target for attack or move?
   2418 		false,						// Is this an insignificant building?
   2419 		true,							// Theater specific graphic image?
   2420 		false,						// Does it have a rotating turret?
   2421 		false,						// Can the building be color remapped to indicate owner?
   2422 	RTTI_NONE,						// The object type produced at this factory.
   2423 	DIR_N,							// Starting idle frame to match construction.
   2424 	BSIZE_11, 						// SIZE:			Building size.
   2425 	NULL,								// Preferred exit cell list.
   2426 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2427 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2428 );
   2429 static BuildingTypeClass const ClassV37(
   2430 	STRUCT_V37,
   2431 	TXT_CIV37,						// NAME:			Short name of the structure.
   2432 	"V37",							// NAME:			Short name of the structure.
   2433 	FACING_NONE,					// Foundation direction from center of building.
   2434 	XYP_COORD(0,0),				// Exit point for produced units.
   2435 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2436 	0x0000,							//	Vertical offset.
   2437 	0x0000,							// Primary weapon offset along turret centerline.
   2438 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2439 		false,						// Is this building a fake (decoy?)
   2440 		true,							// Animation rate is regulated for constant speed?
   2441 		true,							// Always use the given name for the building?
   2442 		false,						// Is this a wall type structure?
   2443 		true,							// Simple (one frame) damage imagery?
   2444 		false,						// Is it invisible to radar?
   2445 		true,							// Can the player select this?
   2446 		true,							// Is this a legal target for attack or move?
   2447 		false,						// Is this an insignificant building?
   2448 		true,							// Theater specific graphic image?
   2449 		false,						// Does it have a rotating turret?
   2450 		false,						// Can the building be color remapped to indicate owner?
   2451 	RTTI_NONE,						// The object type produced at this factory.
   2452 	DIR_N,							// Starting idle frame to match construction.
   2453 	BSIZE_42, 						// SIZE:			Building size.
   2454 	NULL,								// Preferred exit cell list.
   2455 	(short const *)ListWestwood,	// OCCUPYLIST:	List of active foundation squares.
   2456 	(short const *)OListWestwood	// OVERLAPLIST:List of overlap cell offset.
   2457 );
   2458 static BuildingTypeClass const ClassMission(
   2459 	STRUCT_MISSION,
   2460 	TXT_CIVMISS,					// NAME:			Short name of the structure.
   2461 	"MISS",							// NAME:			Short name of the structure.
   2462 	FACING_NONE,					// Foundation direction from center of building.
   2463 	XYP_COORD(0,0),				// Exit point for produced units.
   2464 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2465 	0x0000,							//	Vertical offset.
   2466 	0x0000,							// Primary weapon offset along turret centerline.
   2467 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2468 		false,						// Is this building a fake (decoy?)
   2469 		true,							// Animation rate is regulated for constant speed?
   2470 		true,							// Always use the given name for the building?
   2471 		false,						// Is this a wall type structure?
   2472 		true,							// Simple (one frame) damage imagery?
   2473 		false,						// Is it invisible to radar?
   2474 		true,							// Can the player select this?
   2475 		true,							// Is this a legal target for attack or move?
   2476 		false,						// Is this an insignificant building?
   2477 		false,						// Theater specific graphic image?
   2478 		false,						// Does it have a rotating turret?
   2479 		true,							// Can the building be color remapped to indicate owner?
   2480 	RTTI_NONE,						// The object type produced at this factory.
   2481 	DIR_N,							// Starting idle frame to match construction.
   2482 	BSIZE_32, 						// SIZE:			Building size.
   2483 	NULL,								// Preferred exit cell list.
   2484 	(short const *)List32,		// OCCUPYLIST:	List of active foundation squares.
   2485 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2486 );
   2487 
   2488 // Sandbag wall
   2489 static BuildingTypeClass const Sandbag(
   2490 	STRUCT_SANDBAG_WALL,
   2491 	TXT_SANDBAG_WALL,				// NAME:			Short name of the structure.
   2492 	"SBAG",							// NAME:			Short name of the structure.
   2493 	FACING_NONE,					// Foundation direction from center of building.
   2494 	XYP_COORD(0,0),				// Exit point for produced units.
   2495 	REMAP_NONE,						// Sidebar remap logic.
   2496 	0x0000,							//	Vertical offset.
   2497 	0x0000,							// Primary weapon offset along turret centerline.
   2498 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2499 		false,						// Is this building a fake (decoy?)
   2500 		false,						// Animation rate is regulated for constant speed?
   2501 		true,							// Always use the given name for the building?
   2502 		true,							// Is this a wall type structure?
   2503 		false,						// Simple (one frame) damage imagery?
   2504 		false,						// Is it invisible to radar?
   2505 		false,						// Can the player select this?
   2506 		true,							// Is this a legal target for attack or move?
   2507 		true,							// Is this an insignificant building?
   2508 		false,						// Theater specific graphic image?
   2509 		false,						// Does it have a rotating turret?
   2510 		false,						// Can the building be color remapped to indicate owner?
   2511 	RTTI_NONE,						// The object type produced at this factory.
   2512 	DIR_N,							// Starting idle frame to match construction.
   2513 	BSIZE_11, 						// SIZE:			Building size.
   2514 	NULL,								// Preferred exit cell list.
   2515 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2516 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2517 );
   2518 // Cyclone fence
   2519 static BuildingTypeClass const Cyclone(
   2520 	STRUCT_CYCLONE_WALL,
   2521 	TXT_CYCLONE_WALL,				// NAME:			Short name of the structure.
   2522 	"CYCL",							// NAME:			Short name of the structure.
   2523 	FACING_NONE,					// Foundation direction from center of building.
   2524 	XYP_COORD(0,0),				// Exit point for produced units.
   2525 	REMAP_NONE,						// Sidebar remap logic.
   2526 	0x0000,							//	Vertical offset.
   2527 	0x0000,							// Primary weapon offset along turret centerline.
   2528 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2529 		false,						// Is this building a fake (decoy?)
   2530 		false,						// Animation rate is regulated for constant speed?
   2531 		true,							// Always use the given name for the building?
   2532 		true,							// Is this a wall type structure?
   2533 		false,						// Simple (one frame) damage imagery?
   2534 		false,						// Is it invisible to radar?
   2535 		false,						// Can the player select this?
   2536 		true,							// Is this a legal target for attack or move?
   2537 		true,							// Is this an insignificant building?
   2538 		false,						// Theater specific graphic image?
   2539 		false,						// Does it have a rotating turret?
   2540 		false,						// Can the building be color remapped to indicate owner?
   2541 	RTTI_NONE,						// The object type produced at this factory.
   2542 	DIR_N,							// Starting idle frame to match construction.
   2543 	BSIZE_11, 						// SIZE:			Building size.
   2544 	NULL,								// Preferred exit cell list.
   2545 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2546 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2547 );
   2548 // Brick wall
   2549 static BuildingTypeClass const Brick(
   2550 	STRUCT_BRICK_WALL,
   2551 	TXT_BRICK_WALL,				// NAME:			Short name of the structure.
   2552 	"BRIK",							// NAME:			Short name of the structure.
   2553 	FACING_NONE,					// Foundation direction from center of building.
   2554 	XYP_COORD(0,0),				// Exit point for produced units.
   2555 	REMAP_NONE,						// Sidebar remap logic.
   2556 	0x0000,							//	Vertical offset.
   2557 	0x0000,							// Primary weapon offset along turret centerline.
   2558 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2559 		false,						// Is this building a fake (decoy?)
   2560 		false,						// Animation rate is regulated for constant speed?
   2561 		true,							// Always use the given name for the building?
   2562 		true,							// Is this a wall type structure?
   2563 		false,						// Simple (one frame) damage imagery?
   2564 		false,						// Is it invisible to radar?
   2565 		false,						// Can the player select this?
   2566 		true,							// Is this a legal target for attack or move?
   2567 		true,							// Is this an insignificant building?
   2568 		false,						// Theater specific graphic image?
   2569 		false,						// Does it have a rotating turret?
   2570 		false,						// Can the building be color remapped to indicate owner?
   2571 	RTTI_NONE,						// The object type produced at this factory.
   2572 	DIR_N,							// Starting idle frame to match construction.
   2573 	BSIZE_11, 						// SIZE:			Building size.
   2574 	NULL,								// Preferred exit cell list.
   2575 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2576 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2577 );
   2578 // Barbwire wall
   2579 static BuildingTypeClass const Barbwire(
   2580 	STRUCT_BARBWIRE_WALL,
   2581 	TXT_BARBWIRE_WALL,			// NAME:			Short name of the structure.
   2582 	"BARB",							// NAME:			Short name of the structure.
   2583 	FACING_NONE,					// Foundation direction from center of building.
   2584 	XYP_COORD(0,0),				// Exit point for produced units.
   2585 	REMAP_NONE,						// Sidebar remap logic.
   2586 	0x0000,							//	Vertical offset.
   2587 	0x0000,							// Primary weapon offset along turret centerline.
   2588 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2589 		false,						// Is this building a fake (decoy?)
   2590 		false,						// Animation rate is regulated for constant speed?
   2591 		true,							// Always use the given name for the building?
   2592 		true,							// Is this a wall type structure?
   2593 		false,						// Simple (one frame) damage imagery?
   2594 		false,						// Is it invisible to radar?
   2595 		false,						// Can the player select this?
   2596 		true,							// Is this a legal target for attack or move?
   2597 		true,							// Is this an insignificant building?
   2598 		false,						// Theater specific graphic image?
   2599 		false,						// Does it have a rotating turret?
   2600 		false,						// Can the building be color remapped to indicate owner?
   2601 	RTTI_NONE,						// The object type produced at this factory.
   2602 	DIR_N,							// Starting idle frame to match construction.
   2603 	BSIZE_11, 						// SIZE:			Building size.
   2604 	NULL,								// Preferred exit cell list.
   2605 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2606 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2607 );
   2608 // Wood wall
   2609 static BuildingTypeClass const Wood(
   2610 	STRUCT_WOOD_WALL,
   2611 	TXT_WOOD_WALL,					// NAME:			Short name of the structure.
   2612 	"WOOD",							// NAME:			Short name of the structure.
   2613 	FACING_NONE,					// Foundation direction from center of building.
   2614 	XYP_COORD(0,0),				// Exit point for produced units.
   2615 	REMAP_NONE,						// Sidebar remap logic.
   2616 	0x0000,							//	Vertical offset.
   2617 	0x0000,							// Primary weapon offset along turret centerline.
   2618 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2619 		false,						// Is this building a fake (decoy?)
   2620 		false,						// Animation rate is regulated for constant speed?
   2621 		true,							// Always use the given name for the building?
   2622 		true,							// Is this a wall type structure?
   2623 		false,						// Simple (one frame) damage imagery?
   2624 		false,						// Is it invisible to radar?
   2625 		false,						// Can the player select this?
   2626 		true,							// Is this a legal target for attack or move?
   2627 		true,							// Is this an insignificant building?
   2628 		false,						// Theater specific graphic image?
   2629 		false,						// Does it have a rotating turret?
   2630 		false,						// Can the building be color remapped to indicate owner?
   2631 	RTTI_NONE,						// The object type produced at this factory.
   2632 	DIR_N,							// Starting idle frame to match construction.
   2633 	BSIZE_11, 						// SIZE:			Building size.
   2634 	NULL,								// Preferred exit cell list.
   2635 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2636 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2637 );
   2638 static BuildingTypeClass const Fence(
   2639 	STRUCT_FENCE,
   2640 	TXT_FENCE,						// NAME:			Short name of the structure.
   2641 	"FENC",							// NAME:			Short name of the structure.
   2642 	FACING_NONE,					// Foundation direction from center of building.
   2643 	XYP_COORD(0,0),				// Exit point for produced units.
   2644 	REMAP_NONE,						// Sidebar remap logic.
   2645 	0x0000,							//	Vertical offset.
   2646 	0x0000,							// Primary weapon offset along turret centerline.
   2647 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2648 		false,						// Is this building a fake (decoy?)
   2649 		false,						// Animation rate is regulated for constant speed?
   2650 		true,							// Always use the given name for the building?
   2651 		true,							// Is this a wall type structure?
   2652 		false,						// Simple (one frame) damage imagery?
   2653 		false,						// Is it invisible to radar?
   2654 		false,						// Can the player select this?
   2655 		true,							// Is this a legal target for attack or move?
   2656 		true,							// Is this an insignificant building?
   2657 		false,						// Theater specific graphic image?
   2658 		false,						// Does it have a rotating turret?
   2659 		false,						// Can the building be color remapped to indicate owner?
   2660 	RTTI_NONE,						// The object type produced at this factory.
   2661 	DIR_N,							// Starting idle frame to match construction.
   2662 	BSIZE_11, 						// SIZE:			Building size.
   2663 	NULL,								// Preferred exit cell list.
   2664 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2665 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2666 );
   2667 
   2668 
   2669 #ifdef FIXIT_ANTS
   2670 static BuildingTypeClass const ClassQueen(
   2671 	STRUCT_QUEEN,
   2672 	TXT_NONE,						// NAME:			Short name of the structure.
   2673 	"QUEE",							// NAME:			Short name of the structure.
   2674 	FACING_NONE,					// Foundation direction from center of building.
   2675 	XYP_COORD(24,47),				// Exit point for produced units.
   2676 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2677 	0x0000,							//	Vertical offset.
   2678 	0x0000,							// Primary weapon offset along turret centerline.
   2679 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2680 		false,						// Is this building a fake (decoy?)
   2681 		true,							// Animation rate is regulated for constant speed?
   2682 		true,							// Always use the given name for the building?
   2683 		false,						// Is this a wall type structure?
   2684 		false,						// Simple (one frame) damage imagery?
   2685 		false,						// Is it invisible to radar?
   2686 		true,							// Can the player select this?
   2687 		true,							// Is this a legal target for attack or move?
   2688 		false,						// Is this an insignificant building?
   2689 		false,						// Theater specific graphic image?
   2690 		false,						// Does it have a rotating turret?
   2691 		true,							// Can the building be color remapped to indicate owner?
   2692 	RTTI_NONE,						// The object type produced at this factory.
   2693 	DIR_N,							// Starting idle frame to match construction.
   2694 	BSIZE_21, 						// SIZE:			Building size.
   2695 	NULL,								// Preferred exit cell list.
   2696 	(short const *)List11,		// OCCUPYLIST:	List of active foundation squares.
   2697 	NULL								// OVERLAPLIST:List of overlap cell offset.
   2698 );
   2699 static BuildingTypeClass const ClassLarva1(
   2700 	STRUCT_LARVA1,
   2701 	TXT_NONE,						// NAME:			Short name of the structure.
   2702 	"LAR1",							// NAME:			Short name of the structure.
   2703 	FACING_NONE,					// Foundation direction from center of building.
   2704 	XYP_COORD(0,0),				// Exit point for produced units.
   2705 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2706 	0x0000,							//	Vertical offset.
   2707 	0x0000,							// Primary weapon offset along turret centerline.
   2708 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2709 		false,						// Is this building a fake (decoy?)
   2710 		false,						// Animation rate is regulated for constant speed?
   2711 		true,							// Always use the given name for the building?
   2712 		false,						// Is this a wall type structure?
   2713 		true,							// Simple (one frame) damage imagery?
   2714 		true,							// Is it invisible to radar?
   2715 		true,							// Can the player select this?
   2716 		true,							// Is this a legal target for attack or move?
   2717 		true,							// Is this an insignificant building?
   2718 		false,						// Theater specific graphic image?
   2719 		false,						// Does it have a rotating turret?
   2720 		false,						// Can the building be color remapped to indicate owner?
   2721 	RTTI_NONE,						// The object type produced at this factory.
   2722 	DIR_N,							// Starting idle frame to match construction.
   2723 	BSIZE_11, 						// SIZE:			Building size.
   2724 	NULL,								// Preferred exit cell list.
   2725 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2726 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2727 );
   2728 static BuildingTypeClass const ClassLarva2(
   2729 	STRUCT_LARVA2,
   2730 	TXT_NONE,						// NAME:			Short name of the structure.
   2731 	"LAR2",							// NAME:			Short name of the structure.
   2732 	FACING_NONE,					// Foundation direction from center of building.
   2733 	XYP_COORD(0,0),				// Exit point for produced units.
   2734 	REMAP_ALTERNATE,				// Sidebar remap logic.
   2735 	0x0000,							//	Vertical offset.
   2736 	0x0000,							// Primary weapon offset along turret centerline.
   2737 	0x0000,							// Primary weapon lateral offset along turret centerline.
   2738 		false,						// Is this building a fake (decoy?)
   2739 		false,						// Animation rate is regulated for constant speed?
   2740 		true,							// Always use the given name for the building?
   2741 		false,						// Is this a wall type structure?
   2742 		true,							// Simple (one frame) damage imagery?
   2743 		true,							// Is it invisible to radar?
   2744 		true,							// Can the player select this?
   2745 		true,							// Is this a legal target for attack or move?
   2746 		true,							// Is this an insignificant building?
   2747 		false,						// Theater specific graphic image?
   2748 		false,						// Does it have a rotating turret?
   2749 		false,						// Can the building be color remapped to indicate owner?
   2750 	RTTI_NONE,						// The object type produced at this factory.
   2751 	DIR_N,							// Starting idle frame to match construction.
   2752 	BSIZE_11, 						// SIZE:			Building size.
   2753 	NULL,								// Preferred exit cell list.
   2754 	(short const *)List1,		// OCCUPYLIST:	List of active foundation squares.
   2755 	(short const *)NULL			// OVERLAPLIST:List of overlap cell offset.
   2756 );
   2757 #endif
   2758 void const * BuildingTypeClass::WarFactoryOverlay;
   2759 void const * LightningShapes;
   2760 
   2761 
   2762 /***********************************************************************************************
   2763  * BuildingTypeClass::BuildingTypeClass -- This is the constructor for the building types.     *
   2764  *                                                                                             *
   2765  *    This is the constructor used to create the building types.                               *
   2766  *                                                                                             *
   2767  * INPUT:   see below...                                                                       *
   2768  *                                                                                             *
   2769  * OUTPUT:  none                                                                               *
   2770  *                                                                                             *
   2771  * WARNINGS:   none                                                                            *
   2772  *                                                                                             *
   2773  * HISTORY:                                                                                    *
   2774  *   07/29/1994 JLB : Created.                                                                 *
   2775  *=============================================================================================*/
   2776 BuildingTypeClass::BuildingTypeClass(
   2777 						StructType type,
   2778 						int name,
   2779 						char const * ininame,
   2780 						FacingType foundation,
   2781 						COORDINATE exitpoint,
   2782 						RemapType remap,
   2783 						int verticaloffset,
   2784 						int primaryoffset,
   2785 						int primarylateral,
   2786 						bool is_fake,
   2787 						bool is_regulated,
   2788 						bool is_nominal,
   2789 						bool is_wall,
   2790 						bool is_simpledamage,
   2791 						bool is_stealthy,
   2792 						bool is_selectable,
   2793 						bool is_legal_target,
   2794 						bool is_insignificant,
   2795 						bool is_theater,
   2796 						bool is_turret_equipped,
   2797 						bool is_remappable,
   2798 						RTTIType tobuild,
   2799 						DirType sframe,
   2800 						BSizeType size,
   2801 						short const * exitlist,
   2802 						short const * sizelist,
   2803 						short const * overlap) :
   2804 								TechnoTypeClass(RTTI_BUILDINGTYPE,
   2805 													int(type),
   2806 													name,
   2807 													ininame,
   2808 													remap,
   2809 													verticaloffset,
   2810 													primaryoffset,
   2811 													primarylateral,
   2812 													primaryoffset,
   2813 													primarylateral,
   2814 													is_nominal,
   2815 													is_stealthy,
   2816 													is_selectable,
   2817 													is_legal_target,
   2818 													is_insignificant,
   2819 													false,
   2820 													is_theater,
   2821 													is_turret_equipped,
   2822 													is_remappable,
   2823 													true,
   2824 													(is_turret_equipped ? 32 : 1),
   2825 													SPEED_NONE),
   2826 	IsBase(true),
   2827 	IsFake(is_fake),
   2828 	IsBibbed(false),
   2829 	IsWall(is_wall),
   2830 	IsSimpleDamage(is_simpledamage),
   2831 	IsCaptureable(false),
   2832 	IsRegulated(is_regulated),
   2833 	IsPowered(false),
   2834 	IsUnsellable(false),
   2835 	FoundationFace(foundation),
   2836 	Adjacent(1),
   2837 	ToBuild(tobuild),
   2838 	ExitCoordinate(exitpoint),
   2839 	ExitList(exitlist),
   2840 	Type(type),
   2841 	StartFace(sframe),
   2842 	Capacity(0),
   2843 	Power(0),
   2844 	Drain(0),
   2845 	Size(size),
   2846 	OccupyList(sizelist),
   2847 	OverlapList(overlap),
   2848 	BuildupData(0)
   2849 {
   2850 
   2851 	Anims[BSTATE_CONSTRUCTION].Start = 0;
   2852 	Anims[BSTATE_CONSTRUCTION].Count = 1;
   2853 	Anims[BSTATE_CONSTRUCTION].Rate = 0;
   2854 
   2855 	Anims[BSTATE_IDLE].Start = 0;
   2856 	Anims[BSTATE_IDLE].Count = 1;
   2857 	Anims[BSTATE_IDLE].Rate = 0;
   2858 
   2859 	Anims[BSTATE_ACTIVE].Start = 0;
   2860 	Anims[BSTATE_ACTIVE].Count = 1;
   2861 	Anims[BSTATE_ACTIVE].Rate = 0;
   2862 
   2863 	Anims[BSTATE_AUX1].Start = 0;
   2864 	Anims[BSTATE_AUX1].Count = 1;
   2865 	Anims[BSTATE_AUX1].Rate = 0;
   2866 
   2867 	Anims[BSTATE_AUX2].Start = 0;
   2868 	Anims[BSTATE_AUX2].Count = 1;
   2869 	Anims[BSTATE_AUX2].Rate = 0;
   2870 }
   2871 
   2872 
   2873 /***********************************************************************************************
   2874  * BuildingTypeClass::operator new -- Allocates a building type object from the special heap.  *
   2875  *                                                                                             *
   2876  *    This routine will allocate a building type object from the special heap used just for    *
   2877  *    allocation of object of this type.                                                       *
   2878  *                                                                                             *
   2879  * INPUT:   none                                                                               *
   2880  *                                                                                             *
   2881  * OUTPUT:  Returns with a pointer to the newly allocated object. If the allocation could not  *
   2882  *          succeed, then NULL will be returned.                                               *
   2883  *                                                                                             *
   2884  * WARNINGS:   none                                                                            *
   2885  *                                                                                             *
   2886  * HISTORY:                                                                                    *
   2887  *   07/06/1996 JLB : Created.                                                                 *
   2888  *=============================================================================================*/
   2889 void * BuildingTypeClass::operator new(size_t)
   2890 {
   2891 	return(BuildingTypes.Alloc());
   2892 }
   2893 
   2894 
   2895 /***********************************************************************************************
   2896  * BuildingTypeClass::operator delete -- Deletes a building type object from the special heap. *
   2897  *                                                                                             *
   2898  *    This will delete a previously allocated building type object. The memory is returned     *
   2899  *    to the special heap that is used for that purpose.                                       *
   2900  *                                                                                             *
   2901  * INPUT:   ptr   -- Pointer to the building type object to return to the special heap.        *
   2902  *                                                                                             *
   2903  * OUTPUT:  none                                                                               *
   2904  *                                                                                             *
   2905  * WARNINGS:   none                                                                            *
   2906  *                                                                                             *
   2907  * HISTORY:                                                                                    *
   2908  *   07/06/1996 JLB : Created.                                                                 *
   2909  *=============================================================================================*/
   2910 void BuildingTypeClass::operator delete(void * ptr)
   2911 {
   2912 	BuildingTypes.Free((BuildingTypeClass *)ptr);
   2913 }
   2914 
   2915 
   2916 /***********************************************************************************************
   2917  * BuildingTypeClass::Init_Heap -- Initialize the heap as necessary for the building type obje *
   2918  *                                                                                             *
   2919  *    This routine performs the necessary heap initializations. Since we know exactly what     *
   2920  *    building type objects will be needed, they are pre-allocated at this time.               *
   2921  *                                                                                             *
   2922  * INPUT:   none                                                                               *
   2923  *                                                                                             *
   2924  * OUTPUT:  none                                                                               *
   2925  *                                                                                             *
   2926  * WARNINGS:   Call this routine only once.                                                    *
   2927  *                                                                                             *
   2928  * HISTORY:                                                                                    *
   2929  *   07/06/1996 JLB : Created.                                                                 *
   2930  *=============================================================================================*/
   2931 void BuildingTypeClass::Init_Heap(void)
   2932 {
   2933 	/*
   2934 	**	These building type class objects must be allocated in the exact order that they
   2935 	**	are specified in the StructType enumeration. This is necessary because the heap
   2936 	**	allocation block index serves double duty as the type number index.
   2937 	*/
   2938 	new BuildingTypeClass(ClassAdvancedTech);	// STRUCT_ADVANCED_TECH
   2939 	new BuildingTypeClass(ClassIronCurtain);	// STRUCT_IRON_CURTAIN
   2940 	new BuildingTypeClass(ClassWeapon);			//	STRUCT_WEAP
   2941 	new BuildingTypeClass(ClassChronosphere);	// STRUCT_CHRONOSPHERE
   2942 	new BuildingTypeClass(ClassPillbox);		//	STRUCT_PILLBOX
   2943 	new BuildingTypeClass(ClassCamoPillbox);	//	STRUCT_CAMOPILLBOX
   2944 	new BuildingTypeClass(ClassCommand);		//	STRUCT_RADAR
   2945 	new BuildingTypeClass(ClassGapGenerator);	// STRUCT_GAP
   2946 	new BuildingTypeClass(ClassTurret);			//	STRUCT_TURRET
   2947 	new BuildingTypeClass(ClassAAGun);			// STRUCT_AAGUN
   2948 	new BuildingTypeClass(ClassFlameTurret);	//	STRUCT_FLAME_TURRET
   2949 	new BuildingTypeClass(ClassConst);			//	STRUCT_CONST
   2950 	new BuildingTypeClass(ClassRefinery);		//	STRUCT_REFINERY
   2951 	new BuildingTypeClass(ClassStorage);		//	STRUCT_STORAGE
   2952 	new BuildingTypeClass(ClassHelipad);		//	STRUCT_HELIPAD
   2953 	new BuildingTypeClass(ClassSAM);				//	STRUCT_SAM
   2954 	new BuildingTypeClass(ClassAirStrip);		//	STRUCT_AIRSTRIP
   2955 	new BuildingTypeClass(ClassPower);			//	STRUCT_POWER
   2956 	new BuildingTypeClass(ClassAdvancedPower);//	STRUCT_ADVANCED_POWER
   2957 	new BuildingTypeClass(ClassSovietTech);	// STRUCT_SOVIET_TECH
   2958 	new BuildingTypeClass(ClassHospital);		//	STRUCT_HOSPITAL
   2959 	new BuildingTypeClass(ClassBarracks);		//	STRUCT_BARRACKS
   2960 	new BuildingTypeClass(ClassTent);			//	STRUCT_TENT
   2961 	new BuildingTypeClass(ClassKennel);			// STRUCT_KENNEL
   2962 	new BuildingTypeClass(ClassRepair);			//	STRUCT_REPAIR
   2963 	new BuildingTypeClass(ClassBioLab);			//	STRUCT_BIO_LAB
   2964 	new BuildingTypeClass(ClassMission);		//	STRUCT_MISSION
   2965 	new BuildingTypeClass(ClassShipYard);		//	STRUCT_SHIP_YARD
   2966 	new BuildingTypeClass(ClassSubPen);			//	STRUCT_SUB_PEN
   2967 	new BuildingTypeClass(ClassMissileSilo);	// STRUCT_MSLO
   2968 	new BuildingTypeClass(ClassForwardCom);	// STRUCT_FORWARD_COM
   2969 	new BuildingTypeClass(ClassTesla);			//	STRUCT_TESLA
   2970 	new BuildingTypeClass(ClassFakeWeapon);	// STRUCT_FAKEWEAP
   2971 	new BuildingTypeClass(ClassFakeConst);		// STRUCT_FAKECONST
   2972 	new BuildingTypeClass(ClassFakeShipYard);	// STRUCT_FAKE_YARD
   2973 	new BuildingTypeClass(ClassFakeSubPen);	// STRUCT_FAKE_PEN
   2974 	new BuildingTypeClass(ClassFakeCommand);	// STRUCT_FAKE_RADAR
   2975 	new BuildingTypeClass(Sandbag);				// STRUCT_SANDBAG_WALL
   2976 	new BuildingTypeClass(Cyclone);				//	STRUCT_CYCLONE_WALL
   2977 	new BuildingTypeClass(Brick);					// STRUCT_BRICK_WALL
   2978 	new BuildingTypeClass(Barbwire);				// STRUCT_BARBWIRE_WALL
   2979 	new BuildingTypeClass(Wood);					//	STRUCT_WOOD_WALL
   2980 	new BuildingTypeClass(Fence);					// STRUCT_FENCE
   2981 	new BuildingTypeClass(ClassAVMine);			// STRUCT_AVMINE
   2982 	new BuildingTypeClass(ClassAPMine);			// STRUCT_APMINE
   2983 	new BuildingTypeClass(ClassV01);				//	STRUCT_V1
   2984 	new BuildingTypeClass(ClassV02);				//	STRUCT_V2
   2985 	new BuildingTypeClass(ClassV03);				//	STRUCT_V3
   2986 	new BuildingTypeClass(ClassV04);				//	STRUCT_V4
   2987 	new BuildingTypeClass(ClassV05);				//	STRUCT_V5
   2988 	new BuildingTypeClass(ClassV06);				//	STRUCT_V6
   2989 	new BuildingTypeClass(ClassV07);				//	STRUCT_V7
   2990 	new BuildingTypeClass(ClassV08);				//	STRUCT_V8
   2991 	new BuildingTypeClass(ClassV09);				//	STRUCT_V9
   2992 	new BuildingTypeClass(ClassV10);				//	STRUCT_V10
   2993 	new BuildingTypeClass(ClassV11);				//	STRUCT_V11
   2994 	new BuildingTypeClass(ClassV12);				//	STRUCT_V12
   2995 	new BuildingTypeClass(ClassV13);				//	STRUCT_V13
   2996 	new BuildingTypeClass(ClassV14);				//	STRUCT_V14
   2997 	new BuildingTypeClass(ClassV15);				//	STRUCT_V15
   2998 	new BuildingTypeClass(ClassV16);				//	STRUCT_V16
   2999 	new BuildingTypeClass(ClassV17);				//	STRUCT_V17
   3000 	new BuildingTypeClass(ClassV18);				//	STRUCT_V18
   3001 	new BuildingTypeClass(ClassV19);				//	STRUCT_PUMP
   3002 	new BuildingTypeClass(ClassV20);				//	STRUCT_V20
   3003 	new BuildingTypeClass(ClassV21);				//	STRUCT_V21
   3004 	new BuildingTypeClass(ClassV22);				//	STRUCT_V22
   3005 	new BuildingTypeClass(ClassV23);				//	STRUCT_V23
   3006 	new BuildingTypeClass(ClassV24);				//	STRUCT_V24
   3007 	new BuildingTypeClass(ClassV25);				//	STRUCT_V25
   3008 	new BuildingTypeClass(ClassV26);				//	STRUCT_V26
   3009 	new BuildingTypeClass(ClassV27);				//	STRUCT_V27
   3010 	new BuildingTypeClass(ClassV28);				//	STRUCT_V28
   3011 	new BuildingTypeClass(ClassV29);				//	STRUCT_V29
   3012 	new BuildingTypeClass(ClassV30);				//	STRUCT_V30
   3013 	new BuildingTypeClass(ClassV31);				//	STRUCT_V31
   3014 	new BuildingTypeClass(ClassV32);				//	STRUCT_V32
   3015 	new BuildingTypeClass(ClassV33);				//	STRUCT_V33
   3016 	new BuildingTypeClass(ClassV34);				//	STRUCT_V34
   3017 	new BuildingTypeClass(ClassV35);				//	STRUCT_V35
   3018 	new BuildingTypeClass(ClassV36);				//	STRUCT_V36
   3019 	new BuildingTypeClass(ClassV37);				//	STRUCT_V37
   3020 	new BuildingTypeClass(ClassBarrel);			// STRUCT_BARREL
   3021 	new BuildingTypeClass(ClassBarrel3);		// STRUCT_BARREL3
   3022 
   3023 #ifdef FIXIT_ANTS
   3024 	new BuildingTypeClass(ClassQueen);			// STRUCT_QUEEN
   3025 	new BuildingTypeClass(ClassLarva1);			// STRUCT_LARVA1
   3026 	new BuildingTypeClass(ClassLarva2);			// STRUCT_LARVA2
   3027 #endif
   3028 
   3029 }
   3030 
   3031 
   3032 /***********************************************************************************************
   3033  * BuildingTypeClass::One_Time -- Performs special one time action for buildings.              *
   3034  *                                                                                             *
   3035  *    This routine is used to do the one time action necessary to handle building type class   *
   3036  *    objects. This entails loading of the building shapes and the brain file used by          *
   3037  *    buildings.                                                                               *
   3038  *                                                                                             *
   3039  * INPUT:   none                                                                               *
   3040  *                                                                                             *
   3041  * OUTPUT:  none                                                                               *
   3042  *                                                                                             *
   3043  * WARNINGS:   This routine should only be called ONCE.                                        *
   3044  *                                                                                             *
   3045  * HISTORY:                                                                                    *
   3046  *   05/28/1994 JLB : Created.                                                                 *
   3047  *   06/11/1994 JLB : Updated construction time and frame count logic.                         *
   3048  *=============================================================================================*/
   3049 void BuildingTypeClass::One_Time(void)
   3050 {
   3051 	static const struct {
   3052 		StructType	Class;			// Building class number.
   3053 		BStateType	Stage;			// Animation sequence to assign animation range to.
   3054 		int			Start;			// Starting frame number.
   3055 		int			Length;			// Number of frames (-1 means use all frames).
   3056 		int			Rate;				// Rate of animation.
   3057 	} _anims[] = {
   3058 		{STRUCT_CHRONOSPHERE,	BSTATE_IDLE,	0, 4, 3},	// idling
   3059 		{STRUCT_CHRONOSPHERE,	BSTATE_ACTIVE,	4, 16,3},	// charging up and activating
   3060 		{STRUCT_MSLO,				BSTATE_IDLE,	0, 0, 0},
   3061 		{STRUCT_MSLO,				BSTATE_ACTIVE,	0, 5, 2},	// door opening
   3062 		{STRUCT_MSLO,				BSTATE_AUX1,	4, 1, 0},	// door held open
   3063 		{STRUCT_MSLO,				BSTATE_AUX2,	5, 3, 2},	// door closing
   3064 		{STRUCT_CAMOPILLBOX,		BSTATE_ACTIVE,	0,	2, 1},
   3065 		{STRUCT_GAP,				BSTATE_IDLE,	0,	32,3},
   3066 		{STRUCT_AIRSTRIP,			BSTATE_IDLE,	0,	0,	0},
   3067 		{STRUCT_AIRSTRIP,			BSTATE_AUX1,	0,	8,	3},
   3068 		{STRUCT_BARRACKS,			BSTATE_ACTIVE,	0,	10,3},
   3069 		{STRUCT_BARRACKS,			BSTATE_IDLE,	0,	10,3},
   3070 		{STRUCT_TENT,				BSTATE_ACTIVE,	0,	10,3},
   3071 		{STRUCT_TENT,				BSTATE_IDLE,	0,	10,3},
   3072 #ifdef FIXIT_ANTS
   3073 		{STRUCT_QUEEN,				BSTATE_IDLE,	0,	10,3},
   3074 #endif
   3075 		{STRUCT_CONST,				BSTATE_ACTIVE,	0,	26,3},
   3076 		{STRUCT_FAKECONST,		BSTATE_ACTIVE,	0,	26,3},
   3077 		{STRUCT_HELIPAD,			BSTATE_ACTIVE,	0,	7,	4},
   3078 		{STRUCT_HELIPAD,			BSTATE_IDLE,	0,	0,	0},
   3079 		{STRUCT_HOSPITAL,			BSTATE_IDLE,	0,	4,	3},
   3080 		{STRUCT_PUMP,				BSTATE_IDLE,	0,	14,4},
   3081 		{STRUCT_REPAIR,			BSTATE_ACTIVE,	0,	7,	2},
   3082 		{STRUCT_REPAIR,			BSTATE_IDLE,	0,	1,	0},
   3083 		{STRUCT_V20,				BSTATE_IDLE,	0,	3,	3},
   3084 		{STRUCT_V21,				BSTATE_IDLE,	0,	3,	3},
   3085 		{STRUCT_V22,				BSTATE_IDLE,	0,	3,	3},
   3086 		{STRUCT_V23,				BSTATE_IDLE,	0,	3,	3},
   3087 		{STRUCT_WEAP,				BSTATE_ACTIVE,	0,	1,	0},
   3088 		{STRUCT_WEAP,				BSTATE_IDLE,	0,	1,	0},
   3089 		{STRUCT_FAKEWEAP,			BSTATE_ACTIVE,	0,	1,	0},
   3090 		{STRUCT_FAKEWEAP,			BSTATE_IDLE,	0,	1,	0},
   3091 		{STRUCT_IRON_CURTAIN,	BSTATE_ACTIVE,	0,	11,3},
   3092 		{STRUCT_TESLA,				BSTATE_ACTIVE,	0,	10,2},
   3093 		{STRUCT_AIRSTRIP,			BSTATE_IDLE,	0,	8,	3}
   3094 	};
   3095 
   3096 	for (int sindex = STRUCT_FIRST; sindex < STRUCT_COUNT; sindex++) {
   3097 		char	fullname[_MAX_FNAME+_MAX_EXT];
   3098 		char	buffer[_MAX_FNAME];
   3099 		BuildingTypeClass const & building = As_Reference((StructType)sindex);
   3100 		/*
   3101 		**	Fetch the sidebar cameo image for this building.
   3102 		*/
   3103 		if (building.Level != -1) {
   3104 //		if (building.IsBuildable) {
   3105 			sprintf(buffer, "%sICON", building.Graphic_Name());
   3106 
   3107 			if (building.IsFake) {
   3108 				buffer[3] = 'F';
   3109 			}
   3110 
   3111 			_makepath(fullname, NULL, NULL, buffer, ".SHP");
   3112 			((void const *&)building.CameoData) = MFCD::Retrieve(fullname);
   3113 		}
   3114 
   3115 		/*
   3116 		**	Fetch the construction animation for this building.
   3117 		*/
   3118 		sprintf(buffer, "%sMAKE", building.Graphic_Name());
   3119 		_makepath(fullname, NULL, NULL, buffer, ".SHP");
   3120 		void const * dataptr;
   3121 		dataptr = MFCD::Retrieve(fullname);
   3122 		((void const *&)building.BuildupData) = dataptr;
   3123 		if (dataptr != NULL) {
   3124 			int timedelay = 1;
   3125 			int count = Get_Build_Frame_Count(dataptr);
   3126 			if (count > 0) {
   3127 				timedelay = (Rule.BuildupTime * TICKS_PER_MINUTE) / count;
   3128 			}
   3129 			building.Init_Anim(BSTATE_CONSTRUCTION, 0, count, timedelay);
   3130 		}
   3131 
   3132 		/*
   3133 		**	Fetch the normal game shape for this building.
   3134 		*/
   3135 		_makepath(fullname, NULL, NULL, building.Graphic_Name(), ".SHP");
   3136 		((void const *&)building.ImageData) = MFCD::Retrieve(fullname);
   3137 	}
   3138 
   3139 	// Try to load weap2.shp and tesla coil's lightning shapes
   3140 	char fullname[_MAX_FNAME+_MAX_EXT];
   3141 	_makepath(fullname, NULL, NULL, (char const *)"WEAP2",".SHP");
   3142 	WarFactoryOverlay = MFCD::Retrieve(fullname);
   3143 	_makepath(fullname, NULL, NULL, (char const *)"LITNING",".SHP");
   3144 	LightningShapes = MFCD::Retrieve(fullname);
   3145 
   3146 	/*
   3147 	**	Install all the special animation sequences for the different building types.
   3148 	*/
   3149 	for (unsigned index = 0; index < (sizeof(_anims) / sizeof(_anims[0])); index++) {
   3150 		As_Reference(_anims[index].Class).Init_Anim(_anims[index].Stage, _anims[index].Start, _anims[index].Length, _anims[index].Rate);
   3151 	}
   3152 
   3153 }
   3154 
   3155 
   3156 /***********************************************************************************************
   3157  * Struct_From_Name -- Find BData structure from its name.                                     *
   3158  *                                                                                             *
   3159  *    This routine will convert an ASCII name for a building class into                        *
   3160  *    the actual building class it represents.                                                 *
   3161  *                                                                                             *
   3162  * INPUT:   name  -- ASCII representation of a building class.                                 *
   3163  *                                                                                             *
   3164  * OUTPUT:  Returns with the actual building class number that the string                      *
   3165  *          represents.                                                                        *
   3166  *                                                                                             *
   3167  * WARNINGS:   none                                                                            *
   3168  *                                                                                             *
   3169  * HISTORY:                                                                                    *
   3170  *   10/07/1992 JLB : Created.                                                                 *
   3171  *   05/02/1994 JLB : Converted to member function.                                            *
   3172  *=============================================================================================*/
   3173 StructType BuildingTypeClass::From_Name(char const * name)
   3174 {
   3175 	if (name != NULL) {
   3176 		for (int classid = STRUCT_FIRST; classid < STRUCT_COUNT; classid++) {
   3177 			if (stricmp(As_Reference((StructType)classid).IniName, name) == 0) {
   3178 				return((StructType)classid);
   3179 			}
   3180 		}
   3181 	}
   3182 	return(STRUCT_NONE);
   3183 }
   3184 
   3185 
   3186 #ifdef SCENARIO_EDITOR
   3187 /***********************************************************************************************
   3188  * BuildingTypeClass::Display -- Renders a generic view of building.                           *
   3189  *                                                                                             *
   3190  *    This routine is used to display a generic representation of the                          *
   3191  *    building. Typical use of this occurs with the scenario editor.                           *
   3192  *                                                                                             *
   3193  * INPUT:   x,y      -- Coordinate to display the building (centered).                         *
   3194  *                                                                                             *
   3195  *          window   -- The window the building should be rendered                             *
   3196  *                      relative to.                                                           *
   3197  *                                                                                             *
   3198  *          house    -- The house color to use for the building.                               *
   3199  *                                                                                             *
   3200  * OUTPUT:  none                                                                               *
   3201  *                                                                                             *
   3202  * WARNINGS:   none                                                                            *
   3203  *                                                                                             *
   3204  * HISTORY:                                                                                    *
   3205  *   05/23/1994 JLB : Created.                                                                 *
   3206  *=============================================================================================*/
   3207 void BuildingTypeClass::Display(int x, int y, WindowNumberType window, HousesType ) const
   3208 {
   3209 	void const * ptr = Get_Cameo_Data();
   3210 	if (ptr == NULL) {
   3211 		IsTheaterShape = IsTheater;
   3212 		ptr = Get_Image_Data();
   3213 	}
   3214 	CC_Draw_Shape(ptr, 0, x, y, window, SHAPE_CENTER|SHAPE_WIN_REL);
   3215 	IsTheaterShape = false;
   3216 }
   3217 
   3218 
   3219 /***********************************************************************************************
   3220  * BuildingTypeClass::Prep_For_Add -- Prepares scenario editor for adding a                    *
   3221  *                                                                                             *
   3222  *    This routine is used to prepare the scenario editor for the addition                     *
   3223  *    of a building object to the game.                                                        *
   3224  *                                                                                             *
   3225  * INPUT:   none                                                                               *
   3226  *                                                                                             *
   3227  * OUTPUT:  none                                                                               *
   3228  *                                                                                             *
   3229  * WARNINGS:   none                                                                            *
   3230  *                                                                                             *
   3231  * HISTORY:                                                                                    *
   3232  *   05/23/1994 JLB : Created.                                                                 *
   3233  *   06/04/1994 JLB : Uses map editing interface routines.                                     *
   3234  *=============================================================================================*/
   3235 void BuildingTypeClass::Prep_For_Add(void)
   3236 {
   3237 	for (StructType index = STRUCT_FIRST; index < STRUCT_COUNT; index++) {
   3238 		if (As_Reference(index).Get_Image_Data()) {
   3239 			Map.Add_To_List(&As_Reference(index));
   3240 		}
   3241 	}
   3242 }
   3243 #endif
   3244 
   3245 
   3246 /***********************************************************************************************
   3247  * BuildingTypeClass::Create_And_Place -- Creates and places a building object onto the map.   *
   3248  *                                                                                             *
   3249  *    This routine is used by the scenario editor to create and place buildings on the map.    *
   3250  *                                                                                             *
   3251  * INPUT:   cell     -- The cell that the building is to be placed upon.                       *
   3252  *                                                                                             *
   3253  *          house    -- The owner of the building.                                             *
   3254  *                                                                                             *
   3255  * OUTPUT:  bool; Was the building successfully created and placed on the map?                 *
   3256  *                                                                                             *
   3257  * WARNINGS:   none                                                                            *
   3258  *                                                                                             *
   3259  * HISTORY:                                                                                    *
   3260  *   05/28/1994 JLB : Created.                                                                 *
   3261  *=============================================================================================*/
   3262 bool BuildingTypeClass::Create_And_Place(CELL cell, HousesType house) const
   3263 {
   3264 	BuildingClass * ptr;
   3265 
   3266 	ptr = new BuildingClass(Type, house);
   3267 	if (ptr != NULL) {
   3268 		return(ptr->Unlimbo(Cell_Coord(cell), DIR_N));
   3269 	}
   3270 	return(false);
   3271 }
   3272 
   3273 
   3274 /***********************************************************************************************
   3275  * BuildingTypeClass::Create_One_Of -- Creates a building of this type.                        *
   3276  *                                                                                             *
   3277  *    This routine will create a building object of this type. The building object is in a     *
   3278  *    limbo state. It is presumed that the building object will be unlimboed at the correct    *
   3279  *    place and time. Typical use is when the building is created in a factory situation       *
   3280  *    and will be placed on the map when construction completes.                               *
   3281  *                                                                                             *
   3282  * INPUT:   house -- Pointer to the house that is to be the owner of the building.             *
   3283  *                                                                                             *
   3284  * OUTPUT:  Returns with a pointer to the building. If the building could not be created       *
   3285  *          then a NULL is returned.                                                           *
   3286  *                                                                                             *
   3287  * WARNINGS:   none                                                                            *
   3288  *                                                                                             *
   3289  * HISTORY:                                                                                    *
   3290  *   06/07/1994 JLB : Created.                                                                 *
   3291  *=============================================================================================*/
   3292 ObjectClass * BuildingTypeClass::Create_One_Of(HouseClass * house) const
   3293 {
   3294 	HousesType htype = HOUSE_NEUTRAL;
   3295 	if (house != NULL) {
   3296 		htype = house->Class->House;
   3297 	}
   3298 	return(new BuildingClass(Type, htype));
   3299 }
   3300 
   3301 
   3302 /***********************************************************************************************
   3303  * BuildingTypeClass::Init_Anim -- Initialize an animation control for a building.             *
   3304  *                                                                                             *
   3305  *    This routine will initialize one animation control element for a                         *
   3306  *    specified building. This modifies a "const" class and thus must                          *
   3307  *    perform some strategic casting to get away with this.                                    *
   3308  *                                                                                             *
   3309  * INPUT:   state -- The animation state to apply these data values to.                        *
   3310  *                                                                                             *
   3311  *          start -- Starting frame for the building's animation.                              *
   3312  *                                                                                             *
   3313  *          count -- The number of frames in this animation.                                   *
   3314  *                                                                                             *
   3315  *          rate  -- The countdown timer between animation frames.                             *
   3316  *                                                                                             *
   3317  * OUTPUT:  none                                                                               *
   3318  *                                                                                             *
   3319  * WARNINGS:   none                                                                            *
   3320  *                                                                                             *
   3321  * HISTORY:                                                                                    *
   3322  *   04/18/1994 JLB : Created.                                                                 *
   3323  *=============================================================================================*/
   3324 void BuildingTypeClass::Init_Anim(BStateType state, int start, int count, int rate) const
   3325 {
   3326 	((int &)Anims[state].Start) = start;
   3327 	((int &)Anims[state].Count) = count;
   3328 	((int &)Anims[state].Rate) = rate;
   3329 }
   3330 
   3331 
   3332 /***********************************************************************************************
   3333  * BuildingTypeClass::Init -- Performs theater specific initialization.                        *
   3334  *                                                                                             *
   3335  *    This routine is used to perform any initialization that is custom per theater.           *
   3336  *    Typically, this is fetching the building shape data for those building types that have   *
   3337  *    theater specific art.                                                                    *
   3338  *                                                                                             *
   3339  * INPUT:   theater  -- The theater to base this initialization on.                            *
   3340  *                                                                                             *
   3341  * OUTPUT:  none                                                                               *
   3342  *                                                                                             *
   3343  * WARNINGS:   none                                                                            *
   3344  *                                                                                             *
   3345  * HISTORY:                                                                                    *
   3346  *   01/21/1995 JLB : Created.                                                                 *
   3347  *=============================================================================================*/
   3348 void BuildingTypeClass::Init(TheaterType theater)
   3349 {
   3350 	if (theater != LastTheater) {
   3351 		char fullname[_MAX_FNAME+_MAX_EXT];
   3352 
   3353 		for (int sindex = STRUCT_FIRST; sindex < STRUCT_COUNT; sindex++) {
   3354 			BuildingTypeClass const * classptr = &As_Reference((StructType)sindex);
   3355 
   3356 			if (classptr->IsTheater) {
   3357 				_makepath(fullname, NULL, NULL, classptr->Graphic_Name(), Theaters[theater].Suffix);
   3358 				((void const *&)classptr->ImageData) = MFCD::Retrieve(fullname);
   3359 
   3360 				/*
   3361 				**	Buildup data is probably theater specific as well. Fetch a pointer to the
   3362 				**	data at this time as well.
   3363 				*/
   3364 				sprintf(fullname, "%sMAKE.%s", classptr->Graphic_Name(), Theaters[theater].Suffix);
   3365 				((void const *&)classptr->BuildupData) = MFCD::Retrieve(fullname);
   3366 				if (classptr->BuildupData) {
   3367 					int timedelay = 1;
   3368 					int count = Get_Build_Frame_Count(classptr->BuildupData);
   3369 					if (count != 0) {
   3370 						timedelay = (5 * TICKS_PER_SECOND) / count;
   3371 					}
   3372 					classptr->Init_Anim(BSTATE_CONSTRUCTION, 0, count, timedelay);
   3373 				}
   3374 			}
   3375 		}
   3376 	}
   3377 }
   3378 
   3379 
   3380 /***********************************************************************************************
   3381  * BuildingTypeClass::Dimensions -- Fetches the pixel dimensions of the building.              *
   3382  *                                                                                             *
   3383  *    This routine will fetch the dimensions of the building (in pixels). These dimensions are *
   3384  *    used to render the selection rectangle and the health bar.                               *
   3385  *                                                                                             *
   3386  * INPUT:   width    -- Reference to the pixel width (to be filled in).                        *
   3387  *                                                                                             *
   3388  *          height   -- Reference to the pixel height (to be filled in).                       *
   3389  *                                                                                             *
   3390  * OUTPUT:  none                                                                               *
   3391  *                                                                                             *
   3392  * WARNINGS:   none                                                                            *
   3393  *                                                                                             *
   3394  * HISTORY:                                                                                    *
   3395  *   01/23/1995 JLB : Created.                                                                 *
   3396  *=============================================================================================*/
   3397 void BuildingTypeClass::Dimensions(int &width, int &height) const
   3398 {
   3399 	width = Width() * ICON_PIXEL_W;
   3400 	width -= (width/5);
   3401 	height = Height() * ICON_PIXEL_H;
   3402 	height -= (height/5);
   3403 }
   3404 
   3405 
   3406 /***********************************************************************************************
   3407  * BuildingTypeClass::As_Reference -- Fetches reference to the building type specified.        *
   3408  *                                                                                             *
   3409  *    This routine will fetch a reference to the BuildingTypeClass as indicated by the         *
   3410  *    building type number specified.                                                          *
   3411  *                                                                                             *
   3412  * INPUT:   type  -- The building type number to convert into a BuildingTypeClass reference.   *
   3413  *                                                                                             *
   3414  * OUTPUT:  Returns with a reference to the building type class as indicated by the            *
   3415  *          parameter.                                                                         *
   3416  *                                                                                             *
   3417  * WARNINGS:   none                                                                            *
   3418  *                                                                                             *
   3419  * HISTORY:                                                                                    *
   3420  *   01/23/1995 JLB : Created.                                                                 *
   3421  *=============================================================================================*/
   3422 BuildingTypeClass & BuildingTypeClass::As_Reference(StructType type)
   3423 {
   3424 	return(*BuildingTypes.Ptr(type));
   3425 }
   3426 
   3427 
   3428 /***********************************************************************************************
   3429  * BuildingTypeClass::Occupy_List -- Fetches the occupy list for the building.                 *
   3430  *                                                                                             *
   3431  *    Use this routine to fetch the occupy list pointer for the building. The occupy list is   *
   3432  *    used to determine what cells the building occupies and thus precludes other buildings    *
   3433  *    or objects from using.                                                                   *
   3434  *                                                                                             *
   3435  * INPUT:   placement   -- Is this for placement legality checking only? The normal condition  *
   3436  *                         is for marking occupation flags.                                    *
   3437  *                                                                                             *
   3438  * OUTPUT:  Returns with a pointer to a cell offset list to be used to determine what cells    *
   3439  *          this building occupies.                                                            *
   3440  *                                                                                             *
   3441  * WARNINGS:   none                                                                            *
   3442  *                                                                                             *
   3443  * HISTORY:                                                                                    *
   3444  *   01/23/1995 JLB : Created.                                                                 *
   3445  *=============================================================================================*/
   3446 short const * BuildingTypeClass::Occupy_List(bool placement) const
   3447 {
   3448 	SmudgeType bib = SMUDGE_NONE;
   3449 	CELL cell=0;
   3450 
   3451 	if (placement && Bib_And_Offset(bib, cell)) {
   3452 
   3453 		SmudgeTypeClass const & smudge = SmudgeTypeClass::As_Reference(bib);
   3454 		static short _list[25];
   3455 		short * dest = &_list[0];
   3456 
   3457 		/*
   3458 		**	Copy the bib overlap list into the working buffer.
   3459 		*/
   3460 		short const * src = smudge.Occupy_List();
   3461 		while (*src != REFRESH_EOL) {
   3462 			*dest++ = (*src++) + cell;
   3463 		}
   3464 
   3465 		/*
   3466 		**	Append the building occupy list to this working buffer.
   3467 		*/
   3468 		src = OccupyList;
   3469 		while (src && *src != REFRESH_EOL) {
   3470 			*dest++ = *src++;
   3471 		}
   3472 		*dest = REFRESH_EOL;
   3473 
   3474 		return(&_list[0]);
   3475 	}
   3476 
   3477 	if (OccupyList != NULL) {
   3478 		return(OccupyList);
   3479 	}
   3480 
   3481 	static short const _templap[] = {REFRESH_EOL};
   3482 	return(&_templap[0]);
   3483 }
   3484 
   3485 
   3486 /***********************************************************************************************
   3487  * BuildingTypeClass::Overlap_List -- Fetches the overlap list for the building.               *
   3488  *                                                                                             *
   3489  *    This routine will fetch the overlap list for the building. The overlap list is used      *
   3490  *    to determine what cells the building's graphics cover, but is not considered to occupy   *
   3491  *    for movement purposes.                                                                   *
   3492  *                                                                                             *
   3493  * INPUT:   none                                                                               *
   3494  *                                                                                             *
   3495  * OUTPUT:  Returns with a pointer to the cell offset list that is used to determine the       *
   3496  *          cells that this building overlaps.                                                 *
   3497  *                                                                                             *
   3498  * WARNINGS:   none                                                                            *
   3499  *                                                                                             *
   3500  * HISTORY:                                                                                    *
   3501  *   01/23/1995 JLB : Created.                                                                 *
   3502  *=============================================================================================*/
   3503 short const * BuildingTypeClass::Overlap_List(void) const
   3504 {
   3505 	if (OverlapList != NULL) {
   3506 		return(OverlapList);
   3507 	}
   3508 
   3509 	static short const _templap[] = {REFRESH_EOL};
   3510 	return(&_templap[0]);
   3511 }
   3512 
   3513 
   3514 /***********************************************************************************************
   3515  * BuildingTypeClass::Width -- Determines width of building in icons.                          *
   3516  *                                                                                             *
   3517  *    Use this routine to determine the width of the building type in icons.                   *
   3518  *                                                                                             *
   3519  * INPUT:   none                                                                               *
   3520  *                                                                                             *
   3521  * OUTPUT:  Returns with the building width in icons.                                          *
   3522  *                                                                                             *
   3523  * WARNINGS:   none                                                                            *
   3524  *                                                                                             *
   3525  * HISTORY:                                                                                    *
   3526  *   02/23/1995 JLB : Created.                                                                 *
   3527  *=============================================================================================*/
   3528 int BuildingTypeClass::Width(void) const
   3529 {
   3530 	static int width[BSIZE_COUNT] = {
   3531 		1,
   3532 		2,
   3533 		1,
   3534 		2,
   3535 		2,
   3536 		3,
   3537 		3,
   3538 		4,
   3539 		5
   3540 	};
   3541 	return(width[Size]);
   3542 }
   3543 
   3544 
   3545 /***********************************************************************************************
   3546  * BuildingTypeClass::Height -- Determines the height of the building in icons.                *
   3547  *                                                                                             *
   3548  *    Use this routine to find the height of the building in icons.                            *
   3549  *                                                                                             *
   3550  * INPUT:   none                                                                               *
   3551  *                                                                                             *
   3552  * OUTPUT:  Returns with the building height in icons.                                         *
   3553  *                                                                                             *
   3554  * WARNINGS:   none                                                                            *
   3555  *                                                                                             *
   3556  * HISTORY:                                                                                    *
   3557  *   02/23/1995 JLB : Created.                                                                 *
   3558  *=============================================================================================*/
   3559 int BuildingTypeClass::Height(bool bib) const
   3560 {
   3561 	static int height[BSIZE_COUNT] = {
   3562 		1,
   3563 		1,
   3564 		2,
   3565 		2,
   3566 		3,
   3567 		2,
   3568 		3,
   3569 		2,
   3570 		5
   3571 	};
   3572 	return(height[Size] + ((bib && IsBibbed) ? 1 : 0));
   3573 }
   3574 
   3575 
   3576 /***********************************************************************************************
   3577  * BuildingTypeClass::Bib_And_Offset -- Determines the bib and appropriate cell offset.        *
   3578  *                                                                                             *
   3579  *    This routine is used to determine what (if any) bib should be used for this building     *
   3580  *    and also the cell offset for the upper left corner of the bib smudge type.               *
   3581  *                                                                                             *
   3582  * INPUT:   bib   -- Reference to the bib that should be used for this building.               *
   3583  *                                                                                             *
   3584  *          cell  -- The cell offset for the upper left corner of the bib. This offset is      *
   3585  *                   relative to the upper left corner of the building.                        *
   3586  *                                                                                             *
   3587  * OUTPUT:  Is a bib required for this building? If the result is true, then the correct       *
   3588  *          bib and cell offset will be filled in.                                             *
   3589  *                                                                                             *
   3590  * WARNINGS:   none                                                                            *
   3591  *                                                                                             *
   3592  * HISTORY:                                                                                    *
   3593  *   05/23/1995 JLB : Created.                                                                 *
   3594  *=============================================================================================*/
   3595 bool BuildingTypeClass::Bib_And_Offset(SmudgeType & bib, CELL & cell) const
   3596 {
   3597 	bib = SMUDGE_NONE;
   3598 
   3599 	if (IsBibbed) {
   3600 		switch (Width()) {
   3601 			case 2:
   3602 				bib = SMUDGE_BIB3;
   3603 				break;
   3604 
   3605 			case 3:
   3606 				bib = SMUDGE_BIB2;
   3607 				break;
   3608 
   3609 			case 4:
   3610 				bib = SMUDGE_BIB1;
   3611 				break;
   3612 
   3613 			default:
   3614 				bib = SMUDGE_NONE;
   3615 				break;
   3616 		}
   3617 
   3618 		/*
   3619 		**	Adjust the bib position for special buildings that have the bib as part
   3620 		**	of the building art itself.
   3621 		*/
   3622 		if (bib != SMUDGE_NONE) {
   3623 			cell += ((Height()-1)*MAP_CELL_W);
   3624 		}
   3625 	}
   3626 	return(bib != SMUDGE_NONE);
   3627 }
   3628 
   3629 
   3630 /***********************************************************************************************
   3631  * BuildingTypeClass::Max_Pips -- Determines the maximum pips to display.                      *
   3632  *                                                                                             *
   3633  *    Use this routine to determine the maximum number of pips to display on this building     *
   3634  *    when it is rendered. Typically, this is the tiberium capacity divided by 100.            *
   3635  *                                                                                             *
   3636  * INPUT:   none                                                                               *
   3637  *                                                                                             *
   3638  * OUTPUT:  Returns with the number of pips to display on this building when selected.         *
   3639  *                                                                                             *
   3640  * WARNINGS:   none                                                                            *
   3641  *                                                                                             *
   3642  * HISTORY:                                                                                    *
   3643  *   06/29/1995 JLB : Created.                                                                 *
   3644  *=============================================================================================*/
   3645 int BuildingTypeClass::Max_Pips(void) const
   3646 {
   3647 	int maxpips = (Width() * ICON_PIXEL_W) / 4;
   3648 	return(Bound((int)(Capacity/100), 0, maxpips));
   3649 }
   3650 
   3651 
   3652 /***********************************************************************************************
   3653  * BuildingTypeClass::Raw_Cost -- Fetches the raw (base) cost of this building type.           *
   3654  *                                                                                             *
   3655  *    This routine is used to fetch the real raw base cost of the building. The raw cost       *
   3656  *    is the cost of the building less any free unit that would come with the building         *
   3657  *    if it were built in the normal fashion. Specifically, the helicopter cost is subtracted  *
   3658  *    from the helipad and the harvester cost is subtracted from the refinery. This cost       *
   3659  *    is used for refunding.                                                                   *
   3660  *                                                                                             *
   3661  * INPUT:   none                                                                               *
   3662  *                                                                                             *
   3663  * OUTPUT:  Returns the raw (base) cost to build the building of this type.                    *
   3664  *                                                                                             *
   3665  * WARNINGS:   none                                                                            *
   3666  *                                                                                             *
   3667  * HISTORY:                                                                                    *
   3668  *   09/21/1995 JLB : Created.                                                                 *
   3669  *=============================================================================================*/
   3670 int BuildingTypeClass::Raw_Cost(void) const
   3671 {
   3672 	int cost = TechnoTypeClass::Raw_Cost();
   3673 
   3674 	if (Type == STRUCT_HELIPAD && !Rule.IsSeparate) {
   3675 		cost -= (AircraftTypeClass::As_Reference(AIRCRAFT_HIND).Cost + AircraftTypeClass::As_Reference(AIRCRAFT_HIND).Cost)/2;
   3676 	}
   3677 	if (Type == STRUCT_REFINERY) {
   3678 		cost -= UnitTypeClass::As_Reference(UNIT_HARVESTER).Cost;
   3679 	}
   3680 	return(cost);
   3681 }
   3682 
   3683 
   3684 /***********************************************************************************************
   3685  * BuildingTypeClass::Cost_Of -- Fetches the cost of this building.                            *
   3686  *                                                                                             *
   3687  *    This routine will fetch the cost to build the building of this type.                     *
   3688  *                                                                                             *
   3689  * INPUT:   none                                                                               *
   3690  *                                                                                             *
   3691  * OUTPUT:  Returns with the cost to produce this building.                                    *
   3692  *                                                                                             *
   3693  * WARNINGS:   none                                                                            *
   3694  *                                                                                             *
   3695  * HISTORY:                                                                                    *
   3696  *   09/21/1995 JLB : Created.                                                                 *
   3697  *=============================================================================================*/
   3698 int BuildingTypeClass::Cost_Of(void) const
   3699 {
   3700 	if (Rule.IsSeparate && Type == STRUCT_HELIPAD) {
   3701 		return(Raw_Cost());
   3702 	}
   3703 	return(TechnoTypeClass::Cost_Of());
   3704 }
   3705 
   3706 
   3707 /***********************************************************************************************
   3708  * BuildingTypeClass::Flush_For_Placement -- Tries to clear placement area for this building t *
   3709  *                                                                                             *
   3710  *    This routine is called when a clear space for placement is desired at the cell location  *
   3711  *    specified. Typical use of this routine is by the computer when it wants to build up      *
   3712  *    its base.                                                                                *
   3713  *                                                                                             *
   3714  * INPUT:   cell  -- The cell that the building of this type would like to be placed down at.  *
   3715  *                                                                                             *
   3716  *          house -- Pointer to the house that want to clear the foundation zone.              *
   3717  *                                                                                             *
   3718  * OUTPUT:  Placement is temporarily blocked, please try again later?                          *
   3719  *                                                                                             *
   3720  * WARNINGS:   none                                                                            *
   3721  *                                                                                             *
   3722  * HISTORY:                                                                                    *
   3723  *   09/27/1995 JLB : Created.                                                                 *
   3724  *=============================================================================================*/
   3725 bool BuildingTypeClass::Flush_For_Placement(CELL cell, HouseClass * house)  const
   3726 {
   3727 	bool again = false;
   3728 	if (cell > 0) {
   3729 		short const * list = Occupy_List(true);
   3730 
   3731 		while (*list != REFRESH_EOL) {
   3732 			CELL newcell = cell + *list++;
   3733 
   3734 			if (Map.In_Radar(newcell)) {
   3735 				TechnoClass * occupier = Map[newcell].Cell_Techno();
   3736 				if (occupier != NULL) {
   3737 					again = true;
   3738 					if (occupier->House->Is_Ally(house) && occupier->Is_Foot() && !Target_Legal(((FootClass *)occupier)->NavCom)) {
   3739 						Map[newcell].Incoming(0, true);
   3740 					} else {
   3741 //						Base_Is_Attacked(occupier);
   3742 					}
   3743 				}
   3744 			}
   3745 		}
   3746 	}
   3747 	return(again);
   3748 }
   3749 
   3750 
   3751 /***********************************************************************************************
   3752  * BuildingTypeClass::Read_INI -- Fetch building type data from the INI database.              *
   3753  *                                                                                             *
   3754  *    This routine will fetch the building type class data from the INI database file.         *
   3755  *                                                                                             *
   3756  * INPUT:   ini   -- Reference to the INI database that will be examined.                      *
   3757  *                                                                                             *
   3758  * OUTPUT:  bool; Was the building entry found and the data extracted?                         *
   3759  *                                                                                             *
   3760  * WARNINGS:   none                                                                            *
   3761  *                                                                                             *
   3762  * HISTORY:                                                                                    *
   3763  *   07/19/1996 JLB : Created.                                                                 *
   3764  *=============================================================================================*/
   3765 bool BuildingTypeClass::Read_INI(CCINIClass & ini)
   3766 {
   3767 	if (TechnoTypeClass::Read_INI(ini)) {
   3768 		Speed = ini.Get_Bool(Name(), "WaterBound", (Speed == SPEED_FLOAT)) ? SPEED_FLOAT : SPEED_NONE;
   3769 		Capacity = ini.Get_Int(Name(), "Storage", Capacity);
   3770 		Adjacent = ini.Get_Int(Name(), "Adjacent", Adjacent);
   3771 		IsCaptureable = ini.Get_Bool(Name(), "Capturable", IsCaptureable);
   3772 		IsPowered = ini.Get_Bool(Name(), "Powered", IsPowered);
   3773 		IsBibbed = ini.Get_Bool(Name(), "Bib", IsBibbed);
   3774 		IsUnsellable = ini.Get_Bool(Name(), "Unsellable", IsUnsellable);
   3775 		IsBase = ini.Get_Bool(Name(), "BaseNormal", IsBase);
   3776 		Power = ini.Get_Int(Name(), "Power", (Power > 0) ? Power : -Drain);
   3777 		if (Power < 0) {
   3778 			Drain = -Power;
   3779 			Power = 0;
   3780 		}
   3781 		return(true);
   3782 	}
   3783 	return(false);
   3784 }
   3785 
   3786 
   3787 /***********************************************************************************************
   3788  * BuildingTypeClass::Coord_Fixup -- Adjusts coordinate to be legal for assignment.            *
   3789  *                                                                                             *
   3790  *    This routine will adjust the specified coordinate so that it will be legal for assignment*
   3791  *    to this building. All buildings are given a coordinate that is in the upper left corner  *
   3792  *    of a cell. This routine will drop the fractional component of the coordinate.            *
   3793  *                                                                                             *
   3794  * INPUT:   coord -- The coordinate to fixup into a legal to assign value.                     *
   3795  *                                                                                             *
   3796  * OUTPUT:  Returns with a coordinate that can be assigned to the building.                    *
   3797  *                                                                                             *
   3798  * WARNINGS:   The coordinate is not examined to see if the cell is legal for placing the      *
   3799  *             building. It merely adjusts the coordinate so that is legal at first glance.    *
   3800  *                                                                                             *
   3801  * HISTORY:                                                                                    *
   3802  *   08/14/1996 JLB : Created.                                                                 *
   3803  *=============================================================================================*/
   3804 COORDINATE BuildingTypeClass::Coord_Fixup(COORDINATE coord) const
   3805 {
   3806 	return Coord_Whole(coord);
   3807 }
   3808 
   3809 
   3810 /***********************************************************************************************
   3811  * BuildingTypeClass::Full_Name -- Fetches the name to give this building.                     *
   3812  *                                                                                             *
   3813  *    This routine will return the displayable given name for this building type. Normally,    *
   3814  *    this is the official name as well, however in the case of civilian buildings, the        *
   3815  *    name will just be "Civilian Building" unless special options are in place.               *
   3816  *                                                                                             *
   3817  * INPUT:   none                                                                               *
   3818  *                                                                                             *
   3819  * OUTPUT:  Returns with the text number of the building type.                                 *
   3820  *                                                                                             *
   3821  * WARNINGS:   none                                                                            *
   3822  *                                                                                             *
   3823  * HISTORY:                                                                                    *
   3824  *   10/02/1996 JLB : Created.                                                                 *
   3825  *=============================================================================================*/
   3826 int BuildingTypeClass::Full_Name(void) const
   3827 {
   3828 	if (Debug_Map || Rule.IsNamed || *this < STRUCT_V01 || *this > STRUCT_V37) {
   3829 		return(TechnoTypeClass::Full_Name());
   3830 	}
   3831 	return(TXT_CIVILIAN_BUILDING);
   3832 }