MM Tutorial Home

CSO Main Site

Texture Downloads

CSO Map Making Forum


TUTORIAL LIST

BTD FAQ

CC2 FAQ

Dirt Roads

Naked Foot MM Tutorial

Southern_Land's MM tutorial

 



The (in)Complete CC2 MAP FAQ

by: Naked Foot with footnote by Mick

(Taken from a txt file)

TOOLS - Tin Tin's Map Maker (MM) @ http://members.xoom.com/CloseCombat/MapMaker.zip
Tin Tin's Texture Maker (TM) @ http://cc2.gamestats.com/files/texture_maker.zip
See also his site for additional info on using these primo tools @ http://members.xoom.com/CloseCombat
Vince Viaud's LOS Maker (http://members.xoom.com/CloseCombat/cc2los.zip)
Hex Editor- (UltraEdit @ http://www.ultraedit.com or HexEdit32 (aka HexWorks) @ http://www.bpsoft.com )
Graphics Editor- (Photoshop, PaintShopPro (http://www.jasc.com) or similar app capable of saving images as 16 bit uncompressed .tga files)
Included in this zip is a JPG (Corners.jpg) illustrating how corner coordinates are identified.

CREATING NEW GRAPHICS (building the bgmap file, the primary file in a new map set) The base graphics for a new map are limited only by your imagination. They can be scanned from a variety of sources; cut and pasted or cloned from existing CC1, CC2 or CC3 maps (think screenshots on the first and last here); or just drawn from scratch if ya got the digitally artistic talent. Save your new graphics as a 16 bit uncompressed .TGA file.

USING TEXTURE MAKER - To c&p, clone or otherwise graphically edit the original CC2 maps youll first have to use TM to convert them from CC2 format to .TGA (Targa) format. As Adam D'arcy, aka THE MAN, discovered, the CC2 maps are basically 16 bit uncompressed .TGA files with the byte order reversed and a different 16 byte CC2 header at the beginning of the image data in the file. To use TM - extract the TM files from the zip into a folder. Copy a bgmap### file from your game directory (ABTF/Graphics/Maps) into the TM folder. Rename the bgmap### file as txtr000 (v.2 of TM, available from Tin's web site, doesnt require renaming. My instructions thruout will assume the use of TM v.1). Double click the totga.bat file in the TM folder. A DOS window will open and TM will start to do its thing. Takes a bit for it to digest the 4-5 meg bgmap files. After it does you get a list of error mssgs (txtr001 not found etc) Not to worry. TM was designed to convert the 170+ vehicle textures and its just looking for those other txtr files. Close the DOS window and youll see the file txtr000.tga has been output to your TM folder. Rename it as bgmap###.tga and its ready to view, edit or otherwise manipulate.

FYI- to reverse the process and convert a .tga file to CC2 format just put your .tga in the TM folder, rename as txtr000.tga, double click the fromtga.bat file, wait for the error mssgs, close the window (you can close the window before ya get all 170+ error mssgs) & rename the txtr000 file that is output.

MAP DIMENSIONS - Each deployment tile (the 'squares' you designate with red or blue dots in the Battle Maker (BM) edit screen) is 120 pixels square. Maps must have complete deployment tiles and Tin's Map Maker app will only compile full deploy tiles into a map### file. When you create a new document in your graphics editor, the dimensions of a new map MUST be in multiples of 120 pixels (eg 1680x1200 or 14x10 deployment tiles, the 'standard' CC2 map size). As you approach a 20x20 (2400x2400) size youll begin to see problems running the maps in the game especially on 32 meg RAM machines. DirectX 6 is supposed to obviate this for the 4x larger maps CC3 will use. The following is a list of CC2map #s and sizes (given in HXW deployment tiles. Multiply by 120 for pixel size)-

map#/name/size/(battle # if different than map #)
100-Arnhem RR Br 14x10
101-Arnhem Suburbs 14x10
102-Arnhem Tree Rd 15x9
103-Arnhem W Approach 14x10
104-Arnhem Bridge 12x12
100-Oosterbeek RR Br 14x10 (Battle 110)
112-Oosterbeek Cauldron 15x9 (Battle 111)
111-Oosterbeek North 15x9 (Battle 112)
110-Oosterbeek LZ 12x12 (battle 113)
101-Relief Suburbs 14x10 (Battle 120)
102-Relief Tree Rd 15x9 (Battle 121)
103-Relief W Approach 14x10 (Battle 122)
130-Polish Drop LZ 14x10
131-Polish Drop Driel 14x10
132-Polish Drop Farmland 14x10
202-Groesbeek Heights 16x9 (Battle200)
201-Groesbeek Farmland 16x9 (Battle 201)
200-Groesbeek LZ 14x10 (Battle 202)
210-Nijmegen City 14x10
211-Nijmegen Bridge 10x14
220-Nijmegen River Crossing 14x9
221-Nijmegen Riverfront 14x10
222-Nijmegen North Br 14x10
230-The Tulip Fields 14x10
231-The Island 14x10
300-Veghel Bridge 14x10
301-Veghel Town 16x9
302-Veghel North 14x10
310-Son Town 15x10
311-Son Bridge 13x11
312-Son South 16x9
320-Schijnndel Rd 14x10
321-Schijndel Dunes 14x10

BACKGROUND ON BGMAP### and MAP### files - the map image (bgmap### file) you see onscreen during the game is just a picture. The game cannot interpret what is obviously grass, bldgs, roads etc, as such, without the data in the map### file. Map### (ABTF/Data/Maps folder) is an Excel file that divides the map into 10x10 pixel terrain 'elements' (Open the ABTF/Data/Base/Elements file to see how terrain elements are defined for game purposes. Every type of terrain is assigned a # which is used in the map### file to specify the 10x10 elements) Map### further specifies an elevation for every 4x4 block of elements (40x40 pixels). If you open map### in Excel (or similar spreadsheet app including that in Works) the array of element #s youll see will not correspond from upper left to lower right with the map graphic. Map### has been resorted for CC2 format. To open map### in a WYSIWYG format use Tin's Map Maker tool.

USING MAP MAKER - Extract the Map Maker file from the zip to a folder (I think MM v.1 uses a series of nested folders that ya may want to get rid of. You can place the MapMaker.exe file anywhere ya want) The first time you use MM youll have to tell it where to look for the map### files. In the window that opens only select the ABTF folder, not the ABTF/data folder as you may be led to believe. You can specify either the ABTF folder on your cd drive or the HD. I recomend using the HD location (usually C:/Program Files/Microsoft Games/A Bridge Too Far).

To view existing maps and data - under the File menu select Open, then browse to the ABTF/Data/Maps folder and select a map### file (not the map###.los file).

To Create a New Map### file for your new graphics - under the File menu select New. Specify the pixel size of your graphics. Under the File menu then select Import then select graphics. Browse to the location of your new map graphics and select the .TGA . MapMaker will only import .TGAs when creating a new map### file. As for the actual work of coding the map### I'll leave that for you to figure out. MapMaker is fairly straightforward app to use. The original method Adam used to make the first new CC2 map required much tedious work in Excel and then a convoluted resort of that data to CC2 format. MapMaker simplifies all this, in a WYSIWYG package, that shouldnt pose any difficulties for anybody bright enough to have gotten this far in the process.

A note about trees in map### files- you only have to code a single tree element in MM, over the 'trunk', to force an imposition of a treetop graphic over that trunk in the game. The game 'patches' that treetop image onto the map from the ABTF/Graphics/terrain file much the way roofs are handled. Dont forget to code leave and leave/bush elements around the tree(trunk), otherwise youll wind up with the equivilent of a bare tree with no foliage to inhibit LOS. View a std map### file in MM to see how it is normally handled in CC2. Also Atomic goofed when coding trees in the ABTF/Data/elements file. Column Q (Block All) should have the value '0' not '1' for all 5 tree types. Change this and play the game the way it was meant to be played.

When finished coding your new map### file youll have to decide which map# slot to use. Ugur figured out a method for adding new maps without replacing originals but for simplicities sake Im going to assume you choose to replace map 100 (the Arnhem RR Bridge map we love so well). Name your map### file as map100 and replace the original map100 in the ABTF/Data/Maps folder (Fear not. The original files can easily be copied back from the cd without having to go thru a full reinstall of the game)
Convert your .TGA to CC2 format as outlined above and name it as bgmap100. Copy it to the ABTF/Graphics/Maps folder and overwrite the original.

LOS MAKER - to create a usable LOS (Line of Sight) file for your new map, download Vincent Viaud's LOS Maker and extract it to the ABTF folder. Double click the .exe file. In the window that opens type in 100 (or whatever map# you assigned to the new map### file youve placed in the ABTF/Data/Maps folder) where it asks for map#. Enter this and the program will then analyze the new map### file and output a new map100.los file, automatically replacing the original in the ABTF/Data/Maps folder.

ROOF FILES - CC2 uses a separate set of graphics, found in the ABTF/Graphics/Maps/roof### file (a collection of all the roof and interior images for that map) to 'patch' or superimpose roof and interior images onto the map. The building roof you see on the bgmap graphic gets an interior image from the roof### file patched over it whenever one of your teams enters the building. When your team exits the building the interior patch is removed but rather than default back to the bgmap image, a roof image patch is then used. The roof image patch is a copy of the exterior view of that building from the bgmap graphic, and is cropped to show only that building with as little exterior 'landscape' as possible.

EXTRACTING ROOF AND INTERIOR IMAGES FROM ROOF###
(The following isnt absolutely necessary for creating a new roof### file but if you havent used a hex editor before I suggest running thru all the steps at least once to get the hang of it. The next section, Down and Dirty Roof### File Building, is a much quicker method of doing this if youre not married to the idea of using the original CC2 interior images.)

1.


a. Open the roof312 file (ABTF/Graphics/Maps folder) in HexEdit (Note HexEdit cannot copy data more than 32kb in size so you may want to use a similar app, UltraEdit for handling building image data larger than this. However HexEdits Hex to Decimal conversion utility, Bconv32, and its hex calculator, Calc32, are invaluable for some of the tasks you must accomplish. Both can be used as stand-alone apps with UltraEdit)
b. The first line in a roofxxx file is the 16 byte CC2 header. Using roof312 (Son South) which has only 2 buildings as an example, you will see the first 3 lines of the file in HexEdit as -
52 4F 4F 46 00 00 00 02 00 00 00 00 00 00 00 00
00 94 00 D8 01 C0 01 FC 00 00 00 00 00 00 1F EO
06 14 06 64 01 6C 01 B4 00 00 3F C0 00 00 6C C0
c. The 8th byte in the first line (02, which in this case is also equal to the decimal value '2') is the hex value for the number of bldgs on the map. The second and third lines are 16 byte headers, one for each of the bldgs on the map. Every building gets a 16 byte header. If youre not sure how many bldg headers there are in a roof file you can always count them on the map and count down from the beginning of the file the same number of lines + one to include the CC2 header at the start of the file)

2. The second 16 byte line (the header for the first roof pair in the roof312 file (roof and interior images taken together were named by Piotr Lewandoski as roof pairs) is translated as follows :

a. 1st, 2nd bytes: The x1 coordinate of the upper left corner of the building on the map - 00 94 in hex = 148 in decimal
b. 3rd, 4th bytes: The x2 coordinate of the lower right corner of the building on the map - 00 D8 = 216
c. 5th, 6th bytes: The y1 coordinate of the upper left corner of the building on the map - 01 C0 = 448
d. 7th, 8th bytes: The y2 coordinate of the lower right corner of the building on the map - 01 FC = 508
e. Thus the pixel coordinates for the upper left and lower right corners of both images in the roof pair are 148,448 and 216,508, the x values representing the the horizontal axis and the y values the vertical axis. These values correspond to the pixel coordinates of both the roof and interior image corners where they would be found on the bgmap file when it is viewed as a tga in Photoshop or PaintShopPro. Use the ruler and set its measurement to pixels to determine this.
f. The next two 4 byte pairs are the offsets (offset addresses are found in the left hand column in HexEdit and UlttaEdit) of the start of the roof image and start of the interior image. These offsets give you the image addresses !!!AFTER the headers have been cut!!! (see step 3 below) NOT with the CC2 and roof headers still at the beginning of the file. An offset address is merely a numerical ID system in hex to locate any particular 16 byte line or particular byte within that 16 byte line. Use the 'Go To Address' function described in 4b. below to get an idea of how the offset addressing system works.

3.


a. Select the 3 headers in roof312 (1 CC2 header and 2 roof headers) and cut them (CTRL-X).
b. Create a new document and paste (CTRL+V) the cut headers into the new doc.
c. Cutting the headers has exposed the start of the roof image data for the first roof pair, ie the first byte of the data you now see in line 1 (offset address 00 00 00 00) is the first byte of the image.

4.


a. The next offset (00 00 1F E0) is the start the data to the interior image for the first roof pair. The roof image data for this pair lies entirely between these two offsets. The interior image data lies between the second offset in the first header and the first offset in the second header.
b. Use the 'Go to Address' function in the Search menu and input the offset address of the start of the interior image (00 00 1F E0). Then use 'Go to' to input the first images offset address (00 00 00 00) and hold the shift key down while you click OK. You will have then selected (highlighted) all the data for the roof image in the pair.
c. Copy this data (CTRL+C), create a new document and paste (CTRL+V) the copied data into it.

 

5.

a. Now do some calculations using the HexEdit's hex calculator. Subtract the smaller x coordinate (x1 from step 2b. above) from the larger (x2 from step 2c.)
[eg x2 (00 D8) - x1 (00 94) = 00 44; the decimal equivalent is 216-148=68, 68 being equal to 00 44 in hex]. This is the pixel width of the image, the x values again representing the horizontal axis.
b. Then subtract the smaller y coordinate (y1 from step 2d.) from the larger (y2 from step 2e.)
[eg y2 (01 FC) - y1 (01 C0) = 00 3C; the decimal equivalent is 508-448=60, 60 being equal to 00 3C in hex] This is the pixel height of the image, the y values again representing the vertical axis.
c. Use the insert function in HexEdits edit menu to insert the following 16 byte header at the beginning of your roof image file from step 4b. -
74 78 84 66 00 01 00 00 00 00 00 44 00 00 00 3C
In all cases you where you create a header for these extracted roof or interior image files. You will want to use the same 16 byte values above EXCEPT for the width and height values you've calculated and used in bytes 11 & 12, and 15 & 16. These will likely be different in most cases though the roof and interior images in the same roof pair will share the same header values.
d. Save this file as txtr000 to the folder where Tin's Texture Maker is located. Run the totga.bat file there and Texture Maker will convert the txtr000 file (your roof image) to txtr000.tga. (Note: I wrote this before Tin updated his Texture Maker and I haven't used his TM v.2 yet. I see the whole structure of the app has changed. You're on your own for the time being as far as accomplishing this step in Texture Maker)

6. Continue to extract images from the roof file by using the Go To function and selecting the data between the next offsets, 1F E0, the start of the image data for the interior of first roof pair and 3F C0, the start of the image data for the roof of the second roof pair; pasting it in a new doc. Do your x and y calculations (interior image files in the same roof pair will use the identical new header as the roof image did in step 5c. above so you can copy and paste that header from the finished roof image file).

DOWN AND DIRTY ROOF### FILE 'BUILDING'

1. In your graphics editor, copy a roof from any bgmap.tga, cropping it as closely as possible, leaving as little exterior 'landscape' around the roof as you can. 'Square' bldgs (those not angled in respect to the map edges) are best for this. Paste the roof onto your new map where you want it.

2. Do any necessary graphics work to the exterior landscape surrounding the pasted roof image NOW (all roof and interior images sliced out of a roof file will have landscape matching the map they came from, bordering the bldg in the image) When pasting bldgs into a map youll find it necessary to 'blend' the pasted image in with the landscape surrounding its new position. Remember - any graphic changes done within the boundary of the roof image you copy in the step below, after you copy this roof image, will not displayed when the game 'patches' in the roof and interior images during play.

3. Copy the roof image from its new location including as little landscape as possible. !!!NOTE THE TWO CORNER COORDINATES!!! using the ruler set to measure in pixels. The marquee box the selection tool places around the section of the graphic to be copied makes determining the corners fairly easy. Make a copy of this copy (giving you two identical images, one you name roofx.tga and the other, interiorx.tga) To make the interior, 'hollow out' the roof (basically paint in a suitably colored floor or paste in a nice texture) and add something resembling walls (I find 2 pixel wide lines work well for these even tho the terrain elements in map### are all 10 pix wide) and white rectangles in the walls to represent doors and windows. Stay within the boundaries of the roof portion of the image itself when you do this.

4. Then use Texture Maker to convert the roof and interior .tga images (naming them txtr000.tga and txtr001.tga) and using the fromtga.bat file to create txtr000 and txtr 001 (again please note this step in Texture Maker refers to v.1 of that fine tool)

5. In HexEdit delete the 16 byte header from the converted file for the roof image you want to use and paste the remaining data into a new document. !!!NOTE!!! the offset address of the last line in this data (add blank bytes -'20' values to fill in any missing bytes to create a full 16 byte last line) The offset for the interior is going to be the next line. !!!IMPORTANT!!! to keep track of this as you'll need to input this offset value in the header you will create for this roofpair (the offset address for the roof image data in the first roofpair ia always 00 00 00 00).

6. Then delete the 16 byte header from the converted file for the interior image and paste the remaining data into the new document on the line following the roof image data.

7. To create the header for this roof pair its hex calculator time again. If you had noted the pixel coordinates of the roof image when you pasted it onto your new map as 700 (x1), 840 (y1) for the upper left and 780 (x2), 900 (y2) for the lower right - these decimal values would translate (using HexEdits base conversion tool, Bconv32.exe or a character table) as:
700 (= 02 BC in hex) for x1.
780 (= 03 0C in hex) for x2.
840 (= 03 48 in hex) for y1.
900 (= 03 84 in hex) for y2.

8. The first 8 bytes (specifying the roof images corner coordinates on your map) of the new header are going to be:
02 BC 03 0C 03 48 03 84

9. The next 4 bytes (the offset for the roof image data) will be 00 00 00 00 so the new header is now:
02 BC 03 0C 03 48 03 84 00 00 00 00

10. The last 4 bytes are the offset you'd noted for the beginning of the interior image data. Lets assume this as:
00 00 1D C0 The finished bldg header is now: 02 BC 03 0C 03 48 03 84 00 00 00 00 00 00 1D C0

11. Insert this at the beginning of your new roof pair data in line 1. Then insert a CC2 header (52 4F 4F 46 00 00 00 01 00 00 00 00 00 00 00 00) at the beginning of your new roof pair data in line 1 (which pushes the building header down to line 2). Save as roofxxx in the ABTF/Graphics/Maps folder and play.

Be creative folks. I did a camouflaged pillbox using a haystack graphic for the roof and a custom interior for the bunker. And a camo trench with a hedge for a roof and the trench as the interior. Let only your imagination limit you.

OVMAP AND MMMAP FILES

Ovmap (overview map) and mmmap (map monitor map) are two maps which CC2 uses for displays in the interface (the mmmap seen on the Command screen and on the Map Monitor during the game) and the BattleMaker edit screen. The pixel dimensions of the ovmap and mmmap are important. You cannot use the original ovmap### and mmmap### headers if your new files are different in size (pixel H x pixel W x 2). The data in the middle of the header is byte width x byte height (last data set in the header) x 2. You will need a hex calculator to determine this.

Mmmap example

1) You resize a copy of your new bgmap tga to 144x106 in preparation to make an mmmap file. (144x106 is not a fixed number but keep in mind the Map Monitor window, into which the graphic must fit, is only slightly bigger than that, especially in the horizontal.)

2) You then run the 144x106 .TGA thru Tin's Texture maker and convert it to CC2 format.

3) Rename the txtr000 file it creates as mmmap### (### being the # of the original map you want to substitute your new one for)

4) Open this file in a hex editor and the header appears as-
74 78 74 66 00 01 00 00 00 00 00 90 00 00 00 6A
Change the first 6 bytes to read as 00 00 00 00 00 00.

5) Now use a hex calculator (or hex to decimal conversion table) to multiply the values in bytes 12 and 16 (In this case, 90 x 6A in hex or 144 x 106 in decimal. Different dimensions will naturally produce different values in bytes 12 & 16) times 2. The result, 77 40 in hex (30528 in decimal) is placed in bytes 7 and 8.

6) The finished mmmap header will read -
00 00 00 00 00 00 77 40 00 00 00 90 00 00 00 6A

7) Save in the ABTF/Graphics/Maps folder.

Ovmap example

CC2 uses 904x646 as the ovmap image size for 1600x1200 maps. I've found there's a bit of leeway here if bgmap size is different (646 pixels may be a vertical limit though and 1142 pixels is the largest std horizontal size). This example assumes the reduction of a bgmap###.TGA from 1800x1320 (16x11 in deployment tiles) to an 881x646 .TGA in preparation to make an ovmap file. Keep in mind the values in bytes 11&12 and 15&16 of the header will vary depending on the actual dimensions of the reduction you choose to work with.

1) Use Tin's Texture Maker to convert your 881x646 ovmap###.TGA to CC2 format. The header in your hex editor will read - 74 78 74 66 00 01 00 00 00 00 03 71 00 00 02 86

2) The first 5 bytes are changed to 00.

3) Bytes 11 & 12 (03 71 or 881 in decimal) are multiplied by bytes 15 & 16 (02 86 or 646 in decimal) then the result is multiplied by 2.

4) The final product (11 5E 4C or 1138252 in decimal) is plugged into bytes 6, 7 & 8 producing a finished header that reads - 00 00 00 00 00 11 5E 4C 00 00 03 71 00 00 02 86

5) Save in the ABTF/Graphics/Maps folder

MAKING A FREE DEPLOY BATTLEMAKER TEMPLATE FOR A NEW MAP

Open your new map in the BM edit screen and remove all victory locatins and all but the mandatory 3-5 deployment tiles on the left and right edges of the map. Set the force levels for each side as 0. Save this as your new map name/Free Deploy.

Open this file in Excel. In the map matrix that constitutes the bulk of the file change all values, except for the row at the top and the column on the left, to 0. Save as tab delimited text.

Remove the .txt extension in Windows Explorer. The resulting BM file will now have he mandatory 3-5 deployment tiles along the left and right edges removed. Remember it is a template. In BM edit you will have to add deployment tiles, victory locations and choose teams or set forces levels as desired to play. The advantage of a Free Deploy BM is that you can reverse sides (tho soldiers will still retreat to the left/German or right/Allied edges as before), play top to bottom or set up with one side surrounded. Depending on the amount of 'reversal' you impose on any new setup you may find POW captures increase but theses routing cowards werent gonna be of any more use to your side in the battle anyway.

A CLARIFICATION

I've been ploughing through the MAP FAQ over the last few days in an effort to work out how to do the roof files. Well, I think I've finally cracked it (sort of). As a test on my new map
(chateau), I've managed to successfully do three roofs. There will be about 18 in all.

The problem I'm encountering is that the offset pointing to the roof and interior data is out (and more so for each roofset). Rather than pointing to where the data begins (as you would
think should be the case), I've found that I have to have the offset a number of lines before the data for that roofset begins. And with each roofset I'm adding, I find that I have to point
the offset even more lines before the data begins (ie it's compounding). While it's not a real problem with a few roofs, with 18 its going get more complicated (but not impossible to do
however - it's simply not very neat). What's the reason for this? Or is this normal?

Thanks,

Andrew (The Naked Foot) Glenn

 

///// What youre encountering sounds suspiciously like the probs we had before Tin made Texture Maker when we had to insert blank bytes to force a reversal in the TGA file's byte order. Assuming youre using TM then my best guess is that when you are building the image portion of the roof file you may either be adding each roof header to the top of the file as you go or not deleting the 16 byte txtr headers from the image data before pasting it in.

Keep a header file open (in your case- one with the CC2 header [52 4F 4F 46 00 00 00 1C 00 00 00 00 00 00 00 00; 1C in byte 8 = 28] followed by 28x16 byte lines of blanks ['20's]). Then open another file for the image data. Tile the header & image files horizontally in your Hex editor window. Paste in the image data for roof#1 (AFTER!!!removing the 16 byte txtr header). If the last line of the roof1 image data is incomplete (ie not a full 16 byte line; this happens occasionally) fill it in with blanks ('20's) to create a full 16 byte line. Then add another blank to start a new line. Reason for the extra blank byte is - HexEdit needs any line other than the very first to already be started so you can paste new data in.

Note the offset where the interior#1 image data will go and input that offset into the corresponding last 4 bytes of the roofpair#1 line in the header file.

Open interior#1, remove the header, copy the data and paste it into the last line of the image file. Add blanks to fill the new last line then add the extra blank (youll add 2 blanks if you had to fill in an incomplete line) to start another line. Note the offset of this line and input that offset address into bytes 9-12 of the roofpair#2 line in your header file.

Use the GoTo function to jump to the starting offset for interior#1 and remove the blank. This shifts all the data for interior#1 into its correct position, leaving 1 blank to start the offset where the roof#2 data will go. Repeat the process. Open roof#2, remove the header, copy the data, paste into image file, add an extra blank, note offset in header file (interior#20), jump to roof#2 start offset and remove the blank.

When youve finished pasting in all 28 sets roof pair image data THEN you can copy all 29 lines in the header file (the cc2 header + 28 roof pair headers) and paste them into the beginning of your image file. Thus the start of the roof#1 image data gets shifted to line 1E (=30).

Use the hex-to-decimal converter to translate all the corner coordinates you noted when you cut the roof images from the map. Again the first 2 bytes of each roof pair header get the x1 coordinate (upper left horizontal), bytes 3&4 get the x2 coordinate (lower right horizontal), bytes 5&6 get the y1 coord (upper left vertical) and bytes 7&8 get y2 (lower right vertical).

Hope this solves you prob. If so I prolly coulda just said - dont add the headers to the image file until after youve finished pasting in all the image data but better a little extra verbiage :) to make the point clear. Dont hesitate if ya need to follow up with any questions.

lotsa luck,

mick (xe5)
>>>>>>>>>>>>>>>>>>